LLGL 0.05 Beta
Loading...
Searching...
No Matches
LLGL::TextureLocation Struct Reference

Texture location structure: MIP-map level and offset. More...

#include <TextureFlags.h>

Public Member Functions

 TextureLocation ()=default
 TextureLocation (const Offset3D &offset, std::uint32_t arrayLayer=0, std::uint32_t mipLevel=0)
 Constructor to initialize all attributes.

Public Attributes

Offset3D offset
 Zero-based offset within the texture data.
std::uint32_t arrayLayer = 0
 Zero-based array layer index.
std::uint32_t mipLevel = 0
 MIP-map level for the sub-texture, where 0 is the base texture, and N > 0 is the N-th MIP-map level. By default 0.

Detailed Description

Texture location structure: MIP-map level and offset.

Remarks
This is used to specify the source and destination location of a texture copy operation.
See also
CommandBuffer::CopyTexture
TextureRegion

Constructor & Destructor Documentation

◆ TextureLocation() [1/2]

LLGL::TextureLocation::TextureLocation ( )
default

◆ TextureLocation() [2/2]

LLGL::TextureLocation::TextureLocation ( const Offset3D & offset,
std::uint32_t arrayLayer = 0,
std::uint32_t mipLevel = 0 )
inline

Constructor to initialize all attributes.

Member Data Documentation

◆ arrayLayer

std::uint32_t LLGL::TextureLocation::arrayLayer = 0

Zero-based array layer index.

Remarks
Only used by array texture types (i.e. TextureType::Texture1DArray, TextureType::Texture2DArray, TextureType::TextureCubeArray, and TextureType::Texture2DMSArray).
This field is ignored by all other texture types.
See also
TextureDescriptor::arrayLayers

◆ mipLevel

std::uint32_t LLGL::TextureLocation::mipLevel = 0

MIP-map level for the sub-texture, where 0 is the base texture, and N > 0 is the N-th MIP-map level. By default 0.

See also
TextureDescriptor::mipLevels

◆ offset

Offset3D LLGL::TextureLocation::offset

Zero-based offset within the texture data.

Remarks
Any component of this field that is not meant for the respective texture type is ignored. All other components must be greater than or equal to zero.

The documentation for this struct was generated from the following file: