mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
Do not trust msdn what it say about dwContext in any struct "MSDN : it is not in use for windows nt", "My note: it is in use for all os, and it always point to DDRAWI_DIRECTDRAW_GBL.hDD and we doing that. now the callbacks works in startup process.
svn path=/trunk/; revision=18855
This commit is contained in:
parent
d4b6cf2ab1
commit
8ad9c2cb4c
1 changed files with 13 additions and 6 deletions
|
@ -131,9 +131,17 @@ HRESULT Hal_DirectDraw_Initialize (LPDIRECTDRAW7 iface)
|
||||||
|
|
||||||
/* Todo add a check see if HalInfo.GetDriverInfo is supported or not */
|
/* Todo add a check see if HalInfo.GetDriverInfo is supported or not */
|
||||||
|
|
||||||
|
/* Do not trust msdn what it say about dwContext it is not in use for
|
||||||
|
windows nt, it is in use for all os, and it always pont to
|
||||||
|
DirectDrawGlobal.hDD */
|
||||||
|
|
||||||
DDHAL_GETDRIVERINFODATA DriverInfo;
|
DDHAL_GETDRIVERINFODATA DriverInfo;
|
||||||
memset(&DriverInfo,0, sizeof(DDHAL_GETDRIVERINFODATA));
|
memset(&DriverInfo,0, sizeof(DDHAL_GETDRIVERINFODATA));
|
||||||
DriverInfo.dwSize = sizeof(DDHAL_GETDRIVERINFODATA);
|
DriverInfo.dwSize = sizeof(DDHAL_GETDRIVERINFODATA);
|
||||||
|
DriverInfo.dwContext = DirectDrawGlobal.hDD;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* Get ColorControlCallbacks */
|
/* Get ColorControlCallbacks */
|
||||||
DriverInfo.guidInfo = GUID_ColorControlCallbacks;
|
DriverInfo.guidInfo = GUID_ColorControlCallbacks;
|
||||||
|
@ -207,12 +215,12 @@ HRESULT Hal_DirectDraw_Initialize (LPDIRECTDRAW7 iface)
|
||||||
|
|
||||||
|
|
||||||
/* Get the KernelCaps */
|
/* Get the KernelCaps */
|
||||||
/*
|
/* Need Alloc memmory for lpDDKernelCaps ?? */
|
||||||
DriverInfo.guidInfo = GUID_KernelCaps;
|
DriverInfo.guidInfo = GUID_KernelCaps;
|
||||||
DriverInfo.lpvData = &misc;
|
DriverInfo.lpvData = &This->DirectDrawGlobal.lpDDKernelCaps;
|
||||||
DriverInfo.dwExpectedSize = sizeof(DDHAL_DDMISCELLANEOUSCALLBACKS);
|
DriverInfo.dwExpectedSize = sizeof(DDHAL_DDKERNELCALLBACKS);
|
||||||
This->HalInfo.GetDriverInfo( &DriverInfo);
|
This->HalInfo.GetDriverInfo( &DriverInfo);
|
||||||
*/
|
|
||||||
|
|
||||||
/* Get the MiscellaneousCallbacks */
|
/* Get the MiscellaneousCallbacks */
|
||||||
DriverInfo.guidInfo = GUID_MiscellaneousCallbacks;
|
DriverInfo.guidInfo = GUID_MiscellaneousCallbacks;
|
||||||
|
@ -229,8 +237,7 @@ HRESULT Hal_DirectDraw_Initialize (LPDIRECTDRAW7 iface)
|
||||||
This->HalInfo.GetDriverInfo( &DriverInfo);
|
This->HalInfo.GetDriverInfo( &DriverInfo);
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Get the MotionCompCallbacks */
|
/* Get the MotionCompCallbacks */
|
||||||
|
|
||||||
DriverInfo.guidInfo = GUID_MotionCompCallbacks;
|
DriverInfo.guidInfo = GUID_MotionCompCallbacks;
|
||||||
DriverInfo.lpvData = &This->DirectDrawGlobal.lpDDCBtmp->HALDDMotionComp;
|
DriverInfo.lpvData = &This->DirectDrawGlobal.lpDDCBtmp->HALDDMotionComp;
|
||||||
DriverInfo.dwExpectedSize = sizeof(DDHAL_DDMOTIONCOMPCALLBACKS);
|
DriverInfo.dwExpectedSize = sizeof(DDHAL_DDMOTIONCOMPCALLBACKS);
|
||||||
|
|
Loading…
Reference in a new issue