Commit f971902a authored by Peter Riocreux's avatar Peter Riocreux Committed by Alexandre Julliard

Make DrawDibDraw honour the DDF_BACKGROUNDPAL flag.

parent 5106ee4a
...@@ -311,7 +311,7 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd, HDC hdc, ...@@ -311,7 +311,7 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd, HDC hdc,
whdd = MSVIDEO_GetHddPtr(hdd); whdd = MSVIDEO_GetHddPtr(hdd);
if (!whdd) return FALSE; if (!whdd) return FALSE;
if (wFlags & ~(DDF_SAME_HDC | DDF_SAME_DRAW | DDF_NOTKEYFRAME | DDF_UPDATE | DDF_DONTDRAW)) if (wFlags & ~(DDF_SAME_HDC | DDF_SAME_DRAW | DDF_NOTKEYFRAME | DDF_UPDATE | DDF_DONTDRAW | DDF_BACKGROUNDPAL))
FIXME("wFlags == 0x%08lx not handled\n", (DWORD)wFlags); FIXME("wFlags == 0x%08lx not handled\n", (DWORD)wFlags);
if (!lpBits) if (!lpBits)
...@@ -362,7 +362,12 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd, HDC hdc, ...@@ -362,7 +362,12 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd, HDC hdc,
} }
} }
if (!(wFlags & DDF_DONTDRAW) && whdd->hpal) if (!(wFlags & DDF_DONTDRAW) && whdd->hpal)
{
if ((wFlags & DDF_BACKGROUNDPAL) && ! (wFlags & DDF_SAME_HDC))
SelectPalette(hdc, whdd->hpal, TRUE);
else
SelectPalette(hdc, whdd->hpal, FALSE); SelectPalette(hdc, whdd->hpal, FALSE);
}
if (!(StretchBlt(whdd->hdc, xDst, yDst, dxDst, dyDst, whdd->hMemDC, xSrc, ySrc, dxSrc, dySrc, SRCCOPY))) if (!(StretchBlt(whdd->hdc, xDst, yDst, dxDst, dyDst, whdd->hMemDC, xSrc, ySrc, dxSrc, dySrc, SRCCOPY)))
ret = FALSE; ret = FALSE;
......
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