TextureLayered

Inherits: Texture < Resource < Reference < Object

Inherited By: Cubemap, CubemapArray, Texture2DArray

Base class for 3D texture types.

Description

Base class for Texture2DArray, Cubemap and CubemapArray. Cannot be used directly, but contains all the functions necessary for accessing the derived resource types. Data is set on a per-layer basis. For Texture2DArrays, the layer specifies the array layer.

Methods

Error create_from_images ( Array images )
Format get_format ( ) const
int get_height ( ) const
Image get_layer_data ( int layer ) const
int get_layers ( ) const
int get_width ( ) const
void update_layer ( Image image, int layer )

Method Descriptions


Returns the current format being used by this texture. See Format for details.


  • int get_height ( ) const

Returns the height of the texture. Height is typically represented by the Y-axis.


  • Image get_layer_data ( int layer ) const

Returns an Image resource with the data from specified layer.


  • int get_layers ( ) const

  • int get_width ( ) const

Returns the width of the texture. Width is typically represented by the X-axis.


  • void update_layer ( Image image, int layer )