insertTexture MethodStatic
Insert a new texture into a DefinitionModel.
insertTexture(iModelDb: IModelDb, definitionModelId: string, name: string, format: ImageSourceFormat, data: string | Uint8Array, description?: string): string
throws IModelError if unable to insert the element.
see Texture.insertTexture to insert a new texture into the iModel.
| Parameter | Type | Description |
|---|---|---|
| iModelDb | IModelDb | The iModel to contain the texture. |
| definitionModelId | string | The DefinitionModel to contain the texture. |
| name | string | The name to serve as the texture's Code value. |
| format | ImageSourceFormat | The format of the image data. |
| data | string | Uint8Array | The image data in the format specified by format. |
| description | string | An optional description of the texture |
Returns - string
The Id of the newly-inserted texture element.
Defined in
- backend/src/Texture.ts Line 97
Last Updated: 30 November, 2023