windowscodecs: Fix *_CopyPixels functions to properly handle a NULL rectangle
Krzysztof Nowicki
krissn at op.pl
Sun Oct 17 02:59:03 CDT 2010
W dniu 17.10.2010 01:45, Vincent Povirk pisze:
> +1
>
> + if (!prc)
> + {
> + UINT width, height;
> + hr = IWICBitmapSource_GetSize(This->source,&width,&height);
> + if (FAILED(hr)) return hr;
> + rc.X = 0;
> + rc.Y = 0;
> + rc.Width = width;
> + rc.Height = height;
> + prc =&rc;
> + }
>
> Any reason you didn't use this approach in the other functions?
>
>
>
I don't know really. Doing a memcpy to a local rectangle seems a more
natural way to do it, as I don't really like to modify input arguments.
In this case I guess I just blindly copied an existing solution that I
found later during the review of the other codecs.
If you want I can unify the implementations so that all of them look
like the one above.
More information about the wine-devel
mailing list