[1/2] msvfw32: Derive frame dimension from bitmap info when not available
Bruno Jesus
00cpxxx at gmail.com
Sat Oct 31 12:22:46 CDT 2015
Signed-off-by: Bruno Jesus <00cpxxx at gmail.com>
Otherwise -1,-1 will be passed to StrechBlt.
Fixes bug https://bugs.winehq.org/show_bug.cgi?id=9032 and also
CamStudio Player.
-------------- next part --------------
---
dlls/msvfw32/drawdib.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/dlls/msvfw32/drawdib.c b/dlls/msvfw32/drawdib.c
index a6af90f..e96b0f2 100644
--- a/dlls/msvfw32/drawdib.c
+++ b/dlls/msvfw32/drawdib.c
@@ -347,7 +347,14 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd, HDC hdc,
#undef CHANGED
- if ((dxDst == -1) && (dyDst == -1))
+ /* If source dimensions are not specified derive them from bitmap header */
+ if (dxSrc == -1 && dySrc == -1)
+ {
+ dxSrc = lpbi->biWidth;
+ dySrc = lpbi->biHeight;
+ }
+ /* If destination dimensions are not specified derive them from source */
+ if (dxDst == -1 && dyDst == -1)
{
dxDst = dxSrc;
dyDst = dySrc;
--
2.1.4
More information about the wine-patches
mailing list