ScratchImage::Initialize2D Method

Initializes a 2D ScratchImage.

Syntax

public:
HRESULT Initialize2D(
         DXGI_FORMAT fmt,
         size_t width,
         size_t height,
         size_t arraySize,
         size_t mipLevels
)  

Parameters

fmt
Type: DXGI_FORMAT 

[in] One member of the DXGI_FORMAT enum.

width
Type: size_t 

[in] Width of the texture.

height
Type: size_t 

[in] Height of the texture.

arraySize
Type: size_t 

[in] The number of images.

mipLevels
Type: size_t 

[in] Mip levels.

Return value

Type: HRESULT 

Success or error code.

Requirements

Header: Declared in directxtex.h.