Interface GreasedLineMaterialBuilderOptions
cameraFacing?: boolean;
color?: Color3;
colorDistribution?: GreasedLineMeshColorDistribution;
colorDistributionType?: GreasedLineMeshColorDistributionType;
colorMode?: GreasedLineMeshColorMode;
colors?: Color3[];
colorsSampling?: number;
colorsTexture?: RawTexture;
createAndAssignMaterial?: boolean;
dashCount?: number;
dashOffset?: number;
dashRatio?: number;
forceGLSL?: boolean;
materialType?: GreasedLineMeshMaterialType;
resolution?: Vector2;
sizeAttenuation?: boolean;
useColors?: boolean;
useDash?: boolean;
visibility?: number;
width?: number;
}
Hierarchy (View Summary)
- GreasedLineMaterialOptions
- GreasedLineMaterialBuilderOptions
Properties
Optionalcamera Facing
Whether to use camera facing for the line. Defaults to true.
Optionalcolor
Color of the line. Applies to all line segments. Defaults to White.
Optionalcolor Distribution
Distribution of the colors if the color table contains fewer entries than needed. Defaults to GreasedLineMeshColorDistribution.COLOR_DISTRIBUTION_START
Optionalcolor Distribution Type
The method used to distribute the colors along the line. You can use segment distribution when each segment will use on color from the color table. Or you can use line distribution when the colors are distributed evenly along the line ignoring the segments.
Optionalcolor Mode
Color mode of the line. Applies to all line segments. The pixel color from the material shader will be modified with the value of
Optionalcolors
Colors of the line segments. Defaults to empty.
Optionalcolors Sampling
Sampling type of the colors texture Defaults to NEAREST_NEAREST.
Optionalcolors Texture
You can provide a colorsTexture to use instead of one generated from the 'colors' option
Optionalcreate And Assign Material
If set to true a new material will be created and a new material plugin will be attached to the material. The material will be set on the mesh. If the instance option is specified in the mesh options, no material will be created/assigned. Defaults to true.
Optionaldash Count
Optionaldash Offset
Offset of the dashes along the line. 0 to 1. Defaults to 0.
Optionaldash Ratio
Length of the dash. 0 to 1. 0.5 means half empty, half drawn. Defaults to 0.5.
Optionalforce GLSL
Force the greased lines to compile to glsl even on WebGPU engines. False by default. This is mostly meant for backward compatibility.
Optionalmaterial Type
Type of the material to use to render the line. Defaults to StandardMaterial.
Optionalresolution
Defaults to engine.getRenderWidth() and engine.getRenderHeight() Rendering resolution
Optionalsize Attenuation
If false then width units = scene units. If true then line will width be reduced. Defaults to false.
Optionaluse Colors
If true,
Optionaluse Dash
If true, dashing is used. Defaults to false.
Optionalvisibility
Sets the line length visibility. 0 - 0% of the line will be visible. 1 - 100% of the line will be visible.
Optionalwidth
Line width. If sizeAttenuation os false scene units will be used for width. Defaults to 0.1 if
Material options for GreasedLineBuilder