• listTextureChannels(texture: Texture): TextureChannel[]
  • Returns a list of TextureChannels used by the given texture. Determination is based only on the role of the textures, e.g. a texture used for the occlusionTexture will have (at least) a red channel in use. See getTextureChannelMask for bitmask alternative.


    const channels = listTextureChannels(texture);
    if (channels.includes(TextureChannel.R)) {
      console.log('texture red channel used');
Function symbol, where the argument and output are a box labeled 'glTF'.

Made by Don McCurdy Documented with greendoc © 2023 MIT License