#include <windows.h>
#include <ddk/ntddk.h>
#include <win32k/kapi.h>
+#include <debug.h>
+/*
+ * @implemented
+ */
BOOL
STDCALL
BitBlt(HDC hDCDest,
INT YSrc,
DWORD ROP)
{
- return W32kBitBlt(hDCDest, XDest, YDest, Width, Height, hDCSrc, XSrc, YSrc, ROP);
+ return NtGdiBitBlt(hDCDest, XDest, YDest, Width, Height, hDCSrc, XSrc, YSrc, ROP);
}
+
+/*
+ * @implemented
+ */
HBITMAP
STDCALL
CreateBitmap(INT Width,
UINT BitsPerPel,
CONST VOID *Bits)
{
- return W32kCreateBitmap(Width, Height, Planes, BitsPerPel, Bits);
+ return NtGdiCreateBitmap(Width, Height, Planes, BitsPerPel, Bits);
}
+
+/*
+ * @implemented
+ */
HBITMAP
STDCALL
CreateBitmapIndirect(CONST BITMAP *BM)
{
- return W32kCreateBitmapIndirect(BM);
+ return NtGdiCreateBitmapIndirect(BM);
}
+
+/*
+ * @implemented
+ */
HBITMAP
STDCALL
CreateCompatibleBitmap(HDC hDC,
INT Width,
INT Height)
{
- return W32kCreateCompatibleBitmap(hDC, Width, Height);
+ return NtGdiCreateCompatibleBitmap(hDC, Width, Height);
}
+
+/*
+ * @implemented
+ */
HBITMAP
STDCALL
CreateDiscardableBitmap(HDC hDC,
INT Width,
INT Height)
{
- return W32kCreateDiscardableBitmap(hDC, Width, Height);
+ return NtGdiCreateDiscardableBitmap(hDC, Width, Height);
}
+
+/*
+ * @implemented
+ */
HBITMAP
STDCALL
CreateDIBitmap(HDC hDC,
CONST BITMAPINFO *bmi,
UINT Usage)
{
- return W32kCreateDIBitmap(hDC, bmih, Init, bInit, bmi, Usage);
+ return NtGdiCreateDIBitmap(hDC, bmih, Init, bInit, bmi, Usage);
}
+
+/*
+ * @implemented
+ */
LONG
STDCALL
GetBitmapBits(HBITMAP hBitmap,
LONG Count,
LPVOID Bits)
{
- return W32kGetBitmapBits(hBitmap, Count, Bits);
+ return NtGdiGetBitmapBits(hBitmap, Count, Bits);
}
+
+/*
+ * @implemented
+ */
BOOL
STDCALL
GetBitmapDimensionEx(HBITMAP hBitmap,
LPSIZE Dimension)
{
- return W32kGetBitmapDimensionEx(hBitmap, Dimension);
+ return NtGdiGetBitmapDimensionEx(hBitmap, Dimension);
}
+
+/*
+ * @implemented
+ */
int
STDCALL
GetDIBits(HDC hDC,
LPBITMAPINFO bi,
UINT Usage)
{
- return W32kGetDIBits(hDC, hBitmap, StartScan, ScanLines, Bits, bi, Usage);
+ return NtGdiGetDIBits(hDC, hBitmap, StartScan, ScanLines, Bits, bi, Usage);
}
+
+/*
+ * @implemented
+ */
BOOL
STDCALL
MaskBlt(HDC hDCDest,
INT yMask,
DWORD ROP)
{
- return W32kMaskBlt(hDCDest, XDest, YDest, Width, Height, hDCSrc, XSrc, YSrc, hMaskBitmap, xMask, yMask, ROP);
+ return NtGdiMaskBlt(hDCDest, XDest, YDest, Width, Height, hDCSrc, XSrc, YSrc, hMaskBitmap, xMask, yMask, ROP);
}
+
+/*
+ * @implemented
+ */
BOOL
STDCALL
PlgBlt(HDC hDCDest,
INT xMask,
INT yMask)
{
- return W32kPlgBlt(hDCDest, Point, hDCSrc, XSrc, YSrc, Width, Height, hMaskBitmap, xMask, yMask);
+ return NtGdiPlgBlt(hDCDest, Point, hDCSrc, XSrc, YSrc, Width, Height, hMaskBitmap, xMask, yMask);
}
+
+/*
+ * @implemented
+ */
LONG
STDCALL
SetBitmapBits(HBITMAP hBitmap,
DWORD Bytes,
CONST VOID *Bits)
{
- return W32kSetBitmapBits(hBitmap, Bytes, Bits);
+ return NtGdiSetBitmapBits(hBitmap, Bytes, Bits);
}
+
+/*
+ * @implemented
+ */
int
STDCALL
SetDIBits(HDC hDC,
CONST BITMAPINFO *bmi,
UINT ColorUse)
{
- return W32kSetDIBits(hDC, hBitmap, StartScan, ScanLines, Bits, bmi, ColorUse);
+ return NtGdiSetDIBits(hDC, hBitmap, StartScan, ScanLines, Bits, bmi, ColorUse);
}
+
+/*
+ * @implemented
+ */
int
STDCALL
SetDIBitsToDevice(HDC hDC,
CONST BITMAPINFO *bmi,
UINT ColorUse)
{
- return W32kSetDIBitsToDevice(hDC, XDest, YDest, Width, Height, XSrc, YSrc, StartScan, ScanLines,
+ return NtGdiSetDIBitsToDevice(hDC, XDest, YDest, Width, Height, XSrc, YSrc, StartScan, ScanLines,
Bits, bmi, ColorUse);
}
-int
-STDCALL
+
+/*
+ * @implemented
+ */
+BOOL
+STDCALL
+StretchBlt(
+ HDC hdcDest, // handle to destination DC
+ int nXOriginDest, // x-coord of destination upper-left corner
+ int nYOriginDest, // y-coord of destination upper-left corner
+ int nWidthDest, // width of destination rectangle
+ int nHeightDest, // height of destination rectangle
+ HDC hdcSrc, // handle to source DC
+ int nXOriginSrc, // x-coord of source upper-left corner
+ int nYOriginSrc, // y-coord of source upper-left corner
+ int nWidthSrc, // width of source rectangle
+ int nHeightSrc, // height of source rectangle
+ DWORD dwRop // raster operation code
+ )
+{
+ //SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
+ if ( (nWidthDest==nWidthSrc) && (nHeightDest==nHeightSrc) )
+ {
+ return BitBlt(hdcDest,
+ nXOriginDest, // x-coord of destination upper-left corner
+ nYOriginDest, // y-coord of destination upper-left corner
+ nWidthDest, // width of destination rectangle
+ nHeightDest, // height of destination rectangle
+ hdcSrc, // handle to source DC
+ nXOriginSrc, // x-coordinate of source upper-left corner
+ nYOriginSrc, // y-coordinate of source upper-left corner
+ dwRop // raster operation code
+ );
+ }
+
+ DPRINT1("FIXME: StretchBlt can only Blt, not Stretch!\n");
+ return FALSE;
+}
+
+
+/*
+ * @implemented
+ */
+int
+STDCALL
StretchDIBits(HDC hDC,
INT XDest,
INT YDest,
UINT Usage,
DWORD ROP)
{
- return W32kStretchDIBits(hDC, XDest, YDest, DestWidth, DestHeight, XSrc, YSrc,
+ return NtGdiStretchDIBits(hDC, XDest, YDest, DestWidth, DestHeight, XSrc, YSrc,
SrcWidth, SrcHeight, Bits, BitsInfo, Usage, ROP);
}
+
+/*
+ * @implemented
+ */
HBITMAP
STDCALL
CreateDIBSection(HDC hDC,
HANDLE hSection,
DWORD dwOffset)
{
- return W32kCreateDIBSection(hDC, bmi, Usage, Bits, hSection, dwOffset);
+ return NtGdiCreateDIBSection(hDC, bmi, Usage, Bits, hSection, dwOffset);
}
+
+/*
+ * @implemented
+ */
COLORREF
STDCALL
SetPixel(HDC hDC,
INT Y,
COLORREF Color)
{
- return W32kSetPixel(hDC, X, Y, Color);
+ return NtGdiSetPixel(hDC, X, Y, Color);
}
+
+/*
+ * @implemented
+ */
BOOL STDCALL
PatBlt(HDC hDC, INT Top, INT Left, INT Width, INT Height, ULONG Rop)
{
- return(W32kPatBlt(hDC, Top, Left, Width, Height, Rop));
+ return(NtGdiPatBlt(hDC, Top, Left, Width, Height, Rop));
}
-
+/*
+ * @implemented
+ */
+WINBOOL
+STDCALL
+PolyPatBlt(HDC hDC,DWORD dwRop,PPATRECT pRects,int cRects,ULONG Reserved)
+{
+ return NtGdiPolyPatBlt(hDC,dwRop,pRects,cRects,Reserved);
+}
/*
-BOOL STDCALL W32kExtFloodFill(HDC hDC, INT XStart, INT YStart, COLORREF Color, UINT FillType)
-BOOL STDCALL W32kFloodFill(HDC hDC, INT XStart, INT YStart, COLORREF Fill)
-UINT STDCALL W32kGetDIBColorTable(HDC hDC, UINT StartIndex, UINT Entries, RGBQUAD *Colors)
-COLORREF STDCALL W32kGetPixel(HDC hDC,
+BOOL STDCALL NtGdiExtFloodFill(HDC hDC, INT XStart, INT YStart, COLORREF Color, UINT FillType)
+BOOL STDCALL NtGdiFloodFill(HDC hDC, INT XStart, INT YStart, COLORREF Fill)
+UINT STDCALL NtGdiGetDIBColorTable(HDC hDC, UINT StartIndex, UINT Entries, RGBQUAD *Colors)
+COLORREF STDCALL NtGdiGetPixel(HDC hDC,
INT XPos,
INT YPos)
-BOOL STDCALL W32kSetBitmapDimensionEx(HBITMAP hBitmap,
+BOOL STDCALL NtGdiSetBitmapDimensionEx(HBITMAP hBitmap,
INT Width,
INT Height,
LPSIZE Size)
-UINT STDCALL W32kSetDIBColorTable(HDC hDC,
+UINT STDCALL NtGdiSetDIBColorTable(HDC hDC,
UINT StartIndex,
UINT Entries,
CONST RGBQUAD *Colors)
-BOOL STDCALL W32kSetPixelV(HDC hDC,
+BOOL STDCALL NtGdiSetPixelV(HDC hDC,
INT X,
INT Y,
COLORREF Color)
-BOOL STDCALL W32kStretchBlt(HDC hDCDest,
+BOOL STDCALL NtGdiStretchBlt(HDC hDCDest,
INT XOriginDest,
INT YOriginDest,
INT WidthDest,