public class GLGridPlane extends java.lang.Object implements HasProperties
Modifier and Type | Field and Description |
---|---|
static PropertyList |
myProps |
Constructor and Description |
---|
GLGridPlane() |
Modifier and Type | Method and Description |
---|---|
void |
alignPoint(Point3d aligned,
Point3d pnt)
Aligns a point with the nearest point defined by this grid.
|
void |
centerInViewer() |
PropertyList |
getAllPropertyInfo()
Returns a list giving static information about all properties exported by
this object.
|
int |
getCellDivisions()
Returns the number of subdivisions for each cell.
|
double |
getCellSize()
Returns the cell size for this grid.
|
GLViewer.DraggerType |
getDragger() |
RigidTransform3d |
getGridToWorld() |
void |
getGridToWorld(RigidTransform3d X) |
int |
getLineWidth()
Returns the line width used to render this grid.
|
java.awt.Color |
getMajorColor() |
int |
getMinCellPixels()
Returns the desired minimum number of pixels per cell or divided cell.
|
java.awt.Color |
getMinorColor() |
double |
getMinSize() |
AxisAngle |
getOrientation() |
Plane |
getPlane() |
void |
getPlane(Plane plane) |
Point3d |
getPosition() |
Property |
getProperty(java.lang.String name)
Returns a property associated with a specified path name.
|
GLGridResolution |
getResolution()
Retuns the resolution for this grid.
|
GLViewer |
getViewer() |
java.awt.Color |
getXAxisColor() |
java.awt.Color |
getYAxisColor() |
boolean |
isAutoSized()
Returns true is cell sizes for this grid are computed automatically.
|
boolean |
isGridVisible() |
int |
numCellDivisions()
Returns the number of subdivisions for each cell.
|
void |
render(GLRenderer renderer,
int flags) |
void |
resetInViewer() |
void |
setAutoSized(boolean enable)
Enables or disables auto cell sizing for this grid.
|
void |
setDragger(GLViewer.DraggerType type) |
void |
setGridToWorld(RigidTransform3d X) |
void |
setGridVisible(boolean enable) |
void |
setLineWidth(int width)
Sets the line width used to render this grid.
|
void |
setMajorColor(java.awt.Color color) |
void |
setMinCellPixels(int n)
Sets the desired minimum number of pixels per cell or divided cell.
|
void |
setMinorColor(java.awt.Color color) |
double |
setMinSize(double size)
Sets the minimum grid size.
|
void |
setOrientation(AxisAngle axisAng) |
void |
setPosition(Point3d pos) |
void |
setResolution(double majorCellSize,
int numDivisions)
Sets the resolution for this grid.
|
void |
setResolution(GLGridResolution res)
Sets the resolution for this grid.
|
void |
setXAxisColor(java.awt.Color color) |
void |
setYAxisColor(java.awt.Color color) |
public static PropertyList myProps
public PropertyList getAllPropertyInfo()
HasProperties
getAllPropertyInfo
in interface HasProperties
public Property getProperty(java.lang.String name)
.
' characters. A sub-property
exists if the value of a property is itself an object which exports
properties. It is only possible to obtain a sub-property handle if each of
its ancestor properties exports their values by reference.getProperty
in interface HasProperties
name
- name of the desired property or sub-propertypublic int getMinCellPixels()
public void setMinCellPixels(int n)
n
- minimum pixels for each cell or divided cellpublic double getCellSize()
public void setLineWidth(int width)
width
- new line widthpublic int getLineWidth()
public Point3d getPosition()
public void setPosition(Point3d pos)
public AxisAngle getOrientation()
public void setOrientation(AxisAngle axisAng)
public void setResolution(double majorCellSize, int numDivisions)
If the major cell size is 0, then auto-sizing will be enabled and the grid size will be computed automatically, based on the viewer's current zoom level. Otherwise, auto-sizing will be turned off.
majorCellSize
- major cell sizenumDivisions
- number of divisions per cellpublic void setResolution(GLGridResolution res)
res specifies the major cell size and the number of
subdivisions per cell.
If the major cell size is 0, then auto-sizing will be enabled and the
grid size will be computed automatically, based on the viewer's current
zoom level. Otherwise, auto-sizing will be turned off.
res
- specified new grid resolution, or auto-sizing.public GLGridResolution getResolution()
public boolean isAutoSized()
public void setAutoSized(boolean enable)
enable
- if true, enables auto cell sizingpublic int numCellDivisions()
public int getCellDivisions()
public double setMinSize(double size)
public double getMinSize()
public RigidTransform3d getGridToWorld()
public void alignPoint(Point3d aligned, Point3d pnt)
public void setGridToWorld(RigidTransform3d X)
public void getGridToWorld(RigidTransform3d X)
public GLViewer getViewer()
public GLViewer.DraggerType getDragger()
public void setDragger(GLViewer.DraggerType type)
public boolean isGridVisible()
public void setGridVisible(boolean enable)
public void render(GLRenderer renderer, int flags)
public void getPlane(Plane plane)
public Plane getPlane()
public void centerInViewer()
public void resetInViewer()
public java.awt.Color getMajorColor()
public void setMajorColor(java.awt.Color color)
public java.awt.Color getXAxisColor()
public void setXAxisColor(java.awt.Color color)
public java.awt.Color getYAxisColor()
public void setYAxisColor(java.awt.Color color)
public java.awt.Color getMinorColor()
public void setMinorColor(java.awt.Color color)