API Docs for:
Show:

LS.Components.GeometricPrimitive Class

GeometricPrimitive renders a primitive like a Cube, Sphere, Plane, etc

Constructor

LS.Components.GeometricPrimitive

(
  • object
)

Parameters:

  • object String

    to configure from

Item Index

Methods

Properties

Methods

setCustomMesh

(
  • mesh
)

Assigns a mesh as custom mesh and sets the geometry to CUSTOM

Parameters:

  • mesh GL.Mesh

    the mesh to use as custom mesh

Properties

geometry

Enum

The shape to render, valid values are: LS.Components.GeometricPrimitive.CUBE,PLANE,CYLINDER,SPHERE,CIRCLE,HEMISPHERE,ICOSAHEDRON,CONE,QUAD

Default: LS.Components.GeometricPrimitive.CUBE

primitive

Enum

The GL primitive to use (LINES,LINE_STRIP,TRIANGLES,TRIANGLE_FAN

Default: 10

size

Number

The size of the primitive (the global scale)

Default: 10