API

Class EdgesRenderer

This class is used to generate edges of the mesh that could then easily be rendered in a scene.

Hierarchy (View Summary)

Implements

Index
  • Creates an instance of the EdgesRenderer. It is primarily use to display edges of a mesh. Beware when you use this class with complex objects as the adjacencies computation can be really long

    Parameters

    • source: AbstractMesh

      Mesh used to create edges

    • epsilon: number = 0.95

      sum of angles in adjacency to check for edge

    • checkVerticesInsteadOfIndices: boolean = false

      bases the edges detection on vertices vs indices. Note that this parameter is not used if options.useAlternateEdgeFinder = true

    • generateEdgesLines: boolean = true

      should generate Lines or only prepare resources.

    • Optionaloptions: IEdgesRendererOptions

      The options to apply when generating the edges

    Returns EdgesRenderer

customInstances: SmartArray<Matrix> = ...

List of instances to render in case the source mesh has instances

edgesWidthScalerForOrthographic: number = 1000.0

Define the size of the edges with an orthographic camera

edgesWidthScalerForPerspective: number = 50.0

Define the size of the edges with a perspective camera

isEnabled: boolean = true

Gets or sets a boolean indicating if the edgesRenderer is active

  • Checks whether or not the edges renderer is ready to render.

    Parameters

    • OptionaluseInstances: boolean

      Defines whether the instanced shader variant should be checked. If omitted, the current rendering state is used.

    Returns boolean

    true if ready, otherwise false.