public class Line extends Curve
Geometry.getControlPoints()
, and connected by getSegments()
,
which means it can also be a set of connected line segments.
The line is usually a linear object, which means it cannot be used to represent a curve, in order to represent a curve, uses NurbsCurve
.name, properties
Constructor and Description |
---|
Line()
Initializes a new instance of the
Line class. |
Line(java.lang.String name)
Initializes a new instance of the
Line class. |
Modifier and Type | Method and Description |
---|---|
static Line |
fromPoints(Vector3... points)
Construct a
Line instance from a set of points. |
java.util.List<Vector4> |
getControlPoints()
Gets all control points
|
java.util.List<int[]> |
getSegments()
Gets the segments of the line
|
boolean |
getVisible()
Gets if the geometry is visible
|
void |
makeDefaultIndices()
Generate the sequence 0,1,2,3....
Geometry.getControlPoints() .Length-1 to getSegments() so the ControlPoints can be used as a single line |
void |
setVisible(boolean value)
Sets if the geometry is visible
|
getColor, getEntityRendererKey, setColor
getBoundingBox, getExcluded, getParentNode, getParentNodes, setExcluded, setParentNode
getScene
findProperty, getName, getProperties, getProperty, removeProperty, removeProperty, setName, setProperty
public Line()
Line
class.public Line(java.lang.String name)
Line
class.name
- Name.public java.util.List<Vector4> getControlPoints()
public boolean getVisible()
public void setVisible(boolean value)
value
- New valuepublic java.util.List<int[]> getSegments()
public static Line fromPoints(Vector3... points)
Line
instance from a set of points.points
- public void makeDefaultIndices()
Geometry.getControlPoints()
.Length-1 to getSegments()
so the ControlPoints can be used as a single line