volatileprototypes.fvlib
Class BehaviorCameraOverlap

java.lang.Object
  extended by volatileprototypes.fvlib.Solver
      extended by volatileprototypes.fvlib.Behavior
          extended by volatileprototypes.fvlib.BehaviorCameraOverlap

public final class BehaviorCameraOverlap
extends Behavior

Since:
0.5.0

Nested Class Summary
 
Nested classes/interfaces inherited from class volatileprototypes.fvlib.Solver
Solver.Caller
 
Field Summary
 
Fields inherited from class volatileprototypes.fvlib.Behavior
points
 
Fields inherited from class volatileprototypes.fvlib.Solver
xs
 
Constructor Summary
BehaviorCameraOverlap()
          Constructor, generates a new class instance.
BehaviorCameraOverlap(java.util.ArrayList<? extends Point> pointsin, processing.core.PVector camPosIn)
          Constructor.
BehaviorCameraOverlap(Point[] pointsin, processing.core.PVector camPosIn)
          Constructor.
 
Method Summary
 processing.core.PVector getCam()
          Returns the camera position as a PVector.
 float getMagnitude()
          Returns the force magnitude value.
 float getRange()
          Returns the range value.
 BehaviorCameraOverlap setCam(processing.core.PVector camPosIn)
          Sets the object's Camera Vector using the supplied PVector object.
 BehaviorCameraOverlap setMagnitude(float magin)
          Sets the magnitude of the separation force applied to each point.
 BehaviorCameraOverlap setRange(float nRange)
          Sets the distance that points need to be separated.
protected  void stepFunction(int step, int offset)
           
 
Methods inherited from class volatileprototypes.fvlib.Behavior
getP, setP, setP
 
Methods inherited from class volatileprototypes.fvlib.Solver
finalizeFunction, getNumCPUs, step
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BehaviorCameraOverlap

public BehaviorCameraOverlap()
Constructor, generates a new class instance.


BehaviorCameraOverlap

public BehaviorCameraOverlap(java.util.ArrayList<? extends Point> pointsin,
                             processing.core.PVector camPosIn)
Constructor. Constructor, generates a new class instance using a copy of the supplied Point ArrayList and a Vector indicating camera position against which points will be separated.

Parameters:
pointsin - An ArrayList containing Point objects with which the object will be initialized.
camPosIn - A PVector object indicating the camera position.

BehaviorCameraOverlap

public BehaviorCameraOverlap(Point[] pointsin,
                             processing.core.PVector camPosIn)
Constructor. Constructor, generates a new class instance using the supplied Point array and a Vector indicating camera position against which points will be separated.

Parameters:
pointsin - An array containing Point objects with which the object will be initialized.
camPosIn - A PVector object indicating the camera position.
Method Detail

setCam

public BehaviorCameraOverlap setCam(processing.core.PVector camPosIn)
Sets the object's Camera Vector using the supplied PVector object.

Parameters:
camPosIn - The new camera position as a PVector.
Returns:
The current object.

setMagnitude

public BehaviorCameraOverlap setMagnitude(float magin)
Sets the magnitude of the separation force applied to each point.

Parameters:
magin - A float representing magnitude.
Returns:
The current object.

setRange

public BehaviorCameraOverlap setRange(float nRange)
Sets the distance that points need to be separated.

Parameters:
nRange - A float representing distance.
Returns:
The current object.

getRange

public float getRange()
Returns the range value.

Returns:
The range value.

getCam

public processing.core.PVector getCam()
Returns the camera position as a PVector.

Returns:
A PVector object representing camera position.

getMagnitude

public float getMagnitude()
Returns the force magnitude value.

Returns:
A float representing the magnitude value.

stepFunction

protected final void stepFunction(int step,
                                  int offset)
Overrides:
stepFunction in class Solver