Interface: Line3D
Experimental
Screen-space thick 3D polylines in one instanced draw call (see the module docs).
Implements
Properties
| Property | Modifier | Type | Default value | Description |
|---|---|---|---|---|
material | readonly | ShaderMaterial | undefined | Experimental |
object | readonly | Mesh<InstancedBufferGeometry, ShaderMaterial> | undefined | Experimental Root object to add to a viewport's scene. |
pickKind | readonly | PickElementKind | 'point' | Experimental Pick ids count input points (the nearer vertex of the segment under the cursor). |
Accessors
instanceCount
Get Signature
get instanceCount(): number;Experimental
Number of segment instances drawn (including culled gap instances).
Returns
number
opaque
Get Signature
get opaque(): boolean;Experimental
Whether the line is drawn opaque (depth-writing, see blend3d.ts).
Returns
boolean
pickCount
Get Signature
get pickCount(): number;Experimental
Number of pick ids: one per input point.
Returns
number
Implementation of
PickablePrimitive.pickCount;Methods
createPickMaterial()
createPickMaterial(): PickMaterialHandle;Experimental
Pick material (E2.13): the same shaders with PICKING defined, sharing every uniform except the resolution and viewport (the pick window's) and the pick id base.
Returns
Implementation of
PickablePrimitive.createPickMaterial;dispose()
dispose(): void;Experimental
Release GPU resources. The primitive must not be used afterwards.
Returns
void
Implementation of
Primitive.dispose;setTransform()
setTransform(transform): void;Experimental
Set the data → world transform (cheap: uniforms only, no buffer uploads).
Parameters
| Parameter | Type |
|---|---|
transform | DataTransform |
Returns
void
Implementation of
Primitive.setTransform;setViewport()
setViewport(size): void;Experimental
Update viewport-dependent uniforms (resolution, pixel ratio).
Parameters
| Parameter | Type |
|---|---|
size | ViewportSize |
Returns
void
Implementation of
Primitive.setViewport;syncCamera()
syncCamera(camera): void;Experimental
Bring the dash phase up to date for camera now (it is otherwise refreshed from the frames the line is drawn in, one frame late after a change). The camera's world matrices must be current. No-op for solid lines.
Parameters
| Parameter | Type |
|---|---|
camera | Camera |
Returns
void
update()
update(patch): void;Experimental
Replace or patch the primitive's data. Omitted fields keep their previous values.
Parameters
| Parameter | Type |
|---|---|
patch | Partial<Line3DData> |
Returns
void
Implementation of
Primitive.update;