LoaderDataTextureLoader

TGALoader

A loader for the TGA texture format.

Code Example

const loader = new TGALoader();
const texture = await loader.loadAsync( 'textures/crate_color8.tga' );
texture.colorSpace = THREE.SRGBColorSpace; // only for color textures

Import

TGALoader is an addon, and must be imported explicitly, see Installation#Addons.

import { TGALoader } from 'three/addons/loaders/TGALoader.js';

Constructor

new TGALoader( manager : LoadingManager )

Constructs a new TGA loader.

manager

The loading manager.

Methods

.parse( buffer : ArrayBuffer ) : DataTextureLoader~TexData

Parses the given TGA texture data.

buffer

The raw texture data.

Overrides: DataTextureLoader#parse
Returns: An object representing the parsed texture data.

Source

examples/jsm/loaders/TGALoader.js