Class OffsetOriginStep
java.lang.Object
org.opensourcephysics.cabrillo.tracker.Step
org.opensourcephysics.cabrillo.tracker.OffsetOriginStep
- All Implemented Interfaces:
Cloneable
This is a Step for a OffsetOrigin. It is used for
setting the origin of an ImageCoordSystem.
- Author:
- Douglas Brown
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassA class to represent the position of the offset origin. -
Field Summary
FieldsFields inherited from class org.opensourcephysics.cabrillo.tracker.Step
dataVisible, defaultIndex, footprint, format, hitRect, n, panelMarks, points, screenPoints, selectionShape, selectionStroke, trackID, transform, type, TYPE_ACCELERATION, TYPE_UNKNOWN, TYPE_VELOCITY, valid -
Constructor Summary
ConstructorsConstructorDescriptionOffsetOriginStep(OffsetOrigin track, int n, double x, double y) Constructs a OffsetOriginStep with specified image coordinates. -
Method Summary
Modifier and TypeMethodDescriptionclone()Clones this Step.protected MarkgetMark(TrackerPanel trackerPanel) Overrides Step getMark method.Gets the position.voidsetWorldXY(double x, double y) Sets the world coordinates.toString()Returns a String describing this step.Methods inherited from class org.opensourcephysics.cabrillo.tracker.Step
dispose, draw, erase, erase, findInteractive, getDefaultPoint, getFrameNumber, getLength, getPointIndex, getPoints, getTrack, remark, remark, repaint, repaint, setDefaultPointIndex, setFootprint, setHitRectCenter
-
Field Details
-
worldX
protected double worldX -
worldY
protected double worldY
-
-
Constructor Details
-
OffsetOriginStep
Constructs a OffsetOriginStep with specified image coordinates.- Parameters:
track- the offset originn- the frame numberx- the image x coordinatey- the image y coordinate
-
-
Method Details
-
getPosition
Gets the position.- Returns:
- the position
-
setWorldXY
public void setWorldXY(double x, double y) Sets the world coordinates. This moves the origin so the image location does not change.- Parameters:
x- the world x coordinatey- the world y coordinate
-
getMark
Overrides Step getMark method. -
clone
Clones this Step. -
toString
Returns a String describing this step.
-