Bitbybit Docs
    Preparing search index...

    Class ConvertStepToGltfAdvancedDto (Inputs.OCCT)

    用于 io.convertStepToGltfAdvanced 的 STEP 文件以及所有读取、网格化和写出选项;关闭不需要的选项以加快转换。

    Hierarchy (View Summary)

    Index

    Constructors

    • Parameters

      • OptionalstepData: string | ArrayBuffer | File | Blob | Uint8Array<ArrayBufferLike>

      Returns ConvertStepToGltfAdvancedDto

    Properties

    stepData: string | ArrayBuffer | File | Blob | Uint8Array<ArrayBufferLike>

    STEP 文件,以文本、ArrayBuffer、Uint8Array、File 或 Blob 表示;gzip 压缩的 .stpz 内容会自动解包。

    undefined
    
    readColors: boolean

    为 true 时,从文件读取颜色;带颜色的 glTF 需要它。

    true
    
    readNames: boolean

    为 true 时,从文件读取零件名称;不需要名称时关闭它以加快解析。

    true
    
    readMaterials: boolean

    为 true 时,从文件读取材质;glTF 中的材质属性需要它。

    true
    
    readLayers: boolean

    为 true 时,从文件读取图层信息;glTF 很少需要。

    false
    
    readProps: boolean

    为 true 时,从文件读取验证属性;glTF 很少需要。

    false
    
    meshDeflection: number

    三角形贴合曲面的紧密程度:meshRelative 为 true 时是每条边长度的分数,否则是以模型单位表示的绝对距离。

    0.005
    

    0.0001

    10

    0.001

    meshAngle: number

    相邻三角形法线之间的最大夹角,以弧度为单位;越小曲线越光滑,三角形也越多。

    0.5
    

    0.01

    3.14159

    0.1

    meshParallel: boolean

    为 true 时,在构建允许的情况下用多个线程对面进行网格化。

    true
    
    faceCountThreshold: number

    面数超过此值时,装配体逐个实体网格化以节省内存;-1 一次网格化所有内容,这是最快的。

    -1
    

    -1

    500000

    10000

    meshRelative: boolean

    为 true 时,meshDeflection 随每个零件的尺寸缩放,使小紧固件和大外壳都能良好网格化;为 false 时它是绝对距离。

    true
    
    internalVerticesMode: boolean

    为 true 时,在弯曲的面内部添加额外顶点以更紧密地贴合,代价是速度。

    false
    
    controlSurfaceDeflection: boolean

    为 true 时,额外一遍处理细化超出精度的凸起三角形,代价是速度。

    false
    
    mergeFaces: boolean

    为 true 时,零件的各面被合并成一个网格,这会使文件更小。

    true
    
    splitIndices16: boolean

    为 true 时,合并后的网格在可容纳的情况下使用 16 位索引,这会使文件更小。

    true
    
    parallelWrite: boolean

    为 true 时,glTF 用多个线程写出,这对大文件有帮助。

    true
    
    embedTextures: boolean

    为 true 时,纹理嵌入 GLB 中,而不是作为单独文件引用。

    true
    
    forceUVExport: boolean

    为 true 时,即使网格没有纹理也写出纹理坐标。

    false
    
    nodeNameFormat: gltfNameFormatEnum

    glTF 节点按什么命名:实例、产品、二者组合,或不命名。

    instance
    
    meshNameFormat: gltfNameFormatEnum

    glTF 网格按什么命名:实例、产品、二者组合,或不命名。

    instance
    
    transformFormat: gltfTransformFormatEnum

    节点放置的写法:compact 在可能时写为平移、旋转和缩放,mat4 始终写为矩阵,trs 始终写为三个部分。

    compact
    
    adjustZtoY: boolean

    为 true 时,文件的 Z 向上被转为 glTF 的 Y 向上;false 保持 Z 向上。

    true
    
    scale: number

    应用于整个模型的系数,例如 0.001 将毫米转为米;1 保持大小不变。

    1.0
    

    0.000001

    1000000

    0.001