Bitbybit Docs
    Bereite Suchindex vor...

    Klasse DrawShapeDto<T> (Inputs.OCCT)

    A shape and how to draw it, for the renderer packages' shape drawing: colors and opacity of faces, edges and vertices, what to show, and how finely to mesh the shape.

    Typenparameter

    • T
    Index

    Konstruktoren

    • Provide options without default values

      Typenparameter

      • T

      Parameter

      • Optionalshape: T
      • OptionalfaceOpacity: number
      • OptionaledgeOpacity: number
      • OptionaledgeColour: string
      • OptionalfaceMaterial: any
      • OptionalfaceColour: string
      • OptionaledgeWidth: number
      • OptionaldrawEdges: boolean
      • OptionaldrawFaces: boolean
      • OptionaldrawVertices: boolean
      • OptionalvertexColour: string
      • OptionalvertexSize: number
      • Optionalprecision: number
      • OptionaldrawEdgeIndexes: boolean
      • OptionaledgeIndexHeight: number
      • OptionaledgeIndexColour: string
      • OptionaldrawFaceIndexes: boolean
      • OptionalfaceIndexHeight: number
      • OptionalfaceIndexColour: string
      • OptionaldrawTwoSided: boolean
      • OptionalbackFaceColour: string
      • OptionalbackFaceOpacity: number
      • OptionalkeepMeshData: boolean
      • OptionalallowQualityDecrease: boolean
      • OptionalforceFaceDeflection: boolean

      Rückgabewert DrawShapeDto<T>

    Eigenschaften

    shape?: T

    The shape to draw; it is meshed at precision first.

    undefined
    

    true

    faceOpacity: number

    How opaque the faces are, from 0 for invisible to 1 for solid.

    1
    

    0

    1

    0.1

    edgeOpacity: number

    How opaque the edges are, from 0 for invisible to 1 for solid.

    1
    

    0

    1

    0.1

    edgeColour: string

    The color of the edges as a hex string such as #ffffff.

    #ffffff
    
    faceMaterial?: any

    A material for the faces from the rendering engine; when given it replaces the face color.

    undefined
    

    true

    faceColour: string

    The color of the faces as a hex string such as #ff0000.

    #ff0000
    
    edgeWidth: number

    How thick the edge lines are drawn.

    2
    

    0

    Infinity

    0.1

    drawEdges: boolean

    When false, the edges are not drawn.

    true
    
    drawFaces: boolean

    When false, the faces are not drawn.

    true
    
    drawVertices: boolean

    When true, the vertices are drawn as small markers.

    false
    
    vertexColour: string

    The color of the vertex markers as a hex string.

    #ff00ff
    
    vertexSize: number

    The size of the vertex markers, in model units.

    0.03
    

    0

    Infinity

    0.01

    precision: number

    The meshing tolerance in model units; a smaller value follows curved surfaces more closely with more triangles.

    0.01
    

    0

    Infinity

    0.01

    drawEdgeIndexes: boolean

    When true, each edge's index is written next to it, handy for picking edges to fillet.

    false
    
    edgeIndexHeight: number

    The height of the edge index labels, in model units.

    0.06
    

    0

    Infinity

    0.01

    edgeIndexColour: string

    The color of the edge index labels as a hex string.

    #ff00ff
    
    drawFaceIndexes: boolean

    When true, each face's index is written on it, handy for picking faces.

    false
    
    faceIndexHeight: number

    The height of the face index labels, in model units.

    0.06
    

    0

    Infinity

    0.01

    faceIndexColour: string

    The color of the face index labels as a hex string.

    #0000ff
    
    drawTwoSided: boolean

    When true, the back of each face is drawn in its own color, which shows which way faces point.

    true
    
    backFaceColour: string

    The color of the back of the faces as a hex string; used only with drawTwoSided.

    #0000ff
    
    backFaceOpacity: number

    How opaque the back of the faces is, from 0 to 1; used only with drawTwoSided.

    1
    

    0

    1

    0.1

    keepMeshData: boolean

    When true, the triangulation stays cached on the shape after drawing; when false it is cleared so memory does not grow across draws.

    false
    
    allowQualityDecrease: boolean

    When true, a shape already meshed more finely may be remeshed at the coarser precision asked for.

    true
    
    forceFaceDeflection: boolean

    When true, every face is remeshed at the requested precision even when a triangulation is cached.

    false