Last updated 1 month ago
Retrieves the TextureData of specific TextureConfig by its id.
getTextureData( textureId: string ): Promise<TextureData>
textureId
Id of a that can be retrieved from a specific texture channel.
string
Usage:
const mat = await api.getActiveMaterial('Box'); const tid = mat.properties.colorConfig.texture.id; const textureData = await api.getTextureData(tid);
Return value:
{ "image": {ArrayBuffer}, "width": 2048, "height": 2048 }