mirror of
https://github.com/reactos/reactos.git
synced 2025-02-23 08:55:19 +00:00
implement DxEngGetDeviceGammaRamp
implement DxEngSetDeviceGammaRamp svn path=/trunk/; revision=31465
This commit is contained in:
parent
290a73238b
commit
8dd1e30e97
4 changed files with 65 additions and 27 deletions
|
@ -441,7 +441,7 @@ Main_DirectDraw_CreateSurface (LPDDRAWI_DIRECTDRAW_INT This, LPDDSURFACEDESC pDD
|
|||
|
||||
DX_WINDBG_trace();
|
||||
|
||||
// EnterCriticalSection(&ddcs);
|
||||
EnterCriticalSection(&ddcs);
|
||||
*ppSurf = NULL;
|
||||
|
||||
_SEH_TRY
|
||||
|
@ -464,8 +464,8 @@ Main_DirectDraw_CreateSurface (LPDDRAWI_DIRECTDRAW_INT This, LPDDSURFACEDESC pDD
|
|||
ret = DDERR_INVALIDPARAMS;
|
||||
}
|
||||
_SEH_END;
|
||||
// LeaveCriticalSection(&ddcs);
|
||||
return ret;
|
||||
LeaveCriticalSection(&ddcs);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
|
@ -476,7 +476,8 @@ Main_DirectDraw_CreateSurface4(LPDDRAWI_DIRECTDRAW_INT This, LPDDSURFACEDESC2 pD
|
|||
{
|
||||
HRESULT ret;
|
||||
DX_WINDBG_trace();
|
||||
// EnterCriticalSection(&ddcs);
|
||||
|
||||
EnterCriticalSection(&ddcs);
|
||||
*ppSurf = NULL;
|
||||
|
||||
_SEH_TRY
|
||||
|
@ -489,7 +490,7 @@ Main_DirectDraw_CreateSurface4(LPDDRAWI_DIRECTDRAW_INT This, LPDDSURFACEDESC2 pD
|
|||
}
|
||||
_SEH_END;
|
||||
|
||||
// LeaveCriticalSection(&ddcs);
|
||||
LeaveCriticalSection(&ddcs);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
@ -67,7 +67,7 @@ HDEV *DxEngEnumerateHdev(HDEV *hdev);
|
|||
|
||||
/* Notes : same protypes NtGdiEngGetDeviceGammaRamp, diffent is we skipp the user mode checks and seh */
|
||||
BOOL
|
||||
DxEngGetDeviceGammaRamp(HDC hDC, LPVOID lpRamp);
|
||||
DxEngGetDeviceGammaRamp(HDEV hPDev, PGAMMARAMP Ramp);
|
||||
|
||||
/* Notes : Lock the hDC */
|
||||
PDC DxEngLockDC(HDC hDC);
|
||||
|
@ -75,7 +75,8 @@ PDC DxEngLockDC(HDC hDC);
|
|||
/* Notes : Unlock the hDC */
|
||||
BOOL DxEngUnlockDC(PDC pDC);
|
||||
|
||||
|
||||
/* Notes : Set Gamma ramp */
|
||||
BOOL DxEngSetDeviceGammaRamp(HDEV hPDev, PGAMMARAMP Ramp, BOOL Unuse);
|
||||
|
||||
/* prototypes are not done yet, I need gather all my notes
|
||||
* to make them correct
|
||||
|
@ -89,7 +90,6 @@ DWORD DxEngUnlockHdev(DWORD x1);
|
|||
DWORD DxEngReferenceHdev(DWORD x1);
|
||||
DWORD DxEngIsHdevLockedByCurrentThread(DWORD x1);
|
||||
DWORD DxEngUnreferenceHdev(DWORD x1);
|
||||
DWORD DxEngSetDeviceGammaRamp(DWORD x1, DWORD x2, DWORD x3);
|
||||
DWORD DxEngSpTearDownSprites(DWORD x1, DWORD x2, DWORD x3);
|
||||
DWORD DxEngSpUnTearDownSprites(DWORD x1, DWORD x2, DWORD x3);
|
||||
DWORD DxEngSpSpritesVisible(DWORD x1);
|
||||
|
|
|
@ -121,5 +121,8 @@ typedef BOOL (NTAPI *PGD_ENGUNLOCKDIRECTDRAWSURFACE)(PDD_SURFACE_LOCAL);
|
|||
} \
|
||||
}
|
||||
|
||||
/* Gammaramp internal prototype */
|
||||
BOOL FASTCALL IntGetDeviceGammaRamp(HDEV hPDev, PGAMMARAMP Ramp);
|
||||
BOOL FASTCALL IntSetDeviceGammaRamp(HDEV hPDev, PGAMMARAMP Ramp);
|
||||
|
||||
#endif /* _INT_W32k_DDRAW */
|
||||
|
|
|
@ -123,16 +123,29 @@ DxEngEnumerateHdev(HDEV *hdev)
|
|||
return FALSE;
|
||||
}
|
||||
|
||||
/************************************************************************/
|
||||
/* DxEngGetDeviceGammaRamp */
|
||||
/************************************************************************/
|
||||
/* same protypes NtGdiEngGetDeviceGammaRamp, diffent is we skipp the user mode checks and seh */
|
||||
/*++
|
||||
* @name DxEngGetDeviceGammaRamp
|
||||
* @implemented
|
||||
*
|
||||
* The function DxEngSetDeviceGammaRamp Set Gamma ramp from from dxg.sys
|
||||
|
||||
* @param HDEV hPDev
|
||||
* The hdev
|
||||
*
|
||||
* @param PGAMMARAMP Ramp
|
||||
* to fill in our gama ramp
|
||||
*
|
||||
* @return
|
||||
* This return FALSE or TRUE, FALSE for fail, TRUE for success
|
||||
*
|
||||
* @remarks.
|
||||
* ReactOS does not loop it, only set the gamma once.
|
||||
*
|
||||
*--*/
|
||||
BOOL
|
||||
DxEngGetDeviceGammaRamp(HDC hDC, LPVOID lpRamp)
|
||||
DxEngGetDeviceGammaRamp(HDEV hPDev, PGAMMARAMP Ramp)
|
||||
{
|
||||
/* FIXME redirect it to NtGdiEngGetDeviceGammaRamp internal call */
|
||||
UNIMPLEMENTED;
|
||||
return FALSE;
|
||||
return IntGetDeviceGammaRamp(hPDev, Ramp);
|
||||
}
|
||||
|
||||
|
||||
|
@ -140,12 +153,12 @@ DxEngGetDeviceGammaRamp(HDC hDC, LPVOID lpRamp)
|
|||
* @name DxEngLockDC
|
||||
* @implemented
|
||||
*
|
||||
* The function DxEngLockDC lock a hdc from dxg.sys
|
||||
* The function DxEngLockDC lock a hdc from dxg.sys
|
||||
*
|
||||
* @param HDC hDC
|
||||
* The handle we need want lock
|
||||
*
|
||||
* @return
|
||||
* @return
|
||||
* This api return PDC or NULL depns if it sussess lock the hdc or not
|
||||
*
|
||||
* @remarks.
|
||||
|
@ -163,13 +176,13 @@ DxEngLockDC(HDC hDC)
|
|||
* @name DxEngUnlockDC
|
||||
* @implemented
|
||||
*
|
||||
* The function DxEngUnlockDC Unlock a pDC (hdc) from dxg.sys
|
||||
* The function DxEngUnlockDC Unlock a pDC (hdc) from dxg.sys
|
||||
|
||||
* @param PDC pDC
|
||||
* The handle we need unlock
|
||||
*
|
||||
* @return
|
||||
* This api always return TRUE if it sussess or not
|
||||
* @return
|
||||
* This api always return TRUE if it sussess or not
|
||||
*
|
||||
* @remarks.
|
||||
* none
|
||||
|
@ -265,13 +278,34 @@ DWORD DxEngUnreferenceHdev(DWORD x1)
|
|||
return FALSE;
|
||||
}
|
||||
|
||||
/************************************************************************/
|
||||
/* DxEngSetDeviceGammaRamp */
|
||||
/************************************************************************/
|
||||
DWORD DxEngSetDeviceGammaRamp(DWORD x1, DWORD x2, DWORD x3)
|
||||
|
||||
/*++
|
||||
* @name DxEngSetDeviceGammaRamp
|
||||
* @implemented
|
||||
*
|
||||
* The function DxEngSetDeviceGammaRamp Set Gamma ramp from from dxg.sys
|
||||
|
||||
* @param HDEV hPDev
|
||||
* The hdev
|
||||
*
|
||||
* @param PGAMMARAMP Ramp
|
||||
* to set in our gama ramp
|
||||
*
|
||||
* @param BOOL Unuse
|
||||
* Info on this are avail at request. at moment ReactOS does not
|
||||
* does not use it. and problare never need it.
|
||||
*
|
||||
* @return
|
||||
* This return FALSE or TRUE, FALSE for fail, TRUE for success
|
||||
*
|
||||
* @remarks.
|
||||
* ReactOS does not loop it, only set the gamma once.
|
||||
*
|
||||
*--*/
|
||||
BOOL
|
||||
DxEngSetDeviceGammaRamp(HDEV hPDev, PGAMMARAMP Ramp, BOOL Unuse)
|
||||
{
|
||||
UNIMPLEMENTED;
|
||||
return FALSE;
|
||||
return IntSetDeviceGammaRamp(hPDev, Ramp);
|
||||
}
|
||||
|
||||
/************************************************************************/
|
||||
|
|
Loading…
Reference in a new issue