Material
Python API types
Read time 9 minutesLast updated 16 hours ago
BlurFilter
Enum of core.IntName | Value |
|---|---|
| Box | 0 |
| Gaussian | 1 |
CoeffOrTexture
Select between:- coeff: core.Coeff
- texture: material.Texture Functions accepting this type or a list of this type as a parameter:
- material.setCoeffOrTextureProperty
ColorMaterialInfos
FieldsType | Name | Default | Description |
|---|---|---|---|
| name | Core.String | ||
| color | ColorAlpha |
ColorOrTexture
Select between:- color: core.Color
- texture: material.Texture Functions accepting this type or a list of this type as a parameter:
- material.setColorOrTextureProperty
CustomMaterialPattern
A Custom MaterialPattern is an entity which defines an abstract custom Shader. It is used by the Materials. Base class: core.Entity- material.addUniformProperty
- material.getUniformPropertyType
- material.setFragmentShader
- material.setVertexShader
- core.cloneEntity
- core.deleteEntities
- core.entityExists
- core.getEntityType
- core.getEntityTypeString
- core.addCustomProperties
- core.addCustomProperty
- core.getProperties
- core.getProperty
- core.getPropertyInfo
- core.hasCustomProperty
- core.hasProperty
- core.listProperties
- core.listPropertiesBatch
- core.removeCustomProperty
- core.setProperties
- core.setProperty
- core.supportCustomProperties
- core.unsetProperty
- scene.linkPropertyToAnimation
- scene.unlinkPropertyToAnimation
EdgeFilter
Enum of core.IntName | Value |
|---|---|
| Clamp | 0 |
| Extend | 1 |
| Repeat | 2 |
| Mirror | 3 |
- material.blurImage
- material.getImageColorBilinear
- material.rotateImage
- material.setSubImage
- material.stretchImage
- material.transformImage
- material.translateImage
Image
An Image is an entity which represents an image in the Image library. Base class: core.Entity- algo.convertNormalMap
- algo.fillNormalMap
- algo.orientNormalMap
- material.convertHeightMapToNormalMap
- material.filterAO
- material.remapIndexMap
- material.applyFactorOnImage
- material.blurImage
- material.clearImageRoI
- material.convertFloat32To8BitsImage
- material.convertImage
- material.convertImageToDefinition
- material.exportImage
- material.extractImageChannels
- material.extractImageComponents
- material.fillImageWithColor
- material.fillUnusedPixels
- material.flipImageY
- material.getImageColorBilinear
- material.getImageColorRange
- material.getImageComponentType
- material.getImageDefinition
- material.getImageDefinitions
- material.getImageLayout
- material.getImagePixelColor
- material.getImagePixelInfo
- material.getImageRoI
- material.getImageSize
- material.getImagesSizes
- material.getSubImage
- material.invertImageColor
- material.overrideImageFormat
- material.resizeImage
- material.rotateImage
- material.setImageRoI
- material.setSubImage
- material.stretchImage
- material.transformImage
- material.translateImage
- material.updateImageFromDefinition
- material.updateImagesFromDefinitions
- scene.mergeImages
- core.cloneEntity
- core.deleteEntities
- core.entityExists
- core.getEntityType
- core.getEntityTypeString
- core.addCustomProperties
- core.addCustomProperty
- core.getProperties
- core.getProperty
- core.getPropertyInfo
- core.hasCustomProperty
- core.hasProperty
- core.listProperties
- core.listPropertiesBatch
- core.removeCustomProperty
- core.setProperties
- core.setProperty
- core.supportCustomProperties
- core.unsetProperty
- scene.linkPropertyToAnimation
- scene.unlinkPropertyToAnimation
ImageChangeType
Enum of core.LongName | Value |
|---|---|
| ADDED | 0 |
| REMOVED | 1 |
| CHANGED | 2 |
| RESET | 3 |
| REPLACED | 4 |
ImageComponentType
Enum of core.IntName | Value |
|---|---|
| Undefined | 0 |
| UInt8_Norm | 1 |
| UInt8_Int | 2 |
| SInt8_Norm | 3 |
| SInt8_Int | 4 |
| UInt16_Norm | 5 |
| UInt16_Int | 6 |
| SInt16_Norm | 7 |
| SInt16_Int | 8 |
| Float16 | 9 |
| UInt32_Norm | 10 |
| UInt32_Int | 11 |
| SInt32_Norm | 12 |
| SInt32_Int | 13 |
| Float32 | 14 |
| UInt64_Norm | 15 |
| UInt64_Int | 16 |
| SInt64_Norm | 17 |
| SInt64_Int | 18 |
| Float64 | 19 |
- material.convertImage
- material.convertImageToDefinition
- material.createCheckerboardImage
- material.getImageComponentTypeName
- material.getImageFormatName
- material.getImagePixelInfoFromLayoutAndType
- material.overrideImageFormat
ImageDefinition
FieldsType | Name | Default | Description |
|---|---|---|---|
| id | Image | 0 | |
| name | Core.String | ||
| width | Core.Int | 0 | |
| height | Core.Int | 0 | |
| layout | ImageLayout | RGBA | |
| type | ImageComponentType | UInt8_Norm | |
| data | ByteList |
- material.createImageFromDefinition
- material.createImagesFromDefinitions
- material.getImagePixelInfoFromDefinition
- material.updateImageFromDefinition
- material.updateImagesFromDefinitions
ImageDefinitionList
List of material.ImageDefinition Functions accepting this type or a list of this type as a parameter:ImageLayout
Enum of core.IntName | Value |
|---|---|
| Undefined | 0 |
| R | 1 |
| G | 2 |
| B | 3 |
| A | 4 |
| RG | 5 |
| RGB | 6 |
| RGBA | 7 |
| BGR | 8 |
| BGRA | 9 |
| ABGR | 10 |
| Lum | 11 |
| LumA | 12 |
- material.convertImage
- material.convertImageToDefinition
- material.createCheckerboardImage
- material.extractImageComponents
- material.getImageFormatName
- material.getImagePixelInfoFromLayoutAndType
- material.overrideImageFormat
ImageList
List of material.Image Functions accepting this type or a list of this type as a parameter:- material.filterAO
- material.remapIndexMap
- material.getImageDefinitions
- material.getImagesSizes
- material.updateImagesFromDefinitions
- scene.mergeImages
ImpostorMaterialInfos
FieldsType | Name | Default | Description |
|---|---|---|---|
| name | Core.String | ||
| albedo | ColorOrTexture | ||
| normal | ColorOrTexture | ||
| roughness | CoeffOrTexture | ||
| ao | CoeffOrTexture | ||
| depth | CoeffOrTexture | ||
| nbFrames | Core.Int | 0 | |
| fullOcta | Core.Boolean | 1 | |
| octaDiameter | Core.Double | 1.0 | |
| linearSteps | Core.Int | 30 | |
| binarySteps | Core.Int | 1 |
Material
The Material is an Entity that contains visual definition that can be applied to the Components of the scene. Base class: core.Entity- algo.filletMesh
- algo.removeHoles
- algo.remeshSurfacicHoles
- cad.setFaceMaterial
- cad.setEdgeMaterial
- material.areOpaques
- material.copyMaterial
- material.getColorMaterialInfos
- material.getCustomMaterialPattern
- material.getImpostorMaterialInfos
- material.getMaterialDefinition
- material.getMaterialDefinitions
- material.getMaterialMainColor
- material.getMaterialPattern
- material.getMaterialPatternType
- material.getPBRMaterialInfos
- material.getStandardMaterialInfos
- material.getUnlitTextureMaterialInfos
- material.isOpaque
- material.makeMaterialNamesUnique
- material.setCoeffOrTextureProperty
- material.setColorAlphaProperty
- material.setColorOrTextureProperty
- material.setMaterialMainColor
- material.setMaterialPattern
- material.setPBRMaterialInfos
- material.getAllImages
- material.getMaterialUserData
- material.getMultipleMaterialUserData
- material.hasMaterialUserData
- material.hasMultipleMaterialUserData
- material.setMaterialUserData
- material.setMultipleMaterialUserData
- material.unsetMaterialUserData
- material.unsetMultipleMaterialUserData
- scene.convertMaterialsToColor
- scene.convertMaterialsToPBR
- scene.mergeMaterials
- scene.replaceMaterial
- scene.setOccurrenceMaterial
- scene.findOccurrencesByMaterial
- scene.findPartOccurrencesByActiveMaterial
- scene.findPartOccurrencesByVisibleMaterial
- scene.setSubpartMaterial
- scene.setSubpartMaterials
- scene.addMeshToAnnotation
- core.cloneEntity
- core.deleteEntities
- core.entityExists
- core.getEntityType
- core.getEntityTypeString
- core.addCustomProperties
- core.addCustomProperty
- core.getProperties
- core.getProperty
- core.getPropertyInfo
- core.hasCustomProperty
- core.hasProperty
- core.listProperties
- core.listPropertiesBatch
- core.removeCustomProperty
- core.setProperties
- core.setProperty
- core.supportCustomProperties
- core.unsetProperty
- scene.linkPropertyToAnimation
- scene.unlinkPropertyToAnimation
MaterialChangeType
Enum of core.LongName | Value |
|---|---|
| CHANGED | 0 |
| PATTERN_CHANGED | 1 |
| RELOAD | 2 |
| DESTROYED | 3 |
| ICON_CHANGED | 4 |
| ADDED | 5 |
| REMOVED | 6 |
MaterialDefinition
FieldsType | Name | Default | Description |
|---|---|---|---|
| name | Core.String | ||
| id | Material | 0 | |
| albedo | ColorOrTexture | ||
| normal | ColorOrTexture | ||
| metallic | CoeffOrTexture | ||
| roughness | CoeffOrTexture | ||
| ao | CoeffOrTexture | ||
| opacity | CoeffOrTexture | ||
| emissive | ColorOrTexture |
MaterialDefinitionList
List of material.MaterialDefinition Functions accepting this type or a list of this type as a parameter:MaterialFromMapsReturn
FieldsType | Name | Default | Description |
|---|---|---|---|
| importedTextureCount | Core.Int | 0 | Number of newly imported textures. |
| createdMaterialCount | Core.Int | 0 | Number of newly created materials. |
| updatedMaterialCount | Core.Int | 0 |
MaterialList
List of material.Material Functions accepting this type or a list of this type as a parameter:- material.areOpaques
- material.getMaterialDefinitions
- material.makeMaterialNamesUnique
- material.getAllImages
- material.getMultipleMaterialUserData
- material.hasMultipleMaterialUserData
- material.setMultipleMaterialUserData
- material.unsetMultipleMaterialUserData
- scene.convertMaterialsToColor
- scene.convertMaterialsToPBR
- scene.mergeMaterials
- scene.setSubpartMaterials
- scene.setSubpartVariantMaterialsList
MaterialListList
List of material.MaterialList Functions accepting this type or a list of this type as a parameter:MaterialPatternType
Enum of core.IntName | Value |
|---|---|
| CUSTOM | 0 |
| COLOR | 1 |
| STANDARD | 2 |
| UNLIT_TEXTURE | 3 |
| PBR | 4 |
| IMPOSTOR | 5 |
| LINE | 6 |
MaterialUserData
Identifier of materials userdata. Base class: core.Ident- material.getMaterialUserData
- material.getMultipleMaterialUserData
- material.hasMaterialUserData
- material.hasMultipleMaterialUserData
- material.setMaterialUserData
- material.setMultipleMaterialUserData
- material.unsetMaterialUserData
- material.unsetMultipleMaterialUserData
- material.unsubscribeFromMaterialUserData
PBRMaterialInfos
FieldsType | Name | Default | Description |
|---|---|---|---|
| name | Core.String | ||
| albedo | ColorOrTexture | ||
| normal | ColorOrTexture | ||
| metallic | CoeffOrTexture | ||
| roughness | CoeffOrTexture | ||
| ao | CoeffOrTexture | ||
| opacity | CoeffOrTexture |
PixelInfo
FieldsType | Name | Default | Description |
|---|---|---|---|
| layout | ImageLayout | Undefined | |
| type | ImageComponentType | Undefined | |
| componentCount | Core.Int | 0 | |
| bitsPerComponent | Core.Int | 0 | |
| bytesPerComponent | Core.Int | 0 | |
| bytesPerPixel | Core.Int | 0 | |
| isFloat | Boolean | False | |
| isSigned | Boolean | False | |
| isNormalized | Boolean | False |
ResizeFilterMethod
Enum of core.IntName | Value |
|---|---|
| DEFAULT | 0 |
| BOX | 1 |
| TRIANGLE | 2 |
| CUBICBSPLINE | 3 |
| CATMULLROM | 4 |
| MITCHELL | 5 |
RoI
FieldsType | Name | Default | Description |
|---|---|---|---|
| x | Core.Int | 0 | |
| y | Core.Int | 0 | |
| w | Core.Int | 0 | |
| h | Core.Int | 0 |
ShaderUniformType
The possible types of shader uniform parameters. Enum of core.LongName | Value |
|---|---|
| INTEGER | 2 |
| BOOLEAN | 9 |
| REAL | 11 |
| COEFF | 13 |
| POINT3 | 23 |
| POINT2 | 22 |
| COLOR | 15 |
| COLOR_ALPHA | 16 |
| TEXTURE | 34 |
| COLORORTEXTURE | 35 |
| COEFFORTEXTURE | 36 |
StandardMaterialInfos
FieldsType | Name | Default | Description |
|---|---|---|---|
| name | Core.String | ||
| diffuse | ColorOrTexture | ||
| specular | ColorOrTexture | ||
| ambient | ColorOrTexture | ||
| emissive | ColorOrTexture | ||
| shininess | Coeff | 0.0 | |
| transparency | Coeff | 0.0 |
Texture
FieldsType | Name | Default | Description |
|---|---|---|---|
| image | Image | 0 | |
| channel | Core.Int | 0 | |
| offset | Point2 | ||
| tilling | Point2 |
UnlitTextureMaterialInfos
FieldsType | Name | Default | Description |
|---|---|---|---|
| name | Core.String | ||
| texture | Texture |