Package org.robwork.sdurw_graphics
Class DrawableGeometryNode
- java.lang.Object
-
- org.robwork.sdurw_graphics.SceneNode
-
- org.robwork.sdurw_graphics.DrawableNode
-
- org.robwork.sdurw_graphics.DrawableGeometryNode
-
public class DrawableGeometryNode extends DrawableNode
A specific type of DrawableNode that is able to draw a rw::geometry::Geometry.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.robwork.sdurw_graphics.DrawableNode
DrawableNode.DrawableTypeMask, DrawableNode.DrawType, DrawableNode.RenderInfo
-
Nested classes/interfaces inherited from class org.robwork.sdurw_graphics.SceneNode
SceneNode.AddPolicy, SceneNode.NodeType
-
-
Constructor Summary
Constructors Constructor Description DrawableGeometryNode(long cPtr, boolean cMemoryOwn)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addFrameAxis(double size)
add a frame axis to this geometryvoid
addGeometry(GeometryPtr geom)
add a geometry to this rendervoid
addLine(Vector3D v1, Vector3D v2)
add a single line segment to this geometry rendervoid
addLines(VectorLine lines)
add lines to this geometryvoid
delete()
double
getAlpha()
get alpha valueVector3D
getColor()
get the RGB colorstatic long
getCPtr(DrawableGeometryNode obj)
void
setAlpha(double alpha)
sets the alpha valuevoid
setColor(double r, double g, double b, double alpha)
sets the RGBA color of the geometryvoid
setColor(Vector3D rgb)
sets the RGB color of the geometry-
Methods inherited from class org.robwork.sdurw_graphics.DrawableNode
asDrawableNode, draw, draw, getCPtr, getMask, getScale, getTransform, getTransparency, isHighlighted, isTransparent, isVisible, setDrawType, setHighlighted, setMask, setScale, setTransform, setTransparency, setVisible
-
Methods inherited from class org.robwork.sdurw_graphics.SceneNode
addParent, addParent, asCameraNode, asGroupNode, get_name, get_parentNodes, get_type, getCPtr, getName, getType, hasParent, removeParent, removeParent, set_name, set_parentNodes, set_type, setName
-
-
-
-
Method Detail
-
getCPtr
public static long getCPtr(DrawableGeometryNode obj)
-
delete
public void delete()
- Overrides:
delete
in classDrawableNode
-
setColor
public void setColor(double r, double g, double b, double alpha)
sets the RGBA color of the geometry- Parameters:
r
- [in] red [0;1]g
- [in] green [0;1]b
- [in] blue [0;1]alpha
- [in] opasity value [0;1], 0 is completely transparent
-
setColor
public void setColor(Vector3D rgb)
sets the RGB color of the geometry- Parameters:
rgb
- [in] red, green and blue must be between [0;1]
-
setAlpha
public void setAlpha(double alpha)
sets the alpha value- Parameters:
alpha
- [in] between [0;1], 0 is completely transparent
-
getColor
public Vector3D getColor()
get the RGB color- Returns:
- RGB color
-
getAlpha
public double getAlpha()
get alpha value- Returns:
- alpha
-
addLines
public void addLines(VectorLine lines)
add lines to this geometry- Parameters:
lines
- [in] list of line segments that should be added
-
addLine
public void addLine(Vector3D v1, Vector3D v2)
add a single line segment to this geometry render- Parameters:
v1
- [in] line segment vertice 1v2
- [in] line segment vertice 2
-
addGeometry
public void addGeometry(GeometryPtr geom)
add a geometry to this render- Parameters:
geom
- [in] a geometry that should be rendered
-
addFrameAxis
public void addFrameAxis(double size)
add a frame axis to this geometry- Parameters:
size
- [in] length of the frame axis's
-
-