Attention: Here be dragons

This is the latest (unstable) version of this documentation, which may document features not available in or compatible with released stable versions of Godot.

RDTextureFormat

Inherits: RefCounted < Object

Texture format (used by RenderingDevice).

Description

This object is used by RenderingDevice.

Properties

int

array_layers

1

int

depth

1

DataFormat

format

8

int

height

1

int

mipmaps

1

TextureSamples

samples

0

TextureType

texture_type

1

BitField[TextureUsageBits]

usage_bits

0

int

width

1

Methods

void

add_shareable_format(format: DataFormat)

void

remove_shareable_format(format: DataFormat)


Property Descriptions

int array_layers = 1

  • void set_array_layers(value: int)

  • int get_array_layers()

The number of layers in the texture. Only relevant for 2D texture arrays.


int depth = 1

  • void set_depth(value: int)

  • int get_depth()

The texture's depth (in pixels). This is always 1 for 2D textures.


DataFormat format = 8

The texture's pixel data format.


int height = 1

  • void set_height(value: int)

  • int get_height()

The texture's height (in pixels).


int mipmaps = 1

  • void set_mipmaps(value: int)

  • int get_mipmaps()

The number of mipmaps available in the texture.


TextureSamples samples = 0

The number of samples used when sampling the texture.


TextureType texture_type = 1

The texture type.


BitField[TextureUsageBits] usage_bits = 0

The texture's usage bits, which determine what can be done using the texture.


int width = 1

  • void set_width(value: int)

  • int get_width()

The texture's width (in pixels).


Method Descriptions

void add_shareable_format(format: DataFormat)

There is currently no description for this method. Please help us by contributing one!


void remove_shareable_format(format: DataFormat)

There is currently no description for this method. Please help us by contributing one!


User-contributed notes

Please read the User-contributed notes policy before submitting a comment.