23245f3322
git-svn-id: https://svn.disconnected-by-peer.at/svn/linamh/trunk/linamh@1438 6952d904-891a-0410-993b-d76249ca496b
1602 lines
57 KiB
Diff
1602 lines
57 KiB
Diff
DIB Engine: initial pass-through implementation
|
|
|
|
From: Massimo Del Fedele <max@veneto.com>
|
|
|
|
|
|
---
|
|
|
|
configure.ac | 1
|
|
dlls/winedib.drv/Makefile.in | 28 +++++
|
|
dlls/winedib.drv/bitblt.c | 80 +++++++++++++
|
|
dlls/winedib.drv/bitmap.c | 77 ++++++++++++
|
|
dlls/winedib.drv/clipping.c | 36 ++++++
|
|
dlls/winedib.drv/dc.c | 104 +++++++++++++++++
|
|
dlls/winedib.drv/dib.c | 92 +++++++++++++++
|
|
dlls/winedib.drv/dibdrv.h | 84 ++++++++++++++
|
|
dlls/winedib.drv/dibdrv_main.c | 50 ++++++++
|
|
dlls/winedib.drv/font.c | 83 +++++++++++++
|
|
dlls/winedib.drv/graphics.c | 230 +++++++++++++++++++++++++++++++++++++
|
|
dlls/winedib.drv/opengl.c | 221 ++++++++++++++++++++++++++++++++++++
|
|
dlls/winedib.drv/palette.c | 90 ++++++++++++++
|
|
dlls/winedib.drv/pen_brush.c | 98 ++++++++++++++++
|
|
dlls/winedib.drv/text.c | 55 +++++++++
|
|
dlls/winedib.drv/video.c | 48 ++++++++
|
|
dlls/winedib.drv/winedib.drv.spec | 74 ++++++++++++
|
|
17 files changed, 1451 insertions(+), 0 deletions(-)
|
|
create mode 100644 dlls/winedib.drv/Makefile.in
|
|
create mode 100644 dlls/winedib.drv/bitblt.c
|
|
create mode 100644 dlls/winedib.drv/bitmap.c
|
|
create mode 100644 dlls/winedib.drv/clipping.c
|
|
create mode 100644 dlls/winedib.drv/dc.c
|
|
create mode 100644 dlls/winedib.drv/dib.c
|
|
create mode 100644 dlls/winedib.drv/dibdrv.h
|
|
create mode 100644 dlls/winedib.drv/dibdrv_main.c
|
|
create mode 100644 dlls/winedib.drv/font.c
|
|
create mode 100644 dlls/winedib.drv/graphics.c
|
|
create mode 100644 dlls/winedib.drv/opengl.c
|
|
create mode 100644 dlls/winedib.drv/palette.c
|
|
create mode 100644 dlls/winedib.drv/pen_brush.c
|
|
create mode 100644 dlls/winedib.drv/text.c
|
|
create mode 100644 dlls/winedib.drv/video.c
|
|
create mode 100644 dlls/winedib.drv/winedib.drv.spec
|
|
|
|
|
|
diff --git a/configure.ac b/configure.ac
|
|
index 4ab3f6a..94136c2 100644
|
|
--- a/configure.ac
|
|
+++ b/configure.ac
|
|
@@ -2270,6 +2270,7 @@ WINE_CONFIG_MAKEFILE([dlls/wineaudioio.drv/Makefile],[dlls/Makedll.rules],[dlls]
|
|
WINE_CONFIG_MAKEFILE([dlls/winecoreaudio.drv/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS])
|
|
WINE_CONFIG_MAKEFILE([dlls/winecrt0/Makefile],[dlls/Makeimplib.rules],[dlls],[ALL_IMPLIB_DIRS])
|
|
WINE_CONFIG_MAKEFILE([dlls/wined3d/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS])
|
|
+WINE_CONFIG_MAKEFILE([dlls/winedib.drv/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS])
|
|
WINE_CONFIG_MAKEFILE([dlls/winedos/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS])
|
|
WINE_CONFIG_MAKEFILE([dlls/wineesd.drv/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS])
|
|
WINE_CONFIG_MAKEFILE([dlls/winejack.drv/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS])
|
|
diff --git a/dlls/winedib.drv/Makefile.in b/dlls/winedib.drv/Makefile.in
|
|
new file mode 100644
|
|
index 0000000..66ad14f
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/Makefile.in
|
|
@@ -0,0 +1,28 @@
|
|
+TOPSRCDIR = @top_srcdir@
|
|
+TOPOBJDIR = ../..
|
|
+SRCDIR = @srcdir@
|
|
+VPATH = @srcdir@
|
|
+EXTRAINCL = @FREETYPEINCL@ @FONTCONFIGINCL@
|
|
+EXTRALIBS = @XLIB@
|
|
+MODULE = winedib.drv
|
|
+IMPORTS = user32 gdi32 advapi32 kernel32 ntdll
|
|
+
|
|
+C_SRCS = \
|
|
+ bitblt.c \
|
|
+ bitmap.c \
|
|
+ clipping.c \
|
|
+ dc.c \
|
|
+ dib.c \
|
|
+ dibdrv_main.c \
|
|
+ driver.c \
|
|
+ font.c \
|
|
+ graphics.c \
|
|
+ opengl.c \
|
|
+ palette.c \
|
|
+ pen_brush.c \
|
|
+ text.c \
|
|
+ video.c
|
|
+
|
|
+@MAKE_DLL_RULES@
|
|
+
|
|
+@DEPENDENCIES@ # everything below this line is overwritten by make depend
|
|
diff --git a/dlls/winedib.drv/bitblt.c b/dlls/winedib.drv/bitblt.c
|
|
new file mode 100644
|
|
index 0000000..fa9e2ec
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/bitblt.c
|
|
@@ -0,0 +1,80 @@
|
|
+/*
|
|
+ * DIBDRV bit-blit operations
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_AlphaBlend
|
|
+ */
|
|
+BOOL DIBDRV_AlphaBlend( DIBDRVPHYSDEV *physDevDst, INT xDst, INT yDst, INT widthDst, INT heightDst,
|
|
+ DIBDRVPHYSDEV *physDevSrc, INT xSrc, INT ySrc, INT widthSrc, INT heightSrc,
|
|
+ BLENDFUNCTION blendfn)
|
|
+{
|
|
+ TRACE("physDevDst:%p, xDst:%d, yDst:%d, widthDst:%d, heightDst:%d, physDevSrc:%p, xSrc:%d, ySrc:%d, widthSrc:%d, heightSrc:%d\n",
|
|
+ physDevDst, xDst, yDst, widthDst, heightDst, physDevSrc, xSrc, ySrc, widthSrc, heightSrc);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pAlphaBlend(physDevDst->X11PhysDev, xDst, yDst, widthDst, heightDst,
|
|
+ physDevSrc->X11PhysDev, xSrc, ySrc, widthSrc, heightSrc,
|
|
+ blendfn);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_BitBlt
|
|
+ */
|
|
+BOOL DIBDRV_BitBlt( DIBDRVPHYSDEV *physDevDst, INT xDst, INT yDst,
|
|
+ INT width, INT height, DIBDRVPHYSDEV *physDevSrc,
|
|
+ INT xSrc, INT ySrc, DWORD rop )
|
|
+{
|
|
+ TRACE("physDevDst:%p, xDst:%d, yDst:%d, width:%d, height:%d, physDevSrc:%p, xSrc:%d, ySrc:%d, rop:%08x\n",
|
|
+ physDevDst, xDst, yDst, width, height, physDevSrc, xSrc, ySrc, rop);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pBitBlt(physDevDst->X11PhysDev, xDst, yDst, width, height,
|
|
+ physDevSrc->X11PhysDev, xSrc, ySrc, rop);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_StretchBlt
|
|
+ */
|
|
+BOOL DIBDRV_StretchBlt( DIBDRVPHYSDEV *physDevDst, INT xDst, INT yDst,
|
|
+ INT widthDst, INT heightDst,
|
|
+ DIBDRVPHYSDEV *physDevSrc, INT xSrc, INT ySrc,
|
|
+ INT widthSrc, INT heightSrc, DWORD rop )
|
|
+{
|
|
+ TRACE("physDevDst:%p, xDst:%d, yDst:%d, widthDst:%d, heightDst:%d, physDevSrc:%p, xSrc:%d, ySrc:%d, widthSrc:%d, heightSrc:%d, rop:%8x\n",
|
|
+ physDevDst, xDst, yDst, widthDst, heightDst, physDevSrc, xSrc, ySrc, widthSrc, heightSrc, rop);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pStretchBlt(physDevDst->X11PhysDev, xDst, yDst, widthSrc, heightSrc,
|
|
+ physDevSrc->X11PhysDev, xSrc, ySrc, widthDst, heightDst, rop);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_PatBlt
|
|
+ */
|
|
+BOOL DIBDRV_PatBlt( DIBDRVPHYSDEV *physDev, INT left, INT top, INT width, INT height, DWORD rop )
|
|
+{
|
|
+ TRACE("physDev:%p, left:%d, top:%d, width:%d, height:%d, rop:%06x\n", physDev, left, top, width, height, rop);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pPatBlt(physDev->X11PhysDev, left, top, width, height, rop);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/bitmap.c b/dlls/winedib.drv/bitmap.c
|
|
new file mode 100644
|
|
index 0000000..09cca69
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/bitmap.c
|
|
@@ -0,0 +1,77 @@
|
|
+/*
|
|
+ * DIB driver bitmap objects
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+
|
|
+/****************************************************************************
|
|
+ * SelectBitmap (WINEDIB.DRV.@)
|
|
+ */
|
|
+HBITMAP DIBDRV_SelectBitmap( DIBDRVPHYSDEV *physDev, HBITMAP hbitmap )
|
|
+{
|
|
+ TRACE("physDev:%p, hbitmap:%p\n", physDev, hbitmap);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSelectBitmap(physDev->X11PhysDev, hbitmap);
|
|
+}
|
|
+
|
|
+/****************************************************************************
|
|
+ * DIBDRV_CreateBitmap
|
|
+ */
|
|
+BOOL DIBDRV_CreateBitmap( DIBDRVPHYSDEV *physDev, HBITMAP hbitmap, LPVOID bmBits )
|
|
+{
|
|
+ TRACE("physDev:%p, hbitmap:%p, bmBits:%p\n", physDev, hbitmap, bmBits);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pCreateBitmap(physDev->X11PhysDev, hbitmap, bmBits);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_DeleteBitmap
|
|
+ */
|
|
+BOOL DIBDRV_DeleteBitmap( HBITMAP hbitmap )
|
|
+{
|
|
+ TRACE("hbitmap:%p\n", hbitmap);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pDeleteBitmap(hbitmap);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetBitmapBits
|
|
+ */
|
|
+LONG DIBDRV_GetBitmapBits( HBITMAP hbitmap, void *buffer, LONG count )
|
|
+{
|
|
+ TRACE("hbitmap:%p, buffer:%p, count:%d\n", hbitmap, buffer, count);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetBitmapBits(hbitmap, buffer, count);
|
|
+}
|
|
+
|
|
+/******************************************************************************
|
|
+ * DIBDRV_SetBitmapBits
|
|
+ */
|
|
+LONG DIBDRV_SetBitmapBits( HBITMAP hbitmap, const void *bits, LONG count )
|
|
+{
|
|
+ TRACE("hbitmap:%p, bits:%p, count:%d\n", hbitmap, bits, count);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetBitmapBits(hbitmap, bits, count);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/clipping.c b/dlls/winedib.drv/clipping.c
|
|
new file mode 100644
|
|
index 0000000..b3c18ef
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/clipping.c
|
|
@@ -0,0 +1,36 @@
|
|
+/*
|
|
+ * DIBDRV clipping functions
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SetDeviceClipping
|
|
+ */
|
|
+void DIBDRV_SetDeviceClipping( DIBDRVPHYSDEV *physDev, HRGN vis_rgn, HRGN clip_rgn )
|
|
+{
|
|
+ TRACE("physDev:%p, vis_rgn:%p, clip_rgn:%p\n", physDev, vis_rgn, clip_rgn);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ _DIBDRV_GetDisplayDriver()->pSetDeviceClipping(physDev->X11PhysDev, vis_rgn, clip_rgn);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/dc.c b/dlls/winedib.drv/dc.c
|
|
new file mode 100644
|
|
index 0000000..e0ffb4d
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/dc.c
|
|
@@ -0,0 +1,104 @@
|
|
+/*
|
|
+ * DIB driver initialization functions
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/**********************************************************************
|
|
+ * DIBDRV_CreateDC
|
|
+ */
|
|
+BOOL DIBDRV_CreateDC( HDC hdc, DIBDRVPHYSDEV **pdev, LPCWSTR driver, LPCWSTR device,
|
|
+ LPCWSTR output, const DEVMODEW* initData )
|
|
+{
|
|
+ DIBDRVPHYSDEV *physDev;
|
|
+ PHYSDEV X11PhysDev;
|
|
+
|
|
+ TRACE("hdc:%p, pdev:%p, driver:%s, device:%s, output:%s, initData:%p\n",
|
|
+ hdc, pdev, debugstr_w(driver), debugstr_w(device), debugstr_w(output), initData);
|
|
+
|
|
+ /* allocates physical device */
|
|
+ physDev = HeapAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(DIBDRVPHYSDEV) );
|
|
+ if (!physDev)
|
|
+ return FALSE;
|
|
+
|
|
+ /* creates X11 physical device */
|
|
+ if(!_DIBDRV_GetDisplayDriver()->pCreateDC(hdc, &X11PhysDev, driver, device, output, initData))
|
|
+ {
|
|
+ HeapFree(GetProcessHeap(), 0, physDev);
|
|
+ return FALSE;
|
|
+ }
|
|
+
|
|
+ /* sets X11 Device pointer in DIB Engine device */
|
|
+ physDev->X11PhysDev = X11PhysDev;
|
|
+
|
|
+ /* sets the result value and returns */
|
|
+ *pdev = physDev;
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return TRUE;
|
|
+}
|
|
+
|
|
+/**********************************************************************
|
|
+ * DIBDRV_DeleteDC
|
|
+ */
|
|
+BOOL DIBDRV_DeleteDC( DIBDRVPHYSDEV *physDev )
|
|
+{
|
|
+ BOOL res;
|
|
+
|
|
+ TRACE("physDev:%p\n", physDev);
|
|
+
|
|
+ /* frees X11 device */
|
|
+ res = _DIBDRV_GetDisplayDriver()->pDeleteDC(physDev->X11PhysDev);
|
|
+ physDev->X11PhysDev = NULL;
|
|
+
|
|
+ /* frees DIB Engine device */
|
|
+ HeapFree(GetProcessHeap(), 0, physDev);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return res;
|
|
+}
|
|
+
|
|
+/**********************************************************************
|
|
+ * DIBDRV_ExtEscape
|
|
+ */
|
|
+INT DIBDRV_ExtEscape( DIBDRVPHYSDEV *physDev, INT escape, INT in_count, LPCVOID in_data,
|
|
+ INT out_count, LPVOID out_data )
|
|
+{
|
|
+ TRACE("physDev:%p, escape:%d, in_count:%d, in_data:%p, out_count:%d, out_data:%p\n",
|
|
+ physDev, escape, in_count, in_data, out_count, out_data);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pExtEscape(physDev->X11PhysDev, escape, in_count, in_data, out_count, out_data);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetDeviceCaps
|
|
+ */
|
|
+INT DIBDRV_GetDeviceCaps( DIBDRVPHYSDEV *physDev, INT cap )
|
|
+{
|
|
+ TRACE("physDev:%p, cap:%d\n", physDev, cap);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetDeviceCaps(physDev->X11PhysDev, cap);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/dib.c b/dlls/winedib.drv/dib.c
|
|
new file mode 100644
|
|
index 0000000..47dce0e
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/dib.c
|
|
@@ -0,0 +1,92 @@
|
|
+/*
|
|
+ * DIBDRV device-independent bitmaps
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_CreateDIBSection
|
|
+ */
|
|
+HBITMAP DIBDRV_CreateDIBSection( DIBDRVPHYSDEV *physDev, HBITMAP hbitmap,
|
|
+ const BITMAPINFO *bmi, UINT usage )
|
|
+{
|
|
+ TRACE("physDev:%p, hbitmap:%p, bmi:%p, usage:%d\n", physDev, hbitmap, bmi, usage);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pCreateDIBSection(physDev->X11PhysDev, hbitmap, bmi, usage);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetDIBits
|
|
+*/
|
|
+INT DIBDRV_GetDIBits( DIBDRVPHYSDEV *physDev, HBITMAP hbitmap, UINT startscan,
|
|
+ UINT lines, LPCVOID bits, const BITMAPINFO *bmi, UINT coloruse )
|
|
+{
|
|
+ TRACE("physDev:%p, hbitmap:%p, startscan:%d, lines:%d, bits:%p, bmi:%p, coloruse:%d\n",
|
|
+ physDev, hbitmap, startscan, lines, bits, bmi, coloruse);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetDIBits(physDev->X11PhysDev, hbitmap, startscan, lines, bits, bmi, coloruse);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SetDIBColorTable
|
|
+ */
|
|
+UINT DIBDRV_SetDIBColorTable( DIBDRVPHYSDEV *physDev, UINT start, UINT count,
|
|
+ const RGBQUAD *colors )
|
|
+{
|
|
+ TRACE("physDev:%p, start:%d, count:%d, colors:%p\n", physDev, start, count, colors);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetDIBColorTable(physDev->X11PhysDev, start, count, colors);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SetDIBits
|
|
+ */
|
|
+INT DIBDRV_SetDIBits( DIBDRVPHYSDEV *physDev, HBITMAP hbitmap, UINT startscan,
|
|
+ UINT lines, LPCVOID bits, const BITMAPINFO *info, UINT coloruse )
|
|
+{
|
|
+ TRACE("physDev:%p, hbitmap:%p, startscan:%d, lines:%d, bits:%p, bmi:%p, coloruse:%d\n",
|
|
+ physDev, hbitmap, startscan, lines, bits, info, coloruse);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetDIBits(physDev->X11PhysDev, hbitmap, startscan, lines, bits, info, coloruse);
|
|
+}
|
|
+
|
|
+/*************************************************************************
|
|
+ * DIBDRV_SetDIBitsToDevice
|
|
+ */
|
|
+INT DIBDRV_SetDIBitsToDevice( DIBDRVPHYSDEV *physDev, INT xDest, INT yDest, DWORD cx,
|
|
+ DWORD cy, INT xSrc, INT ySrc,
|
|
+ UINT startscan, UINT lines, LPCVOID bits,
|
|
+ const BITMAPINFO *info, UINT coloruse )
|
|
+{
|
|
+ TRACE("physDev:%p, xDest:%d, yDest:%d, cx:%x, cy:%x, xSrc:%d, ySrc:%d, startscan:%d, lines:%d, bits:%p, info:%p, coloruse:%d\n",
|
|
+ physDev, xDest, yDest, cx, cy, xSrc, ySrc, startscan, lines, bits, info, coloruse);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetDIBitsToDevice(physDev->X11PhysDev, xDest, yDest, cx, cy, xSrc, ySrc,
|
|
+ startscan, lines, bits, info, coloruse);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/dibdrv.h b/dlls/winedib.drv/dibdrv.h
|
|
new file mode 100644
|
|
index 0000000..6dfba06
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/dibdrv.h
|
|
@@ -0,0 +1,84 @@
|
|
+/*
|
|
+ * DIB driver private definitions
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#ifndef __WINE_DIBDRV_H
|
|
+#define __WINE_DIBDRV_H
|
|
+
|
|
+#include <stdarg.h>
|
|
+#include <stdlib.h>
|
|
+#include <X11/Xlib.h>
|
|
+
|
|
+#include "windef.h"
|
|
+#include "winbase.h"
|
|
+#include "winerror.h"
|
|
+#include "wingdi.h"
|
|
+#include "wine/list.h"
|
|
+#include "wine/library.h"
|
|
+#include "wine/debug.h"
|
|
+#include "wingdi.h"
|
|
+#include "winreg.h"
|
|
+#include "wine/winbase16.h" /* GlobalLock16 */
|
|
+
|
|
+/* data structures needed to access opaque pointers
|
|
+ * defined in gdi32.h */
|
|
+#include "dibdrv_gdi32.h"
|
|
+
|
|
+/* provide a way to make debugging output appear
|
|
+ only once. Usage example:
|
|
+ ONCE(FIXME("Some message\n")); */
|
|
+#define ONCE(x) \
|
|
+{ \
|
|
+ static BOOL done = FALSE; \
|
|
+ if(!done) \
|
|
+ { \
|
|
+ done = TRUE; \
|
|
+ x; \
|
|
+ } \
|
|
+}
|
|
+
|
|
+
|
|
+/* DIB driver physical device */
|
|
+typedef struct _DIBDRVPHYSDEV
|
|
+{
|
|
+ /* X11 driver physical device */
|
|
+ PHYSDEV X11PhysDev;
|
|
+
|
|
+ /* active ROP2 */
|
|
+ INT rop2;
|
|
+
|
|
+} DIBDRVPHYSDEV;
|
|
+
|
|
+
|
|
+/* *********************************************************************
|
|
+ * DISPLAY DRIVER ACCESS FUNCTIONS
|
|
+ * ********************************************************************/
|
|
+
|
|
+/* LoadDisplayDriver
|
|
+ * Loads display driver - partially grabbed from gdi32 */
|
|
+DC_FUNCTIONS *_DIBDRV_LoadDisplayDriver(void);
|
|
+
|
|
+/* FreeDisplayDriver
|
|
+ Frees resources allocated by Display driver */
|
|
+void _DIBDRV_FreeDisplayDriver(void);
|
|
+
|
|
+/* GetDisplayDriver
|
|
+ Gets a pointer to display drives'function table */
|
|
+inline DC_FUNCTIONS *_DIBDRV_GetDisplayDriver(void);
|
|
+
|
|
+#endif /* __WINE_DIBDRV_H */
|
|
diff --git a/dlls/winedib.drv/dibdrv_main.c b/dlls/winedib.drv/dibdrv_main.c
|
|
new file mode 100644
|
|
index 0000000..28429d2
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/dibdrv_main.c
|
|
@@ -0,0 +1,50 @@
|
|
+/*
|
|
+ * DIBDRV initialization code
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV initialization routine
|
|
+ */
|
|
+BOOL WINAPI DllMain( HINSTANCE hinst, DWORD reason, LPVOID reserved )
|
|
+{
|
|
+ BOOL ret = TRUE;
|
|
+
|
|
+ switch(reason)
|
|
+ {
|
|
+ case DLL_PROCESS_ATTACH:
|
|
+ /* Loads display driver */
|
|
+ _DIBDRV_LoadDisplayDriver();
|
|
+ break;
|
|
+ case DLL_THREAD_DETACH:
|
|
+ /* do thread detach */
|
|
+ break;
|
|
+ case DLL_PROCESS_DETACH:
|
|
+ /* unloads display driver */
|
|
+ _DIBDRV_FreeDisplayDriver();
|
|
+ break;
|
|
+ }
|
|
+ return ret;
|
|
+}
|
|
diff --git a/dlls/winedib.drv/font.c b/dlls/winedib.drv/font.c
|
|
new file mode 100644
|
|
index 0000000..85f9198
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/font.c
|
|
@@ -0,0 +1,83 @@
|
|
+/*
|
|
+ * DIBDRV font objects
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ *
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/**********************************************************************
|
|
+ * DIBDRV_SetTextColor
|
|
+ */
|
|
+COLORREF DIBDRV_SetTextColor( DIBDRVPHYSDEV *physDev, COLORREF color )
|
|
+{
|
|
+ TRACE("physDev:%p, color:%08x\n", physDev, color);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetTextColor(physDev->X11PhysDev, color);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SelectFont
|
|
+ */
|
|
+HFONT DIBDRV_SelectFont( DIBDRVPHYSDEV *physDev, HFONT hfont, HANDLE gdiFont )
|
|
+{
|
|
+ TRACE("physDev:%p, hfont:%p, gdiFont:%p\n", physDev, hfont, gdiFont);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSelectFont(physDev->X11PhysDev, hfont, gdiFont);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_EnumDeviceFonts
|
|
+ */
|
|
+BOOL DIBDRV_EnumDeviceFonts( DIBDRVPHYSDEV *physDev, LPLOGFONTW plf,
|
|
+ FONTENUMPROCW proc, LPARAM lp )
|
|
+{
|
|
+ TRACE("physDev:%p, plf:%p, proc:%p, lp:%lx\n", physDev, plf, proc, lp);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pEnumDeviceFonts(physDev->X11PhysDev, plf, proc, lp);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetTextMetrics
|
|
+ */
|
|
+BOOL DIBDRV_GetTextMetrics( DIBDRVPHYSDEV *physDev, TEXTMETRICW *metrics )
|
|
+{
|
|
+ TRACE("physDev:%p, metrics:%p\n", physDev, metrics);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetTextMetrics(physDev->X11PhysDev, metrics);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetCharWidth
|
|
+ */
|
|
+BOOL DIBDRV_GetCharWidth( DIBDRVPHYSDEV *physDev, UINT firstChar, UINT lastChar,
|
|
+ LPINT buffer )
|
|
+{
|
|
+ TRACE("physDev:%p, firstChar:%d, lastChar:%d, buffer:%pn", physDev, firstChar, lastChar, buffer);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetCharWidth(physDev->X11PhysDev, firstChar, lastChar, buffer);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/graphics.c b/dlls/winedib.drv/graphics.c
|
|
new file mode 100644
|
|
index 0000000..b746af2
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/graphics.c
|
|
@@ -0,0 +1,230 @@
|
|
+/*
|
|
+ * DIBDRV implementation of GDI driver graphics functions
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_Arc
|
|
+ */
|
|
+BOOL DIBDRV_Arc( DIBDRVPHYSDEV *physDev, INT left, INT top, INT right, INT bottom,
|
|
+ INT xstart, INT ystart, INT xend, INT yend )
|
|
+{
|
|
+ TRACE("physDev:%p, left:%d, top:%d, right:%d, bottom:%d, xstart:%d, ystart:%d, xend:%d, yend:%d\n",
|
|
+ physDev, left, top, right, bottom, xstart, ystart, xend, yend);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pArc(physDev->X11PhysDev, left, top, right, bottom,
|
|
+ xstart, ystart, xend, yend);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_Chord
|
|
+ */
|
|
+BOOL DIBDRV_Chord( DIBDRVPHYSDEV *physDev, INT left, INT top, INT right, INT bottom,
|
|
+ INT xstart, INT ystart, INT xend, INT yend )
|
|
+{
|
|
+ TRACE("physDev:%p, left:%d, top:%d, right:%d, bottom:%d, xstart:%d, ystart:%d, xend:%d, yend:%d\n",
|
|
+ physDev, left, top, right, bottom, xstart, ystart, xend, yend);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pChord(physDev->X11PhysDev, left, top, right, bottom,
|
|
+ xstart, ystart, xend, yend);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_Ellipse
|
|
+ */
|
|
+BOOL DIBDRV_Ellipse( DIBDRVPHYSDEV *physDev, INT left, INT top, INT right, INT bottom )
|
|
+{
|
|
+ TRACE("physDev:%p, left:%d, top:%d, right:%d, bottom:%d\n",
|
|
+ physDev, left, top, right, bottom);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pEllipse(physDev->X11PhysDev, left, top, right, bottom);
|
|
+}
|
|
+
|
|
+/**********************************************************************
|
|
+ * DIBDRV_ExtFloodFill
|
|
+ */
|
|
+BOOL DIBDRV_ExtFloodFill( DIBDRVPHYSDEV *physDev, INT x, INT y, COLORREF color,
|
|
+ UINT fillType )
|
|
+{
|
|
+ TRACE("physDev:%p, x:%d, y:%d, color:%x, fillType:%d\n",
|
|
+ physDev, x, y, color, fillType);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pExtFloodFill(physDev->X11PhysDev, x, y, color, fillType);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetDCOrgEx
|
|
+ */
|
|
+BOOL DIBDRV_GetDCOrgEx( DIBDRVPHYSDEV *physDev, LPPOINT lpp )
|
|
+{
|
|
+ TRACE("physDev:%p, lpp:%p\n", physDev, lpp);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetDCOrgEx(physDev->X11PhysDev, lpp);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetPixel
|
|
+ */
|
|
+COLORREF DIBDRV_GetPixel( DIBDRVPHYSDEV *physDev, INT x, INT y )
|
|
+{
|
|
+ TRACE("physDev:%p, x:%d, y:%d\n", physDev, x, y);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetPixel(physDev->X11PhysDev, x, y);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_LineTo
|
|
+ */
|
|
+BOOL DIBDRV_LineTo( DIBDRVPHYSDEV *physDev, INT x, INT y )
|
|
+{
|
|
+ TRACE("physDev:%p, x:%d, y:%d\n", physDev, x, y);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pLineTo(physDev->X11PhysDev, x, y);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_PaintRgn
|
|
+ */
|
|
+BOOL DIBDRV_PaintRgn( DIBDRVPHYSDEV *physDev, HRGN hrgn )
|
|
+{
|
|
+ TRACE("physDev:%p, hrgn:%p\n", physDev, hrgn);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pPaintRgn(physDev->X11PhysDev, hrgn);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_Pie
|
|
+ */
|
|
+BOOL DIBDRV_Pie( DIBDRVPHYSDEV *physDev, INT left, INT top, INT right, INT bottom,
|
|
+ INT xstart, INT ystart, INT xend, INT yend )
|
|
+{
|
|
+ TRACE("physDev:%p, left:%d, top:%d, right:%d, bottom:%d, xstart:%d, ystart:%d, xend:%d, yend:%d\n",
|
|
+ physDev, left, top, right, bottom, xstart, ystart, xend, yend);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pPie(physDev->X11PhysDev, left, top, right, bottom,
|
|
+ xstart, ystart, xend, yend);
|
|
+}
|
|
+
|
|
+/**********************************************************************
|
|
+ * DIBDRV_Polygon
|
|
+ */
|
|
+BOOL DIBDRV_Polygon( DIBDRVPHYSDEV *physDev, const POINT* pt, INT count )
|
|
+{
|
|
+ TRACE("physDev:%p, pt:%p, count:%d\n", physDev, pt, count);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pPolygon(physDev->X11PhysDev, pt, count);
|
|
+}
|
|
+
|
|
+/**********************************************************************
|
|
+ * DIBDRV_Polyline
|
|
+ */
|
|
+BOOL DIBDRV_Polyline( DIBDRVPHYSDEV *physDev, const POINT* pt, INT count )
|
|
+{
|
|
+ TRACE("physDev:%p, pt:%p, count:%d\n", physDev, pt, count);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pPolyline(physDev->X11PhysDev, pt, count);
|
|
+}
|
|
+
|
|
+/**********************************************************************
|
|
+ * DIBDRV_PolyPolygon
|
|
+ */
|
|
+BOOL DIBDRV_PolyPolygon( DIBDRVPHYSDEV *physDev, const POINT* pt, const INT* counts, UINT polygons)
|
|
+{
|
|
+ TRACE("physDev:%p, pt:%p, counts:%p, polygons:%d\n", physDev, pt, counts, polygons);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pPolyPolygon(physDev->X11PhysDev, pt, counts, polygons);
|
|
+}
|
|
+
|
|
+/**********************************************************************
|
|
+ * DIBDRV_PolyPolyline
|
|
+ */
|
|
+BOOL DIBDRV_PolyPolyline( DIBDRVPHYSDEV *physDev, const POINT* pt, const DWORD* counts,
|
|
+ DWORD polylines )
|
|
+{
|
|
+ TRACE("physDev:%p, pt:%p, counts:%p, polylines:%d\n", physDev, pt, counts, polylines);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pPolyPolyline(physDev->X11PhysDev, pt, counts, polylines);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_Rectangle
|
|
+ */
|
|
+BOOL DIBDRV_Rectangle( DIBDRVPHYSDEV *physDev, INT left, INT top, INT right, INT bottom)
|
|
+{
|
|
+ TRACE("physDev:%p, left:%d, top:%d, right:%d, bottom:%d\n",
|
|
+ physDev, left, top, right, bottom);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pRectangle(physDev->X11PhysDev, left, top, right, bottom);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_RoundRect
|
|
+ */
|
|
+BOOL DIBDRV_RoundRect( DIBDRVPHYSDEV *physDev, INT left, INT top, INT right,
|
|
+ INT bottom, INT ell_width, INT ell_height )
|
|
+{
|
|
+ TRACE("physDev:%p, left:%d, top:%d, right:%d, bottom:%d, ell_width:%d, ell_height:%d\n",
|
|
+ physDev, left, top, right, bottom, ell_width, ell_height);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pRoundRect(physDev->X11PhysDev, left, top, right, bottom,
|
|
+ ell_width, ell_height);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SetPixel
|
|
+ */
|
|
+COLORREF DIBDRV_SetPixel( DIBDRVPHYSDEV *physDev, INT x, INT y, COLORREF color )
|
|
+{
|
|
+ TRACE("physDev:%p, x:%d, y:%d, color:%x\n", physDev, x, y, color);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetPixel(physDev->X11PhysDev, x, y, color);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SetDCOrg
|
|
+ */
|
|
+DWORD DIBDRV_SetDCOrg( DIBDRVPHYSDEV *physDev, INT x, INT y )
|
|
+{
|
|
+ TRACE("physDev:%p, x:%d, y:%d\n", physDev, x, y);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetDCOrg(physDev->X11PhysDev, x, y);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/opengl.c b/dlls/winedib.drv/opengl.c
|
|
new file mode 100644
|
|
index 0000000..27e4229
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/opengl.c
|
|
@@ -0,0 +1,221 @@
|
|
+/*
|
|
+ * DIBDRV OpenGL functions
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+#define HPBUFFERARB void *
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+int DIBDRV_ChoosePixelFormat( DIBDRVPHYSDEV *physDev,
|
|
+ const PIXELFORMATDESCRIPTOR *ppfd )
|
|
+{
|
|
+ TRACE("physDev:%p, ppfd:%p\n", physDev, ppfd);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pChoosePixelFormat(physDev->X11PhysDev, ppfd);
|
|
+}
|
|
+
|
|
+int DIBDRV_DescribePixelFormat( DIBDRVPHYSDEV *physDev,
|
|
+ int iPixelFormat,
|
|
+ UINT nBytes,
|
|
+ PIXELFORMATDESCRIPTOR *ppfd )
|
|
+{
|
|
+ TRACE("physDev:%p, iPixelFormat:%d, nBytes:%d, ppfd:%p\n", physDev, iPixelFormat, nBytes, ppfd);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pDescribePixelFormat(physDev->X11PhysDev, iPixelFormat, nBytes, ppfd);
|
|
+}
|
|
+
|
|
+int DIBDRV_GetPixelFormat( DIBDRVPHYSDEV *physDev)
|
|
+{
|
|
+ TRACE("physDev:%p\n", physDev);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetPixelFormat(physDev->X11PhysDev);
|
|
+}
|
|
+
|
|
+BOOL DIBDRV_SetPixelFormat( DIBDRVPHYSDEV *physDev,
|
|
+ int iPixelFormat,
|
|
+ const PIXELFORMATDESCRIPTOR *ppfd )
|
|
+{
|
|
+ TRACE("physDev:%p, iPixelFormat:%d, ppfd:%p\n", physDev, iPixelFormat, ppfd);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetPixelFormat(physDev->X11PhysDev, iPixelFormat, ppfd);
|
|
+}
|
|
+
|
|
+BOOL DIBDRV_SwapBuffers( DIBDRVPHYSDEV *physDev )
|
|
+{
|
|
+ TRACE("physDev:%p\n", physDev);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSwapBuffers(physDev->X11PhysDev);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglCopyContext
|
|
+ *
|
|
+ * For OpenGL32 wglCopyContext.
|
|
+ */
|
|
+BOOL CDECL DIBDRV_wglCopyContext(HGLRC hglrcSrc, HGLRC hglrcDst, UINT mask)
|
|
+{
|
|
+ TRACE("hglrcSrc:%p, hglrcDst:%p, mask:%x\n", hglrcSrc, hglrcDst, mask);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglCopyContext(hglrcSrc, hglrcDst, mask);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglCreateContext
|
|
+ *
|
|
+ * For OpenGL32 wglCreateContext.
|
|
+ */
|
|
+HGLRC CDECL DIBDRV_wglCreateContext(DIBDRVPHYSDEV *physDev)
|
|
+{
|
|
+ TRACE("physDev:%p\n", physDev);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglCreateContext(physDev->X11PhysDev);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglDeleteContext
|
|
+ *
|
|
+ * For OpenGL32 wglDeleteContext.
|
|
+ */
|
|
+BOOL CDECL DIBDRV_wglDeleteContext(HGLRC hglrc)
|
|
+{
|
|
+ TRACE("hglrc:%p\n", hglrc);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglDeleteContext(hglrc);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglGetProcAddress
|
|
+ *
|
|
+ * For OpenGL32 wglGetProcAddress.
|
|
+ */
|
|
+PROC CDECL DIBDRV_wglGetProcAddress(LPCSTR lpszProc)
|
|
+{
|
|
+ TRACE("lpszProc:%p\n", lpszProc);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglGetProcAddress(lpszProc);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglGetPbufferDCARB
|
|
+ *
|
|
+ * WGL_ARB_pbuffer: wglGetPbufferDCARB
|
|
+ * The function wglGetPbufferDCARB returns a device context for a pbuffer.
|
|
+ * Gdi32 implements the part of this function which creates a device context.
|
|
+ * This part associates the physDev with the X drawable of the pbuffer.
|
|
+ */
|
|
+HDC CDECL DIBDRV_wglGetPbufferDCARB(DIBDRVPHYSDEV *physDev, HPBUFFERARB hPbuffer)
|
|
+{
|
|
+ TRACE("physDev:%p, hPbuffer:%p\n", physDev, hPbuffer);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglGetPbufferDCARB(physDev->X11PhysDev, hPbuffer);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglMakeContextCurrentARB
|
|
+ *
|
|
+ * For OpenGL32 wglMakeContextCurrentARB
|
|
+ */
|
|
+BOOL CDECL DIBDRV_wglMakeContextCurrentARB(DIBDRVPHYSDEV* pDrawDev, DIBDRVPHYSDEV* pReadDev, HGLRC hglrc)
|
|
+{
|
|
+ TRACE("pDrawDev:%p, pReadDev:%p, hglrc:%p\n", pDrawDev, pReadDev, hglrc);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglMakeContextCurrentARB(pDrawDev->X11PhysDev, pReadDev->X11PhysDev, hglrc);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglMakeCurrent
|
|
+ *
|
|
+ * For OpenGL32 wglMakeCurrent.
|
|
+ */
|
|
+BOOL CDECL DIBDRV_wglMakeCurrent(DIBDRVPHYSDEV *physDev, HGLRC hglrc)
|
|
+{
|
|
+ TRACE("physDev:%p, hglrc:%p\n", physDev, hglrc);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglMakeCurrent(physDev->X11PhysDev, hglrc);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglSetPixelFormatWINE
|
|
+ *
|
|
+ * WGL_WINE_pixel_format_passthrough: wglSetPixelFormatWINE
|
|
+ * This is a WINE-specific wglSetPixelFormat which can set the pixel format multiple times.
|
|
+ */
|
|
+BOOL CDECL DIBDRV_wglSetPixelFormatWINE(DIBDRVPHYSDEV *physDev, int iPixelFormat, const PIXELFORMATDESCRIPTOR *ppfd)
|
|
+{
|
|
+ TRACE("physDev:%p, iPixelFormat:%d, ppfd:%p\n", physDev, iPixelFormat, ppfd);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglSetPixelFormatWINE(physDev->X11PhysDev, iPixelFormat, ppfd);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglShareLists
|
|
+ *
|
|
+ * For OpenGL32 wglShareLists.
|
|
+ */
|
|
+BOOL CDECL DIBDRV_wglShareLists(HGLRC hglrc1, HGLRC hglrc2)
|
|
+{
|
|
+ TRACE("hglrc1:%p, hglrc2:%p\n", hglrc1, hglrc2);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglShareLists(hglrc1, hglrc2);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglUseFontBitmapsA
|
|
+ *
|
|
+ * For OpenGL32 wglUseFontBitmapsA.
|
|
+ */
|
|
+BOOL CDECL DIBDRV_wglUseFontBitmapsA(DIBDRVPHYSDEV *physDev, DWORD first, DWORD count, DWORD listBase)
|
|
+{
|
|
+ TRACE("physDev:%p, first:%d, count:%d, listBase:%d\n", physDev, first, count, listBase);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglUseFontBitmapsA(physDev->X11PhysDev, first, count, listBase);
|
|
+}
|
|
+
|
|
+/**
|
|
+ * DIBDRV_wglUseFontBitmapsW
|
|
+ *
|
|
+ * For OpenGL32 wglUseFontBitmapsW.
|
|
+ */
|
|
+BOOL CDECL DIBDRV_wglUseFontBitmapsW(DIBDRVPHYSDEV *physDev, DWORD first, DWORD count, DWORD listBase)
|
|
+{
|
|
+ TRACE("physDev:%p, first:%d, count:%d, listBase:%d\n", physDev, first, count, listBase);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pwglUseFontBitmapsW(physDev->X11PhysDev, first, count, listBase);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/palette.c b/dlls/winedib.drv/palette.c
|
|
new file mode 100644
|
|
index 0000000..28fae09
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/palette.c
|
|
@@ -0,0 +1,90 @@
|
|
+/*
|
|
+ * DIBDRV palette objects
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_RealizePalette
|
|
+ */
|
|
+UINT DIBDRV_RealizePalette( DIBDRVPHYSDEV *physDev, HPALETTE hpal, BOOL primary )
|
|
+{
|
|
+ TRACE("physDev:%p, hpal:%p, primary:%s\n", physDev, hpal, (primary ? "TRUE" : "FALSE"));
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pRealizePalette(physDev->X11PhysDev, hpal, primary);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_UnrealizePalette
|
|
+ */
|
|
+BOOL DIBDRV_UnrealizePalette( HPALETTE hpal )
|
|
+{
|
|
+ TRACE("hpal:%p\n", hpal);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pUnrealizePalette(hpal);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetSystemPaletteEntries
|
|
+ */
|
|
+UINT DIBDRV_GetSystemPaletteEntries( DIBDRVPHYSDEV *physDev, UINT start, UINT count,
|
|
+ LPPALETTEENTRY entries )
|
|
+{
|
|
+ TRACE("physDev:%p, start:%d, count:%d, entries:%p\n", physDev, start, count, entries);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetSystemPaletteEntries(physDev->X11PhysDev, start, count, entries);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetNearestColor
|
|
+ */
|
|
+COLORREF DIBDRV_GetNearestColor( DIBDRVPHYSDEV *physDev, COLORREF color )
|
|
+{
|
|
+ TRACE("physDev:%p, color:%x\n", physDev, color);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetNearestColor(physDev->X11PhysDev, color);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_RealizeDefaultPalette
|
|
+ */
|
|
+UINT DIBDRV_RealizeDefaultPalette( DIBDRVPHYSDEV *physDev )
|
|
+{
|
|
+ TRACE("physDev:%p\n", physDev);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pRealizeDefaultPalette(physDev->X11PhysDev);
|
|
+}
|
|
+
|
|
+BOOL DIBDRV_GetICMProfile(DIBDRVPHYSDEV *physDev, LPDWORD lpcbName, LPWSTR lpszFilename)
|
|
+{
|
|
+ TRACE("physDev:%p, lpcpName:%p, lpszFilename:%p\n", physDev, lpcbName, lpszFilename);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetICMProfile(physDev->X11PhysDev, lpcbName, lpszFilename);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/pen_brush.c b/dlls/winedib.drv/pen_brush.c
|
|
new file mode 100644
|
|
index 0000000..1e992e0
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/pen_brush.c
|
|
@@ -0,0 +1,98 @@
|
|
+/*
|
|
+ * DIBDRV pen objects
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SelectPen
|
|
+ */
|
|
+HPEN DIBDRV_SelectPen( DIBDRVPHYSDEV *physDev, HPEN hpen )
|
|
+{
|
|
+ TRACE("physDev:%p, hpen:%p\n", physDev, hpen);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSelectPen(physDev->X11PhysDev, hpen);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SetDCPenColor
|
|
+ */
|
|
+COLORREF DIBDRV_SetDCPenColor( DIBDRVPHYSDEV *physDev, COLORREF crColor )
|
|
+{
|
|
+ TRACE("physDev:%p, crColor:%x\n", physDev, crColor);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetDCPenColor(physDev->X11PhysDev, crColor);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SelectBrush
|
|
+ */
|
|
+HBRUSH DIBDRV_SelectBrush( DIBDRVPHYSDEV *physDev, HBRUSH hbrush )
|
|
+{
|
|
+ TRACE("physDev:%p, hbrush:%p\n", physDev, hbrush);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSelectBrush(physDev->X11PhysDev, hbrush);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SetDCBrushColor
|
|
+ */
|
|
+COLORREF DIBDRV_SetDCBrushColor( DIBDRVPHYSDEV *physDev, COLORREF crColor )
|
|
+{
|
|
+ TRACE("physDev:%p, crColor:%x\n", physDev, crColor);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetDCBrushColor(physDev->X11PhysDev, crColor);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * SetROP2
|
|
+ */
|
|
+INT DIBDRV_SetROP2( DIBDRVPHYSDEV *physDev, INT rop )
|
|
+{
|
|
+ INT prevRop;
|
|
+
|
|
+ TRACE("physDev:%p, rop:%x\n", physDev, rop);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ prevRop = physDev->rop2;
|
|
+ physDev->rop2 = rop;
|
|
+ return prevRop;
|
|
+ /* note : X11 Driver don't have SetROP2() function exported */
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * SetBkColor
|
|
+ */
|
|
+COLORREF DIBDRV_SetBkColor( DIBDRVPHYSDEV *physDev, COLORREF color )
|
|
+{
|
|
+ TRACE("physDev:%p, color:%x\n", physDev, color);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetBkColor(physDev->X11PhysDev, color);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/text.c b/dlls/winedib.drv/text.c
|
|
new file mode 100644
|
|
index 0000000..fdb075f
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/text.c
|
|
@@ -0,0 +1,55 @@
|
|
+/*
|
|
+ * DIBDRV text functions
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_ExtTextOut
|
|
+ */
|
|
+BOOL
|
|
+DIBDRV_ExtTextOut( DIBDRVPHYSDEV *physDev, INT x, INT y, UINT flags,
|
|
+ const RECT *lprect, LPCWSTR wstr, UINT count,
|
|
+ const INT *lpDx )
|
|
+{
|
|
+ TRACE("physDev:%p, x:%d, y:%d, flags:%x, lprect:%p, wstr:%s, count:%d, lpDx:%p\n",
|
|
+ physDev, x, y, flags, lprect, debugstr_w(wstr), count, lpDx);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pExtTextOut(physDev->X11PhysDev, x, y, flags, lprect,
|
|
+ wstr, count, lpDx);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetTextExtentExPoint
|
|
+ */
|
|
+BOOL DIBDRV_GetTextExtentExPoint( DIBDRVPHYSDEV *physDev, LPCWSTR str, INT count,
|
|
+ INT maxExt, LPINT lpnFit, LPINT alpDx, LPSIZE size )
|
|
+{
|
|
+ TRACE("physDev:%p, str:%s, count:%d, maxExt:%d, lpnFit:%p, alpDx:%p, size:%p\n",
|
|
+ physDev, debugstr_w(str), count, maxExt, lpnFit, alpDx, size);
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetTextExtentExPoint(physDev->X11PhysDev, str, count, maxExt,
|
|
+ lpnFit, alpDx, size);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/video.c b/dlls/winedib.drv/video.c
|
|
new file mode 100644
|
|
index 0000000..6490ac6
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/video.c
|
|
@@ -0,0 +1,48 @@
|
|
+/*
|
|
+ * DIBDRV video functions
|
|
+ *
|
|
+ * Copyright 2009 Massimo Del Fedele
|
|
+ *
|
|
+ * This library is free software; you can redistribute it and/or
|
|
+ * modify it under the terms of the GNU Lesser General Public
|
|
+ * License as published by the Free Software Foundation; either
|
|
+ * version 2.1 of the License, or (at your option) any later version.
|
|
+ *
|
|
+ * This library is distributed in the hope that it will be useful,
|
|
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
+ * Lesser General Public License for more details.
|
|
+ *
|
|
+ * You should have received a copy of the GNU Lesser General Public
|
|
+ * License along with this library; if not, write to the Free Software
|
|
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
+ */
|
|
+
|
|
+#include "config.h"
|
|
+#include "wine/port.h"
|
|
+
|
|
+#include "dibdrv.h"
|
|
+
|
|
+WINE_DEFAULT_DEBUG_CHANNEL(dibdrv);
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_GetDeviceGammaRamp
|
|
+ */
|
|
+BOOL DIBDRV_GetDeviceGammaRamp( DIBDRVPHYSDEV *physDev, LPVOID ramp )
|
|
+{
|
|
+ TRACE("physDev:%p, ramp:%p\n", physDev, ramp);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pGetDeviceGammaRamp(physDev->X11PhysDev, ramp);
|
|
+}
|
|
+
|
|
+/***********************************************************************
|
|
+ * DIBDRV_SetDeviceGammaRamp
|
|
+ */
|
|
+BOOL DIBDRV_SetDeviceGammaRamp( DIBDRVPHYSDEV *physDev, LPVOID ramp )
|
|
+{
|
|
+ TRACE("physDev:%p, ramp:%p\n", physDev, ramp);
|
|
+
|
|
+ ONCE(FIXME("stub\n"));
|
|
+ return _DIBDRV_GetDisplayDriver()->pSetDeviceGammaRamp(physDev->X11PhysDev, ramp);
|
|
+}
|
|
diff --git a/dlls/winedib.drv/winedib.drv.spec b/dlls/winedib.drv/winedib.drv.spec
|
|
new file mode 100644
|
|
index 0000000..3743b2b
|
|
--- /dev/null
|
|
+++ b/dlls/winedib.drv/winedib.drv.spec
|
|
@@ -0,0 +1,74 @@
|
|
+@ cdecl AlphaBlend(ptr long long long long ptr long long long long long) DIBDRV_AlphaBlend
|
|
+@ cdecl Arc(ptr long long long long long long long long) DIBDRV_Arc
|
|
+@ cdecl BitBlt(ptr long long long long ptr long long long) DIBDRV_BitBlt
|
|
+@ cdecl ChoosePixelFormat(ptr ptr) DIBDRV_ChoosePixelFormat
|
|
+@ cdecl Chord(ptr long long long long long long long long) DIBDRV_Chord
|
|
+@ cdecl CreateBitmap(ptr long ptr) DIBDRV_CreateBitmap
|
|
+@ cdecl CreateDC(long ptr wstr wstr wstr ptr) DIBDRV_CreateDC
|
|
+@ cdecl CreateDIBSection(ptr long ptr long) DIBDRV_CreateDIBSection
|
|
+@ cdecl DeleteBitmap(long) DIBDRV_DeleteBitmap
|
|
+@ cdecl DeleteDC(ptr) DIBDRV_DeleteDC
|
|
+@ cdecl DescribePixelFormat(ptr long long ptr) DIBDRV_DescribePixelFormat
|
|
+@ cdecl Ellipse(ptr long long long long) DIBDRV_Ellipse
|
|
+@ cdecl EnumDeviceFonts(ptr ptr ptr long) DIBDRV_EnumDeviceFonts
|
|
+@ cdecl ExtEscape(ptr long long ptr long ptr) DIBDRV_ExtEscape
|
|
+@ cdecl ExtFloodFill(ptr long long long long) DIBDRV_ExtFloodFill
|
|
+@ cdecl ExtTextOut(ptr long long long ptr ptr long ptr) DIBDRV_ExtTextOut
|
|
+@ cdecl GetBitmapBits(long ptr long) DIBDRV_GetBitmapBits
|
|
+@ cdecl GetCharWidth(ptr long long ptr) DIBDRV_GetCharWidth
|
|
+@ cdecl GetDCOrgEx(ptr ptr) DIBDRV_GetDCOrgEx
|
|
+@ cdecl GetDIBits(ptr long long long ptr ptr long) DIBDRV_GetDIBits
|
|
+@ cdecl GetDeviceCaps(ptr long) DIBDRV_GetDeviceCaps
|
|
+@ cdecl GetDeviceGammaRamp(ptr ptr) DIBDRV_GetDeviceGammaRamp
|
|
+@ cdecl GetICMProfile(ptr ptr ptr) DIBDRV_GetICMProfile
|
|
+@ cdecl GetNearestColor(ptr long) DIBDRV_GetNearestColor
|
|
+@ cdecl GetPixel(ptr long long) DIBDRV_GetPixel
|
|
+@ cdecl GetPixelFormat(ptr) DIBDRV_GetPixelFormat
|
|
+@ cdecl GetSystemPaletteEntries(ptr long long ptr) DIBDRV_GetSystemPaletteEntries
|
|
+@ cdecl GetTextExtentExPoint(ptr ptr long long ptr ptr ptr) DIBDRV_GetTextExtentExPoint
|
|
+@ cdecl GetTextMetrics(ptr ptr) DIBDRV_GetTextMetrics
|
|
+@ cdecl LineTo(ptr long long) DIBDRV_LineTo
|
|
+@ cdecl PaintRgn(ptr long) DIBDRV_PaintRgn
|
|
+@ cdecl PatBlt(ptr long long long long long) DIBDRV_PatBlt
|
|
+@ cdecl Pie(ptr long long long long long long long long) DIBDRV_Pie
|
|
+@ cdecl PolyPolygon(ptr ptr ptr long) DIBDRV_PolyPolygon
|
|
+@ cdecl PolyPolyline(ptr ptr ptr long) DIBDRV_PolyPolyline
|
|
+@ cdecl Polygon(ptr ptr long) DIBDRV_Polygon
|
|
+@ cdecl Polyline(ptr ptr long) DIBDRV_Polyline
|
|
+@ cdecl RealizeDefaultPalette(ptr) DIBDRV_RealizeDefaultPalette
|
|
+@ cdecl RealizePalette(ptr long long) DIBDRV_RealizePalette
|
|
+@ cdecl Rectangle(ptr long long long long) DIBDRV_Rectangle
|
|
+@ cdecl RoundRect(ptr long long long long long long) DIBDRV_RoundRect
|
|
+@ cdecl SelectBitmap(ptr long) DIBDRV_SelectBitmap
|
|
+@ cdecl SelectBrush(ptr long) DIBDRV_SelectBrush
|
|
+@ cdecl SelectFont(ptr long long) DIBDRV_SelectFont
|
|
+@ cdecl SelectPen(ptr long) DIBDRV_SelectPen
|
|
+@ cdecl SetBitmapBits(long ptr long) DIBDRV_SetBitmapBits
|
|
+@ cdecl SetBkColor(ptr long) DIBDRV_SetBkColor
|
|
+@ cdecl SetDCBrushColor(ptr long) DIBDRV_SetDCBrushColor
|
|
+@ cdecl SetDCOrg(ptr long long) DIBDRV_SetDCOrg
|
|
+@ cdecl SetDCPenColor(ptr long) DIBDRV_SetDCPenColor
|
|
+@ cdecl SetDIBColorTable(ptr long long ptr) DIBDRV_SetDIBColorTable
|
|
+@ cdecl SetDIBits(ptr long long long ptr ptr long) DIBDRV_SetDIBits
|
|
+@ cdecl SetDIBitsToDevice(ptr long long long long long long long long ptr ptr long) DIBDRV_SetDIBitsToDevice
|
|
+@ cdecl SetDeviceClipping(ptr long long) DIBDRV_SetDeviceClipping
|
|
+@ cdecl SetDeviceGammaRamp(ptr ptr) DIBDRV_SetDeviceGammaRamp
|
|
+@ cdecl SetPixel(ptr long long long) DIBDRV_SetPixel
|
|
+@ cdecl SetPixelFormat(ptr long ptr) DIBDRV_SetPixelFormat
|
|
+@ cdecl SetTextColor(ptr long) DIBDRV_SetTextColor
|
|
+@ cdecl StretchBlt(ptr long long long long ptr long long long long long) DIBDRV_StretchBlt
|
|
+@ cdecl SwapBuffers(ptr) DIBDRV_SwapBuffers
|
|
+@ cdecl UnrealizePalette(long) DIBDRV_UnrealizePalette
|
|
+@ cdecl SetROP2(ptr long) DIBDRV_SetROP2
|
|
+# OpenGL
|
|
+@ cdecl wglCopyContext(long long long) DIBDRV_wglCopyContext
|
|
+@ cdecl wglCreateContext(ptr) DIBDRV_wglCreateContext
|
|
+@ cdecl wglDeleteContext(long) DIBDRV_wglDeleteContext
|
|
+@ cdecl wglGetProcAddress(str) DIBDRV_wglGetProcAddress
|
|
+@ cdecl wglGetPbufferDCARB(ptr ptr) DIBDRV_wglGetPbufferDCARB
|
|
+@ cdecl wglMakeContextCurrentARB(ptr ptr long) DIBDRV_wglMakeContextCurrentARB
|
|
+@ cdecl wglMakeCurrent(ptr long) DIBDRV_wglMakeCurrent
|
|
+@ cdecl wglSetPixelFormatWINE(ptr long ptr) DIBDRV_wglSetPixelFormatWINE
|
|
+@ cdecl wglShareLists(long long) DIBDRV_wglShareLists
|
|
+@ cdecl wglUseFontBitmapsA(ptr long long long) DIBDRV_wglUseFontBitmapsA
|
|
+@ cdecl wglUseFontBitmapsW(ptr long long long) DIBDRV_wglUseFontBitmapsW
|