slot 0.0.1
A real time UI render framework
载入中...
搜索中...
未找到
Public 属性 | 所有成员列表
gfx::ITextureResource::SubresourceData结构体 参考

#include <slang-gfx.h>

Public 属性

void const * data
 Pointer to texel data for the subresource tensor.
 
gfx::Size strideY
 
gfx::Size strideZ
 

详细描述

Data for a single subresource of a texture.

Each subresource is a tensor with 1 <= rank <= 3, where the rank is deterined by the base shape of the texture (Buffer, 1D, 2D, 3D, or Cube). For the common case of a 2D texture, rank == 2 and each subresource is a 2D image.

Subresource tensors must be stored in a row-major layout, so that the X axis strides over texels, the Y axis strides over 1D rows of texels, and the Z axis strides over 2D "layers" of texels.

For a texture with multiple mip levels or array elements, each mip level and array element is stores as a distinct subresource. When indexing into an array of subresources, the index of a subresoruce for mip level m and array index a is m + a*mipLevelCount.

类成员变量说明

◆ data

void const* gfx::ITextureResource::SubresourceData::data

Pointer to texel data for the subresource tensor.

◆ strideY

gfx::Size gfx::ITextureResource::SubresourceData::strideY

Stride in bytes between rows of the subresource tensor.

This is the number of bytes to add to a pointer to a texel at (X,Y,Z) to get to a texel at (X,Y+1,Z).

Devices may not support all possible values for strideY. In particular, they may only support strictly positive strides.

◆ strideZ

gfx::Size gfx::ITextureResource::SubresourceData::strideZ

Stride in bytes between layers of the subresource tensor.

This is the number of bytes to add to a pointer to a texel at (X,Y,Z) to get to a texel at (X,Y,Z+1).

Devices may not support all possible values for strideZ. In particular, they may only support strictly positive strides.


该结构体的文档由以下文件生成: