public class TCircle extends TShape
Modifier and Type | Field and Description |
---|---|
protected java.awt.geom.Ellipse2D |
circle |
protected int |
n |
protected int |
radius |
color, fillShape, hitRect, stroke, visible
coordinateStrBuilder, coordsEditTrigger, coordsVisibleInMouseBox, enabled, screenPt, stepEditTrigger, support, trackEditTrigger, worldPt
Constructor and Description |
---|
TCircle(int n)
Constructs a TCircle with image coordinates (0, 0).
|
TCircle(int n,
double x,
double y)
Constructs a TCircle with specified image coordinates.
|
Modifier and Type | Method and Description |
---|---|
Interactive |
findInteractive(DrawingPanel panel,
int xpix,
int ypix)
Returns this if it is enabled and visible and the specified
pixel position falls within the bounds of this circle.
|
int |
getFrameNumber(VideoPanel vidPanel)
Overrides TPoint getFrameNumber method.
|
int |
getRadius()
Gets the radius of this circle.
|
protected java.awt.Shape |
getShape(VideoPanel vidPanel)
Gets the circle shape to be filled in the draw method.
|
void |
setRadius(int radius)
Sets the radius of this circle.
|
draw, getBounds, getColor, getStroke, isVisible, setColor, setHitRectCenter, setStroke, setVisible, toString
addPropertyChangeListener, addPropertyChangeListener, angle, angle, center, cos, cos, equals, getScreenPosition, getWorldPosition, getXMax, getXMin, getYMax, getYMin, isCoordsEditTrigger, isEnabled, isMeasured, isStepEditTrigger, isTrackEditTrigger, removePropertyChangeListener, removePropertyChangeListener, setCoordsEditTrigger, setEnabled, setLocation, setPositionOnLine, setScreenPosition, setScreenPosition, setStepEditTrigger, setTrackEditTrigger, setX, setXY, setY, showCoordinates, sin, sin, translate
clone, distance, distance, distance, distanceSq, distanceSq, distanceSq, hashCode, setLocation
finalize, getClass, notify, notifyAll, wait, wait, wait
getX, getY
protected java.awt.geom.Ellipse2D circle
protected int radius
protected int n
public TCircle(int n)
n
- the video frame numberpublic TCircle(int n, double x, double y)
n
- the video frame numberx
- the x coordinatey
- the y coordinatepublic void setRadius(int radius)
radius
- the radius in screen pixelspublic int getRadius()
public int getFrameNumber(VideoPanel vidPanel)
getFrameNumber
in class TPoint
vidPanel
- the video panel drawing this circlepublic Interactive findInteractive(DrawingPanel panel, int xpix, int ypix)
findInteractive
in interface Interactive
findInteractive
in class TShape
panel
- the drawing panelxpix
- the x pixel position on the panelypix
- the y pixel position on the panelprotected java.awt.Shape getShape(VideoPanel vidPanel)