Capítulo 223 de 859
Creates a texture directly from raw buffer data.
The interpretation of the data depends on type and format: If the type is UnsignedByteType, a Uint8Array will be useful for addressing the texel data. If the format is RGBAFormat, data needs four values for one texel; Red, Green, Blue and Alpha (typically the opacity).
true, the texture is flipped along the vertical axis when uploaded to the GPU.Constructor
| Signature |
|---|
new DataTexture( data : TypedArray, width : number, height : number, format : number, type : number, mapping : number, wrapS : number, wrapT : number, magFilter : number, minFilter : number, anisotropy : number, colorSpace : string ) |
Properties
| Property | Description |
|---|---|
.flipY : boolean | If set to true, the texture is flipped along the vertical axis when uploaded to the GPU. |
.generateMipmaps : boolean | Whether to generate mipmaps (if possible) for a texture. |
.image : Object | The image definition of a data texture. |
.isDataTexture : boolean (readonly) | This flag can be used for type testing. |
.unpackAlignment : boolean | Specifies the alignment requirements for the start of each pixel row in memory. |