IWICDdsEncoder::CreateNewFrame method (wincodec.h)

Creates a new frame to encode.


HRESULT CreateNewFrame(
  [out]           IWICBitmapFrameEncode **ppIFrameEncode,
  [out, optional] UINT                  *pArrayIndex,
  [out, optional] UINT                  *pMipLevel,
  [out, optional] UINT                  *pSliceIndex


[out] ppIFrameEncode

A pointer to the newly created frame object.

[out, optional] pArrayIndex

Points to the location where the array index is returned.

[out, optional] pMipLevel

Points to the location where the mip level index is returned.

[out, optional] pSliceIndex

Points to the location where the slice index is returned.

Return value

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.


This is equivalent to IWICBitmapEncoder::CreateNewFrame, but returns additional information about the array index, mip level and slice of the newly created frame. In contrast to IWICBitmapEncoder::CreateNewFrame, there is no IPropertyBag2* parameter because individual DDS frames do not have separate properties.


Minimum supported client Windows 8.1 [desktop apps | UWP apps]
Minimum supported server Windows Server 2012 R2 [desktop apps | UWP apps]
Target Platform Windows
Header wincodec.h
Library Windowscodecs.lib
DLL Windowscodecs.dll

See also