Commit a62bd245 authored by Vincent Povirk's avatar Vincent Povirk Committed by Alexandre Julliard

windowscodecs: Implement IWICBitmap::GetSize.

parent f26402ca
...@@ -266,9 +266,16 @@ static ULONG WINAPI BitmapImpl_Release(IWICBitmap *iface) ...@@ -266,9 +266,16 @@ static ULONG WINAPI BitmapImpl_Release(IWICBitmap *iface)
static HRESULT WINAPI BitmapImpl_GetSize(IWICBitmap *iface, static HRESULT WINAPI BitmapImpl_GetSize(IWICBitmap *iface,
UINT *puiWidth, UINT *puiHeight) UINT *puiWidth, UINT *puiHeight)
{ {
FIXME("(%p,%p,%p)\n", iface, puiWidth, puiHeight); BitmapImpl *This = impl_from_IWICBitmap(iface);
TRACE("(%p,%p,%p)\n", iface, puiWidth, puiHeight);
return E_NOTIMPL; if (!puiWidth || !puiHeight)
return E_INVALIDARG;
*puiWidth = This->width;
*puiHeight = This->height;
return S_OK;
} }
static HRESULT WINAPI BitmapImpl_GetPixelFormat(IWICBitmap *iface, static HRESULT WINAPI BitmapImpl_GetPixelFormat(IWICBitmap *iface,
......
...@@ -256,12 +256,12 @@ todo_wine { ...@@ -256,12 +256,12 @@ todo_wine {
ok(hr == S_OK, "IWICBitmap_GetResolution failed hr=%x\n", hr); ok(hr == S_OK, "IWICBitmap_GetResolution failed hr=%x\n", hr);
ok(dpix == 12.0, "got %f, expected 12.0\n", dpix); ok(dpix == 12.0, "got %f, expected 12.0\n", dpix);
ok(dpiy == 34.0, "got %f, expected 34.0\n", dpiy); ok(dpiy == 34.0, "got %f, expected 34.0\n", dpiy);
}
hr = IWICBitmap_GetSize(bitmap, &width, &height); hr = IWICBitmap_GetSize(bitmap, &width, &height);
ok(hr == S_OK, "IWICBitmap_GetSize failed hr=%x\n", hr); ok(hr == S_OK, "IWICBitmap_GetSize failed hr=%x\n", hr);
ok(width == 3, "got %d, expected 3\n", width); ok(width == 3, "got %d, expected 3\n", width);
ok(height == 3, "got %d, expected 3\n", height); ok(height == 3, "got %d, expected 3\n", height);
}
IWICBitmap_Release(bitmap); IWICBitmap_Release(bitmap);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment