Piotr Caban piotr@codeweavers.com wrote:
- hr = IWICBitmapFrameDecode_QueryInterface(frame, &IID_IWICBitmapSource, (void**)&bmp_source);
- if(FAILED(hr))
return hr;
- hr = IWICBitmapSource_GetSize(bmp_source, width, height);
- IWICBitmapSource_Release(bmp_source);
What's wrong with calling appropriate IWICBitmapFrameDecode method directly?
Dmitry Timoshkov dmitry@baikal.ru wrote:
Piotr Caban piotr@codeweavers.com wrote:
- hr = IWICBitmapFrameDecode_QueryInterface(frame, &IID_IWICBitmapSource, (void**)&bmp_source);
- if(FAILED(hr))
return hr;
- hr = IWICBitmapSource_GetSize(bmp_source, width, height);
- IWICBitmapSource_Release(bmp_source);
What's wrong with calling appropriate IWICBitmapFrameDecode method directly?
Besides, GpBitmap already has this values cached.
On 03/12/15 05:33, Dmitry Timoshkov wrote:
Dmitry Timoshkov dmitry@baikal.ru wrote:
Piotr Caban piotr@codeweavers.com wrote:
- hr = IWICBitmapFrameDecode_QueryInterface(frame, &IID_IWICBitmapSource, (void**)&bmp_source);
- if(FAILED(hr))
return hr;
- hr = IWICBitmapSource_GetSize(bmp_source, width, height);
- IWICBitmapSource_Release(bmp_source);
What's wrong with calling appropriate IWICBitmapFrameDecode method directly?
I'll remove the QueryInterface call, it's there because I've missed it while copying code from original decode_image_wic function. Thanks for spotting it.
Besides, GpBitmap already has this values cached.
Every frame of GIF may have different size, whole image size is not changing.
Thanks, Piotr