mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 21:53:06 +00:00
Fixing smaller bugs in dx after some analyzing how vmware drv works.
1. vmware drv do not implement DrvGetDirectDrawInfo that show windows 2000/XP/2003 that mean u are not force to implement this api in the drv, only INDEX_DrvEnableDirectDraw and INDEX_DrvDisableDirectDraw are req to be implement in the driver. svn path=/trunk/; revision=26164
This commit is contained in:
parent
3907b65ae1
commit
34713168d4
2 changed files with 83 additions and 76 deletions
|
@ -85,6 +85,9 @@ intEnableDriver(PDD_DIRECTDRAW pDirectDraw)
|
||||||
* but we get back how many pvmList it whant we should alloc, same
|
* but we get back how many pvmList it whant we should alloc, same
|
||||||
* with pdwFourCC.
|
* with pdwFourCC.
|
||||||
*/
|
*/
|
||||||
|
if (pDirectDraw->DrvGetDirectDrawInfo)
|
||||||
|
{
|
||||||
|
DPRINT1("if u are using vmware driver and see this msg, please repot this\n");
|
||||||
success = pDirectDraw->DrvGetDirectDrawInfo( pDirectDraw->Global.dhpdev,
|
success = pDirectDraw->DrvGetDirectDrawInfo( pDirectDraw->Global.dhpdev,
|
||||||
&HalInfo,
|
&HalInfo,
|
||||||
&pDirectDraw->dwNumHeaps,
|
&pDirectDraw->dwNumHeaps,
|
||||||
|
@ -99,7 +102,6 @@ intEnableDriver(PDD_DIRECTDRAW pDirectDraw)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* The driver are not respnose to alloc the memory for pvmList
|
/* The driver are not respnose to alloc the memory for pvmList
|
||||||
* but it is win32k responsible todo, Windows 9x it is gdi32.dll
|
* but it is win32k responsible todo, Windows 9x it is gdi32.dll
|
||||||
*/
|
*/
|
||||||
|
@ -125,7 +127,6 @@ intEnableDriver(PDD_DIRECTDRAW pDirectDraw)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
success = pDirectDraw->DrvGetDirectDrawInfo( pDirectDraw->Global.dhpdev,
|
success = pDirectDraw->DrvGetDirectDrawInfo( pDirectDraw->Global.dhpdev,
|
||||||
&HalInfo,
|
&HalInfo,
|
||||||
&pDirectDraw->dwNumHeaps,
|
&pDirectDraw->dwNumHeaps,
|
||||||
|
@ -177,6 +178,7 @@ intEnableDriver(PDD_DIRECTDRAW pDirectDraw)
|
||||||
/* Copy it to user mode pointer the data */
|
/* Copy it to user mode pointer the data */
|
||||||
RtlCopyMemory(&pDirectDraw->Hal, &HalInfo, sizeof(DD_HALINFO));
|
RtlCopyMemory(&pDirectDraw->Hal, &HalInfo, sizeof(DD_HALINFO));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
success = pDirectDraw->EnableDirectDraw( pDirectDraw->Global.dhpdev,
|
success = pDirectDraw->EnableDirectDraw( pDirectDraw->Global.dhpdev,
|
||||||
&pDirectDraw->DD,
|
&pDirectDraw->DD,
|
||||||
|
@ -217,8 +219,7 @@ NtGdiDdCreateDirectDrawObject(HDC hdc)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* test see if drv got a dx interface or not */
|
/* test see if drv got a dx interface or not */
|
||||||
if (( pDC->DriverFunctions.GetDirectDrawInfo == NULL) ||
|
if ( ( pDC->DriverFunctions.DisableDirectDraw == NULL) ||
|
||||||
( pDC->DriverFunctions.DisableDirectDraw == NULL) ||
|
|
||||||
( pDC->DriverFunctions.EnableDirectDraw == NULL))
|
( pDC->DriverFunctions.EnableDirectDraw == NULL))
|
||||||
{
|
{
|
||||||
DC_UnlockDc(pDC);
|
DC_UnlockDc(pDC);
|
||||||
|
|
|
@ -83,6 +83,12 @@ DWORD STDCALL NtGdiDdBlt(
|
||||||
|
|
||||||
Blt.ddRVal = DDERR_GENERIC;
|
Blt.ddRVal = DDERR_GENERIC;
|
||||||
|
|
||||||
|
/* MSDN say this member is always set to FALSE in windows 2000 or higher */
|
||||||
|
Blt.IsClipped = FALSE;
|
||||||
|
|
||||||
|
/* MSDN say this member is always unuse in windows 2000 or higher */
|
||||||
|
Blt.dwROPFlags = 0;
|
||||||
|
|
||||||
if (pDirectDraw->Surf.dwFlags & DDHAL_SURFCB32_BLT)
|
if (pDirectDraw->Surf.dwFlags & DDHAL_SURFCB32_BLT)
|
||||||
{
|
{
|
||||||
Blt.lpDD = &pDirectDraw->Global;
|
Blt.lpDD = &pDirectDraw->Global;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue