Retrieves the friendly name for a sub-format.
HRESULT GetSubFormatFriendlyName( WICPixelFormatGUID guidPixelFormat, UINT uSubFormatIndex, UINT cchFriendlyName, WCHAR *pwzFriendlyName, UINT *pcchActual );
|
Returns S_OK if successful, or an error value otherwise.
Use this method to get a readable string representation for a (sub-format)/(guidPixelFormat) pair. First call IWICLeadBitmapEncoder::GetSubFormats to get an array of valid sub-formats for the particular LEAD bitmap encoder. When calling the GetSubFormatFriendlyName method, pass the index into the sub-format array as the uSubFormatIndex argument.
Call the GetSubFormatFriendlyName method once to get the length of the friendly name. Allocate the appropriately sized array. Then call the GetSubFormatFriendlyName method again, passing the allocated array as an argument. The example illustrates this technique.
For an example, refer to IWICLeadBitmapEncoder::GetSubFormats