mirror of
https://github.com/reactos/reactos.git
synced 2025-05-20 17:45:06 +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();
|
DX_WINDBG_trace();
|
||||||
|
|
||||||
// EnterCriticalSection(&ddcs);
|
EnterCriticalSection(&ddcs);
|
||||||
*ppSurf = NULL;
|
*ppSurf = NULL;
|
||||||
|
|
||||||
_SEH_TRY
|
_SEH_TRY
|
||||||
|
@ -464,8 +464,8 @@ Main_DirectDraw_CreateSurface (LPDDRAWI_DIRECTDRAW_INT This, LPDDSURFACEDESC pDD
|
||||||
ret = DDERR_INVALIDPARAMS;
|
ret = DDERR_INVALIDPARAMS;
|
||||||
}
|
}
|
||||||
_SEH_END;
|
_SEH_END;
|
||||||
// LeaveCriticalSection(&ddcs);
|
LeaveCriticalSection(&ddcs);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -476,7 +476,8 @@ Main_DirectDraw_CreateSurface4(LPDDRAWI_DIRECTDRAW_INT This, LPDDSURFACEDESC2 pD
|
||||||
{
|
{
|
||||||
HRESULT ret;
|
HRESULT ret;
|
||||||
DX_WINDBG_trace();
|
DX_WINDBG_trace();
|
||||||
// EnterCriticalSection(&ddcs);
|
|
||||||
|
EnterCriticalSection(&ddcs);
|
||||||
*ppSurf = NULL;
|
*ppSurf = NULL;
|
||||||
|
|
||||||
_SEH_TRY
|
_SEH_TRY
|
||||||
|
@ -489,7 +490,7 @@ Main_DirectDraw_CreateSurface4(LPDDRAWI_DIRECTDRAW_INT This, LPDDSURFACEDESC2 pD
|
||||||
}
|
}
|
||||||
_SEH_END;
|
_SEH_END;
|
||||||
|
|
||||||
// LeaveCriticalSection(&ddcs);
|
LeaveCriticalSection(&ddcs);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -67,7 +67,7 @@ HDEV *DxEngEnumerateHdev(HDEV *hdev);
|
||||||
|
|
||||||
/* Notes : same protypes NtGdiEngGetDeviceGammaRamp, diffent is we skipp the user mode checks and seh */
|
/* Notes : same protypes NtGdiEngGetDeviceGammaRamp, diffent is we skipp the user mode checks and seh */
|
||||||
BOOL
|
BOOL
|
||||||
DxEngGetDeviceGammaRamp(HDC hDC, LPVOID lpRamp);
|
DxEngGetDeviceGammaRamp(HDEV hPDev, PGAMMARAMP Ramp);
|
||||||
|
|
||||||
/* Notes : Lock the hDC */
|
/* Notes : Lock the hDC */
|
||||||
PDC DxEngLockDC(HDC hDC);
|
PDC DxEngLockDC(HDC hDC);
|
||||||
|
@ -75,7 +75,8 @@ PDC DxEngLockDC(HDC hDC);
|
||||||
/* Notes : Unlock the hDC */
|
/* Notes : Unlock the hDC */
|
||||||
BOOL DxEngUnlockDC(PDC pDC);
|
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
|
/* prototypes are not done yet, I need gather all my notes
|
||||||
* to make them correct
|
* to make them correct
|
||||||
|
@ -89,7 +90,6 @@ DWORD DxEngUnlockHdev(DWORD x1);
|
||||||
DWORD DxEngReferenceHdev(DWORD x1);
|
DWORD DxEngReferenceHdev(DWORD x1);
|
||||||
DWORD DxEngIsHdevLockedByCurrentThread(DWORD x1);
|
DWORD DxEngIsHdevLockedByCurrentThread(DWORD x1);
|
||||||
DWORD DxEngUnreferenceHdev(DWORD x1);
|
DWORD DxEngUnreferenceHdev(DWORD x1);
|
||||||
DWORD DxEngSetDeviceGammaRamp(DWORD x1, DWORD x2, DWORD x3);
|
|
||||||
DWORD DxEngSpTearDownSprites(DWORD x1, DWORD x2, DWORD x3);
|
DWORD DxEngSpTearDownSprites(DWORD x1, DWORD x2, DWORD x3);
|
||||||
DWORD DxEngSpUnTearDownSprites(DWORD x1, DWORD x2, DWORD x3);
|
DWORD DxEngSpUnTearDownSprites(DWORD x1, DWORD x2, DWORD x3);
|
||||||
DWORD DxEngSpSpritesVisible(DWORD x1);
|
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 */
|
#endif /* _INT_W32k_DDRAW */
|
||||||
|
|
|
@ -123,16 +123,29 @@ DxEngEnumerateHdev(HDEV *hdev)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
/************************************************************************/
|
/*++
|
||||||
/* DxEngGetDeviceGammaRamp */
|
* @name DxEngGetDeviceGammaRamp
|
||||||
/************************************************************************/
|
* @implemented
|
||||||
/* same protypes NtGdiEngGetDeviceGammaRamp, diffent is we skipp the user mode checks and seh */
|
*
|
||||||
|
* 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
|
BOOL
|
||||||
DxEngGetDeviceGammaRamp(HDC hDC, LPVOID lpRamp)
|
DxEngGetDeviceGammaRamp(HDEV hPDev, PGAMMARAMP Ramp)
|
||||||
{
|
{
|
||||||
/* FIXME redirect it to NtGdiEngGetDeviceGammaRamp internal call */
|
return IntGetDeviceGammaRamp(hPDev, Ramp);
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -140,12 +153,12 @@ DxEngGetDeviceGammaRamp(HDC hDC, LPVOID lpRamp)
|
||||||
* @name DxEngLockDC
|
* @name DxEngLockDC
|
||||||
* @implemented
|
* @implemented
|
||||||
*
|
*
|
||||||
* The function DxEngLockDC lock a hdc from dxg.sys
|
* The function DxEngLockDC lock a hdc from dxg.sys
|
||||||
*
|
*
|
||||||
* @param HDC hDC
|
* @param HDC hDC
|
||||||
* The handle we need want lock
|
* The handle we need want lock
|
||||||
*
|
*
|
||||||
* @return
|
* @return
|
||||||
* This api return PDC or NULL depns if it sussess lock the hdc or not
|
* This api return PDC or NULL depns if it sussess lock the hdc or not
|
||||||
*
|
*
|
||||||
* @remarks.
|
* @remarks.
|
||||||
|
@ -163,13 +176,13 @@ DxEngLockDC(HDC hDC)
|
||||||
* @name DxEngUnlockDC
|
* @name DxEngUnlockDC
|
||||||
* @implemented
|
* @implemented
|
||||||
*
|
*
|
||||||
* The function DxEngUnlockDC Unlock a pDC (hdc) from dxg.sys
|
* The function DxEngUnlockDC Unlock a pDC (hdc) from dxg.sys
|
||||||
|
|
||||||
* @param PDC pDC
|
* @param PDC pDC
|
||||||
* The handle we need unlock
|
* The handle we need unlock
|
||||||
*
|
*
|
||||||
* @return
|
* @return
|
||||||
* This api always return TRUE if it sussess or not
|
* This api always return TRUE if it sussess or not
|
||||||
*
|
*
|
||||||
* @remarks.
|
* @remarks.
|
||||||
* none
|
* none
|
||||||
|
@ -265,13 +278,34 @@ DWORD DxEngUnreferenceHdev(DWORD x1)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
/************************************************************************/
|
|
||||||
/* DxEngSetDeviceGammaRamp */
|
/*++
|
||||||
/************************************************************************/
|
* @name DxEngSetDeviceGammaRamp
|
||||||
DWORD DxEngSetDeviceGammaRamp(DWORD x1, DWORD x2, DWORD x3)
|
* @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 IntSetDeviceGammaRamp(hPDev, Ramp);
|
||||||
return FALSE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/************************************************************************/
|
/************************************************************************/
|
||||||
|
|
Loading…
Reference in a new issue