bitbybit.dev v1.0.0-rc.1
    Preparing search index...

    Class DrawBasicGeometryOptions

    Draw options for basic geometry types like points, lines, polylines, surfaces and jscad meshes

    Index

    Constructors

    • Parameters

      • Optionalcolours: string | string[]
      • Optionalsize: number
      • Optionalopacity: number
      • Optionalupdatable: boolean
      • Optionalhidden: boolean
      • OptionaldrawTwoSided: boolean
      • OptionalbackFaceColour: string
      • OptionalbackFaceOpacity: number
      • OptionalcolorMapStrategy: colorMapStrategyEnum
      • OptionalarrowSize: number
      • OptionalarrowAngle: number

      Returns DrawBasicGeometryOptions

    Properties

    colours: string | string[]

    Basic geometry colours to use for lines, points, polylines, surfaces, jscad meshes.

    #ff0000
    
    colorMapStrategy: colorMapStrategyEnum

    Strategy for mapping colors to entities when there are more entities than colors.

    • firstColorForAll: Uses the first color for all entities (legacy behavior)
    • lastColorRemainder: Maps colors 1:1, then uses last color for remaining entities
    • repeatColors: Cycles through colors in a repeating pattern
    • reversedColors: After exhausting colors, reverses direction (ping-pong pattern)
    lastColorRemainder
    
    size: number

    Size affect how big the drawn points are and how wide lines are.

    0.1
    

    0

    Infinity

    0.1

    opacity: number

    Opacity of the point 0 to 1

    1
    

    0

    1

    0.1

    updatable: boolean

    If geometry needs to be updated later

    false
    
    hidden: boolean

    Hidden

    false
    
    drawTwoSided: boolean

    Draw two-sided faces with different colors for front and back. This helps visualize face orientation. Only applies to surfaces.

    true
    
    backFaceColour: string

    Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true and drawing surfaces.

    #0000ff
    
    backFaceOpacity: number

    Back face opacity value between 0 and 1. Only used when drawTwoSided is true and drawing surfaces.

    1
    

    0

    1

    0.1

    arrowSize: number

    Size of the arrow head at the end of lines and polylines. Set to 0 to disable arrows.

    0
    

    0

    Infinity

    0.01

    arrowAngle: number

    Angle of the arrow head in degrees. Controls how wide the arrow head spreads.

    15
    

    0

    90

    1