public class MotionTrailPlot extends BaseDisplayObject implements MotionTrail, StackableObject
Modifier and Type | Field and Description |
---|---|
static float |
DEFAULT_MOTION_EASING |
static int |
DEFAULT_NUM_POINTS |
static int |
DEFAULT_PLOT_SIZE |
protected GLColor |
mColor1 |
protected GLColor |
mColor2 |
protected QuadMeshColorBuffer |
mColorBuffer |
protected java.lang.Object |
mData |
protected QuadMeshBuffer |
mMeshBuffer |
protected int |
mMinLength |
protected float |
mMotionEasingX |
protected float |
mMotionEasingY |
protected int |
mNumPoints |
protected PointF[] |
mPoints |
protected float |
mScale1 |
protected float |
mScale2 |
protected int |
mSegmentLength |
protected boolean |
mStackable |
protected Manipulatable |
mTarget |
protected PointF |
mTargetOffset |
protected Texture |
mTexture |
protected QuadMeshTextureCoordBuffer |
mTextureCoordBuffer |
protected float |
mTextureHeight |
protected float |
mTextureScaleX |
protected float |
mTextureScaleY |
protected float |
mTextureWidth |
protected UniContainer |
mUniParent |
ATT_ALPHA, ATT_ANIMATOR, ATT_BLEND_MODE, ATT_COLOR, ATT_DEBUG, ATT_ORIGIN_AT_CENTER, ATT_ROTATION, ATT_VISIBLE, mAlive, mAlpha, mAlphaTestEnabled, mAutoUpdateBounds, mBlendFunc, mBounds, mBypassCameraClipping, mColor, mDebugFlags, mFrameDuration, mHasTransformValues, mId, mInvalidateFlags, mManipulators, mMask, mMatrix, mNumManipulators, mOrigin, mParent, mPerspectiveEnabled, mPivot, mPosition, mRotation, mRotationVectorX, mRotationVectorY, mRotationVectorZ, mScale, mScene, mSceneSize, mSize, mSkew, mTransformMatrix, mTransformMatrixValues, mUIConstraint, mVisible, mZ, TAG
FLIP_X, FLIP_Y
ALL, ALPHA, BLEND, BOUNDS, CACHE, CHILDREN, COLOR, DEPTH, FRAME, ORIGIN, PARENT, PARENT_BOUNDS, PERSPECTIVE, PIVOT, POSITION, ROTATION, SCALE, SIZE, SKEW, TEXTURE, TEXTURE_COORDS, TRANSFORM_MATRIX, VERTICES, VISIBILITY, VISUAL
Constructor and Description |
---|
MotionTrailPlot() |
MotionTrailPlot(Manipulatable target) |
Modifier and Type | Method and Description |
---|---|
void |
dispose() |
boolean |
draw(GLState glState) |
protected boolean |
drawChildren(GLState glState) |
java.lang.Object |
getData() |
int |
getMinLength() |
float |
getMotionEasingX() |
float |
getMotionEasingY() |
int |
getNumPoints() |
int |
getNumStackedChildren() |
Parentable |
getParent() |
PointF[] |
getPoints() |
Manipulatable |
getTarget() |
PointF |
getTargetOffset() |
Texture |
getTexture() |
boolean |
isStackable() |
void |
move(float dx,
float dy) |
void |
onAdded(UniContainer container) |
void |
onRemoved()
This is called after this object is removed from a Container
|
void |
reset(java.lang.Object... params) |
void |
setColorRange(GLColor color1,
GLColor color2) |
void |
setData(java.lang.Object data) |
void |
setMinLength(int totalLength) |
void |
setMotionEasing(float easing) |
void |
setMotionEasing(float easingX,
float easingY) |
void |
setNumPoints(int numPoints) |
void |
setPoints(PointF... points) |
void |
setPointsAt(float x,
float y,
float z) |
void |
setPointsAt(PointF p) |
void |
setPosition(float x,
float y) |
void |
setScaleRange(float scale1,
float scale2) |
void |
setStackable(boolean value) |
void |
setTarget(Manipulatable target) |
void |
setTargetOffset(float offsetX,
float offsetY) |
void |
setTexture(Texture texture) |
int |
stack(GLState glState,
int index,
VertexBuffer vertexBuffer,
ColorBuffer colorBuffer,
TextureCoordBuffer coordBuffer) |
boolean |
update(int deltaTime) |
addManipulator, drawBounds, drawEnd, drawStart, drawWireframe, getAlpha, getBlendFunc, getBounds, getColor, getDebugFlags, getFps, getGlobalPosition, getHeight, getId, getInheritedBlendFunc, getInheritedColor, getManipulator, getMask, getMatrix, getNumManipulators, getObjectTree, getOrigin, getParentMatrix, getPivot, getPosition, getRotation, getScale, getScene, getSceneSize, getSize, getSkew, getUIConstraint, getWidth, getX, getY, getZ, globalToLocal, invalidate, invalidate, isAlive, isAlphaTestEnabled, isAutoUpdateBounds, isBypassCameraClipping, isOriginAtCenter, isPerspectiveEnabled, isVisible, localToGlobal, moveTo, onAdded, onAddedToScene, onCreateChildren, onPreConcatParentMatrix, onRemovedFromScene, queueEvent, removeAllManipulators, removeFromParent, removeManipulator, rotate, setAlive, setAlpha, setAlphaTestEnabled, setAutoUpdateBounds, setBlendFunc, setBypassCameraClipping, setColor, setDebugFlags, setFps, setId, setMask, setOrigin, setOrigin, setOriginAtCenter, setPerspectiveEnabled, setPivot, setPivot, setPivotAtCenter, setPosition, setRotation, setRotationVector, setScale, setScale, setSize, setSize, setSkew, setUIConstraint, setVisible, setX, setXMLAttributes, setY, setZ, shouldDraw, toString, updateBounds, updateChildren, validate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
isPerspectiveEnabled, onAdded, onCreateChildren, setPerspectiveEnabled, setXMLAttributes
addManipulator, getAlpha, getBlendFunc, getBounds, getColor, getFps, getId, getInheritedBlendFunc, getInheritedColor, getManipulator, getNumManipulators, getObjectTree, getOrigin, getPivot, getScene, getSkew, getZ, globalToLocal, invalidate, invalidate, isAlive, isAutoUpdateBounds, isVisible, localToGlobal, onAddedToScene, onRemovedFromScene, queueEvent, removeAllManipulators, removeFromParent, removeManipulator, setAlive, setAlpha, setAutoUpdateBounds, setBlendFunc, setColor, setFps, setId, setOrigin, setOrigin, setOriginAtCenter, setPivot, setPivot, setPivotAtCenter, setSkew, setVisible, setZ, shouldDraw, updateBounds
getHeight, getPosition, getRotation, getScale, getSize, getWidth, getX, getY, moveTo, rotate, setPosition, setRotation, setScale, setScale, setSize, setSize, setX, setY
public static final int DEFAULT_PLOT_SIZE
public static final int DEFAULT_NUM_POINTS
public static final float DEFAULT_MOTION_EASING
protected int mNumPoints
protected float mMotionEasingX
protected float mMotionEasingY
protected int mMinLength
protected int mSegmentLength
protected PointF[] mPoints
protected Manipulatable mTarget
protected PointF mTargetOffset
protected java.lang.Object mData
protected Texture mTexture
protected float mTextureWidth
protected float mTextureHeight
protected float mTextureScaleX
protected float mTextureScaleY
protected QuadMeshBuffer mMeshBuffer
protected QuadMeshTextureCoordBuffer mTextureCoordBuffer
protected QuadMeshColorBuffer mColorBuffer
protected GLColor mColor1
protected GLColor mColor2
protected float mScale1
protected float mScale2
protected boolean mStackable
protected UniContainer mUniParent
public MotionTrailPlot()
public MotionTrailPlot(Manipulatable target)
public java.lang.Object getData()
getData
in interface MotionTrail
public void setData(java.lang.Object data)
setData
in interface MotionTrail
public void setScaleRange(float scale1, float scale2)
public void setPosition(float x, float y)
setPosition
in interface Manipulatable
setPosition
in class BaseDisplayObject
public void move(float dx, float dy)
move
in interface Manipulatable
move
in class BaseDisplayObject
public boolean update(int deltaTime)
update
in interface Displayable
update
in class BaseDisplayObject
public boolean draw(GLState glState)
draw
in interface DisplayObject
draw
in class BaseDisplayObject
protected boolean drawChildren(GLState glState)
drawChildren
in class BaseDisplayObject
public Texture getTexture()
public void setTexture(Texture texture)
public PointF[] getPoints()
public void setPoints(PointF... points)
public int getNumPoints()
getNumPoints
in interface MotionTrail
public void setNumPoints(int numPoints)
setNumPoints
in interface MotionTrail
public Manipulatable getTarget()
getTarget
in interface MotionTrail
public void setTarget(Manipulatable target)
setTarget
in interface MotionTrail
public void setPointsAt(float x, float y, float z)
public void setPointsAt(PointF p)
public int getMinLength()
public void setMinLength(int totalLength)
public float getMotionEasingX()
public float getMotionEasingY()
public void setMotionEasing(float easing)
easing,
- must be from 0 to 1public void setMotionEasing(float easingX, float easingY)
public PointF getTargetOffset()
public void setTargetOffset(float offsetX, float offsetY)
public void dispose()
dispose
in interface Displayable
dispose
in class BaseDisplayObject
public int stack(GLState glState, int index, VertexBuffer vertexBuffer, ColorBuffer colorBuffer, TextureCoordBuffer coordBuffer)
stack
in interface StackableObject
public int getNumStackedChildren()
getNumStackedChildren
in interface StackableObject
public void setStackable(boolean value)
setStackable
in interface StackableObject
public boolean isStackable()
isStackable
in interface StackableObject
public final Parentable getParent()
getParent
in interface Displayable
getParent
in class BaseDisplayObject
public void onAdded(UniContainer container)
onAdded
in interface StackableObject
public void onRemoved()
BaseDisplayObject
onRemoved
in interface Displayable
onRemoved
in class BaseDisplayObject