Basics

Guides

API Reference

Menu

Basics

Guides

API Reference

class: Shape3D

[17:7] extends: Node

Wraps JavaFX Shape3D, the abstract base class for 3D shapes (Box, Sphere, Cylinder, MeshView). Holds the material, cullFace, and drawMode properties common to every 3D shape. Concrete subclasses provide their own constructors and geometry-specific setters. Shape3D extends Node, so 3D shapes inherit Node's translation, rotation, and visibility behavior from the existing Node base.

Methods

  • setMaterial (object MaterialObj)

    Sets the material applied to the shape surface.

    • @p MaterialObj is a Material wrapper (typically a PhongMaterial).
    • @r this object
  • getMaterial ()

    Returns the material currently applied to the shape.

    • @r A PhongMaterial wrapper holding the underlying material object.
  • setCullFace (CullFace)

    Sets which faces of the shape are culled (not rendered).

    • @p CullFace is an fxcullface value or CullFace name (a string): NONE, FRONT, or BACK; or a wrapper/AJO.
    • @r this object
  • setDrawMode (DrawMode)

    Sets the draw mode for the shape.

    • @p DrawMode is an fxdrawmode value or DrawMode name (a string): FILL or LINE; or a wrapper/AJO.
    • @r this object
  • materialProperty ()

    Returns the ObjectProperty backing the material reference.

    • @r An AJO wrapping javafx.beans.property.ObjectProperty.
  • getDrawMode ()

    Returns the current draw mode of the shape.

    • @r An AJO wrapping javafx.scene.shape.DrawMode (FILL or LINE).
  • drawModeProperty ()

    Returns the ObjectProperty backing the draw mode value.

    • @r An AJO wrapping javafx.beans.property.ObjectProperty.
  • getCullFace ()

    Returns the current cull face setting of the shape.

    • @r An AJO wrapping javafx.scene.shape.CullFace (NONE, FRONT, or BACK).
  • cullFaceProperty ()

    Returns the ObjectProperty backing the cull face value.

    • @r An AJO wrapping javafx.beans.property.ObjectProperty.