Hide menu
Loading...
Searching...
No Matches
WireframeBody

Defines a wireframe body composed of edges and wires.

See also Edge and Wire.

Extends

Constructors

Constructor

new WireframeBody(shape?): WireframeBody

Creates a wireframe body with an optional initial shape.

Parameters

shape?

Edge | Wire

Initial wire or edge to add.

Returns

WireframeBody

Overrides

Body.constructor

Properties

material

material: VisualMaterial | null = null

Visual material of the body.

The default value is null.

Inherited from

Body.material

Accessors

id

Get Signature

get id(): bigint

Returns the unique identifier of the object.

Returns

bigint

Inherited from

Body.id


name

Get Signature

get name(): string | null

Name of the body.

The default value is null.

Returns

string | null

Set Signature

set name(name): void

Sets the name of the body.

Parameters

name

string | null

Body name.

Returns

void

Inherited from

Body.name


shapes

Get Signature

get shapes(): ReadonlySet<Shape>

Wireframe shapes composing the body.

Returns

ReadonlySet<Shape>

Methods

append()

append(shape): void

Appends a shape to the body.

If shape is already present in the body, it is not added again.

Parameters

shape

Edge | Wire

Shape to append.

Returns

void


computeCompoundTriangulation()

Computes a compound polygonal representation of the body shapes.

Param

Default material used when the body does not define its own material.

Call Signature

computeCompoundTriangulation(defaultMaterial): ShapeCompoundTriangulation<false>

Computes a compound polygonal representation of the body shapes.

Parameters

defaultMaterial

VisualMaterial

Default material used when the body does not define its own material.

Returns

ShapeCompoundTriangulation<false>

Call Signature

computeCompoundTriangulation(defaultMaterial): ShapeCompoundTriangulation

Computes a compound polygonal representation of the body shapes.

Parameters

defaultMaterial

VisualMaterial | null

Default material used when the body does not define its own material.

Returns

ShapeCompoundTriangulation