public class PjZigZag extends PjProject
HAS_BOUNDARY_PANEL, HAS_CONFIG_PANEL, HAS_INFO_PANEL, HAS_LABEL_PANEL, HAS_MATERIAL_PANEL, HAS_TEXTURE_PANEL, HAS_VECTOR_PANEL, INSPECTOR_INFO, INSPECTOR_INFO_EXT, IS_DELETED, IS_FIXED, IS_FOCUSSED, IS_PICKED, IS_SELECTED, IS_USED, NUM_TAGS| Constructor and Description |
|---|
PjZigZag()
Sets the required polygon and the panels for the number of lines,
Length of the Zag and the angles of the zig and the zag.
|
| Modifier and Type | Method and Description |
|---|---|
PdVector[] |
computeVertices(PgPolygonSet z_short,
double[] vFac,
int[] length)
Computes the vertices of the ZigZag with the given parameters.
|
void |
computeZigZag()
Computes the ZigZag construction depending on the given prameters: angles, lengths and number of lines.
|
void |
init()
Initializes the Applet.
|
PiVector[] |
showZags(PgPolygonSet z_short,
int delta)
Draws the Zags extended to infinity.
|
PiVector[] |
showZigZag(PgPolygonSet z_short)
Draws the ZigZag in original size.
|
void |
start()
Starts the Applet
|
boolean |
update(java.lang.Object event)
Handles the events of the Panel
|
addDisplay, addGeometry, addGeometry, dispose, dragDisplay, dragInitial, dragVertex, fitDisplays, getAnimation, getDisplay, getDisplays, getGeometry, getGeometry, getNumGeometries, getParameter, getViewer, hasAnimation, hasDisplay, isEnabledAutoFit, markVertices, pickDisplay, pickInitial, pickVertex, removeDisplay, removeGeometries, removeGeometry, selectDisplay, selectGeometry, setAnimation, setBackColor, setBorderType, setDisplay, setEnabledAutoFit, setGeometry, setParameter, setTime, setViewer, stop, unmarkVerticesaddInspector, addUpdateListener, assureInspector, clearTag, clone, clone, clone, copy, getFather, getInfoPanel, getInspector, getName, getNumObjects, getSymbol, hasInspector, hasTag, hasUpdateListener, instanceOf, instanceOf, newInspector, newInspector, removeInspector, removeInspector, removeUpdateListener, setName, setParent, setSymbol, setTag, toString, updatePanelsequals, getClass, hashCode, notify, notifyAll, wait, wait, waitgetNamegetNamepublic PjZigZag()
public void init()
public void start()
start in class PjProjectPvViewerIf.start(),
PjProject.isEnabledAutoFit()public boolean update(java.lang.Object event)
update in interface PsUpdateIfupdate in class PsObjectevent - carries a lot of informationPsObject.setParent(PsUpdateIf),
PsObject.getFather(),
PsObject.addUpdateListener(PsUpdateIf)public void computeZigZag()
public PdVector[] computeVertices(PgPolygonSet z_short, double[] vFac, int[] length)
z_short - polygons that define the number of polygons in the zigzagvFac - vFac[0] = angle of zig, vFac[1] = angle of zaglength - m_length[0] = length of zig, m_length[1] = length of zagpublic PiVector[] showZags(PgPolygonSet z_short, int delta)
z_short - the polygons drawn in this method are baed on the points in this polygonsetdelta - the number of zags skippedpublic PiVector[] showZigZag(PgPolygonSet z_short)
z_short - the polygons drawn in this method are baed on the points in this polygonset"