Last updated

API / geotoolkit3d / scene / LineSegments / LineSegments

Namespace: LineSegments

scene.LineSegments.LineSegments

Table of contents

Type Aliases

Contents

Type Aliases

DataOptions

Ƭ DataOptions: Object

Type declaration

NameTypeDescription
colorprovider?ColorProvidercolor provider used along values.
colors?number[]line colors in r,g,b format. One color for each point.
endcaps?booleanIf the segments should have end caps, used to avoid seams when neighbor segments make a sharp angle, or to make thick segments smoother on the ends.
line?booleantrue if need to use geometry as line geometry, not line segments data.x/y/z allow to store x,y,z coordinates in separate array for clarity, and does not need duplicate points for continuous line. Set data.line to "true" for this format to produce a continuous line with the given points. Leave to false if they are expected to be separate segments.
positions?number[] | TypedArrayline vertices pairs in x,y,z format data.positions store the points xyz interleaved, by pairs ex: [x1,y1,z1, x2,y2,z2, x3,y3,z3, x4,y4,z4], where 1 and 2 form the first line segment, 3 and 4 form the second segment. In this case, segments are separate, and a continuous line require duplicate points between segments for continuity.
values?number[]values the value for each point in the data. Used along the colorprovider.
x?number[]line x positions
y?number[]line y positions
z?number[]line z positions

Options

Ƭ Options: ShaderOptions & { data?: DataOptions ; optimizations?: { disposetrajectoryattribute?: boolean } ; selectable?: boolean }

options object


ShaderOptions

Ƭ ShaderOptions: Object

Type declaration

NameTypeDescription
color?Color | stringColor.
Default is white (1, 1, 1).
dashed?booleanTrue to make the line dashed.
Default is false.
dashoffset?numberDash offset.
Default is 0.
dashscale?numberDash scale.
Default is 1.
dashsize?numberDash size.
Default is 1.
gapsize?numberGap size.
Default is 1.
linestyle?TypeLine style.
Default is undefined.
linewidth?numberLine width.
Default is 1.
opacity?numberOpacity.
Default is 1.
polygonoffset?booleanTrue to use offset (like avoiding Z-fight/occlusion when used for contour).
Default is false.
polygonoffsetfactor?numberFactor for polygon offset, > 0 will make line closer to camera, < 0 will make it farther.
Default is 1.

ShaderOptionsOut

Ƭ ShaderOptionsOut: Object

Type declaration

NameTypeDescription
colorColorcolor
dashedbooleandashed
dashoffsetnumberdash offset
dashscalenumberdash scale
dashsizenumberdash size
gapsizenumbergap size
linewidthnumberline width
opacitynumberopacity
polygonoffsetbooleantrue to use offset (like avoid Z-fight/occlusion when used for contour)
polygonoffsetfactornumberfactor for polygon offset, > 0 will make line closer to camera, < 0 will make it farther