Package org.web3d.x3d.sai.Geometry2D
Interface Rectangle2D
- All Superinterfaces:
X3DGeometryNode
,X3DNode
- All Known Implementing Classes:
Rectangle2D
Rectangle2D is a geometry node that defines a 2D rectangle in X-Y plane.
X3D node tooltip: [X3DGeometryNode] Rectangle2D is a geometry node that defines a 2D rectangle in X-Y plane.
Package hint: This interface is defined by the X3D Java Language Binding Specification for the Scene Authoring Interface (SAI).
X3D node tooltip: [X3DGeometryNode] Rectangle2D is a geometry node that defines a 2D rectangle in X-Y plane.
- Hint: insert a Shape node before adding geometry or Appearance. Examples: X3D Example Archives, X3D for Web Authors, Chapter 10 Geometry 2D https://x3dgraphics.com/examples/X3dForWebAuthors/Chapter10Geometry2D
Package hint: This interface is defined by the X3D Java Language Binding Specification for the Scene Authoring Interface (SAI).
-
Method Summary
Modifier and TypeMethodDescriptionProvide org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) from inputOutput SFNode field metadata.float[]
getSize()
Provide array of 2-tuple float results within allowed range of (0,infinity) from inputOutput SFVec2f field named size.boolean
getSolid()
Provide boolean value from inputOutput SFBool field named solid.setMetadata
(X3DMetadataObject newValue) Accessor method to assign org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) to inputOutput SFNode field metadata.setSize
(float[] newValue) Accessor method to assign 2-tuple float array to inputOutput SFVec2f field named size.setSolid
(boolean newValue) Accessor method to assign boolean value to inputOutput SFBool field named solid.
-
Method Details
-
getMetadata
X3DMetadataObject getMetadata()Provide org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) from inputOutput SFNode field metadata.
Tooltip: [X3DMetadataObject] Information about this node can be contained in a MetadataBoolean, MetadataDouble, MetadataFloat, MetadataInteger, MetadataString or MetadataSet node.- Hint: X3D Architecture 7.2.4 Metadata https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-CD1/Part01/components/core.html#Metadata
- Specified by:
getMetadata
in interfaceX3DGeometryNode
- Specified by:
getMetadata
in interfaceX3DNode
- Returns:
- value of metadata field
- See Also:
-
setMetadata
Accessor method to assign org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) to inputOutput SFNode field metadata.
Tooltip: [X3DMetadataObject] Information about this node can be contained in a MetadataBoolean, MetadataDouble, MetadataFloat, MetadataInteger, MetadataString or MetadataSet node.- Hint: X3D Architecture 7.2.4 Metadata https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-CD1/Part01/components/core.html#Metadata
- Specified by:
setMetadata
in interfaceX3DGeometryNode
- Specified by:
setMetadata
in interfaceX3DNode
- Parameters:
newValue
- is new value for the metadata field.- Returns:
Rectangle2D
- namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).- See Also:
-
getSize
float[] getSize()Provide array of 2-tuple float results within allowed range of (0,infinity) from inputOutput SFVec2f field named size.
Tooltip: 2D dimensions of Rectangle2D.- Warning: simple-geometry dimensions are initializeOnly and cannot be changed after initial creation, avoiding the need for potentially expensive tessellation at run time.
- Hint: for size animation, modify the scale of a parent/ancestor Transform node instead.
- Returns:
- value of size field
-
setSize
Accessor method to assign 2-tuple float array to inputOutput SFVec2f field named size.
Tooltip: 2D dimensions of Rectangle2D.- Warning: simple-geometry dimensions are initializeOnly and cannot be changed after initial creation, avoiding the need for potentially expensive tessellation at run time.
- Hint: for size animation, modify the scale of a parent/ancestor Transform node instead.
- Parameters:
newValue
- is new value for the size field.- Returns:
Rectangle2D
- namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
-
getSolid
boolean getSolid()Provide boolean value from inputOutput SFBool field named solid.
Tooltip: Setting solid true means draw only one side of polygons (backface culling on), setting solid false means draw both sides of polygons (backface culling off).- Hint: mnemonic "this geometry is solid like a brick" (you don't render the inside of a brick).
- Warning: default value true can completely hide geometry if viewed from wrong side!
- Hint: if in doubt, use solid='false' for maximum visibility.
- Warning: solid false not supported in VRML97.
- Hint: (X3D version 4.0 draft) accessType relaxed to inputOutput in order to support animation and visualization.
- Returns:
- value of solid field
-
setSolid
Accessor method to assign boolean value to inputOutput SFBool field named solid.
Tooltip: Setting solid true means draw only one side of polygons (backface culling on), setting solid false means draw both sides of polygons (backface culling off).- Hint: mnemonic "this geometry is solid like a brick" (you don't render the inside of a brick).
- Warning: default value true can completely hide geometry if viewed from wrong side!
- Hint: if in doubt, use solid='false' for maximum visibility.
- Warning: solid false not supported in VRML97.
- Hint: (X3D version 4.0 draft) accessType relaxed to inputOutput in order to support animation and visualization.
- Parameters:
newValue
- is new value for the solid field.- Returns:
Rectangle2D
- namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
-