Author: tkreuzer
Date: Thu Sep 6 04:28:04 2007
New Revision: 28889
URL:
http://svn.reactos.org/svn/reactos?rev=28889&view=rev
Log:
- move dx gdi object type definitions from intddraw.h to ntgdihdl.h, change 2 type values
to make them match windows, comment out 2 unused types for now.
- add pool tags for gdi objects
- add a bitmask for basic type (0x01 - 0x1f)
Modified:
trunk/reactos/include/reactos/win32k/ntgdihdl.h
trunk/reactos/subsystems/win32/win32k/include/intddraw.h
Modified: trunk/reactos/include/reactos/win32k/ntgdihdl.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/win32k/ntg…
==============================================================================
--- trunk/reactos/include/reactos/win32k/ntgdihdl.h (original)
+++ trunk/reactos/include/reactos/win32k/ntgdihdl.h Thu Sep 6 04:28:04 2007
@@ -23,6 +23,7 @@
/* Handle Masks and shifts */
#define GDI_HANDLE_INDEX_MASK (GDI_HANDLE_COUNT - 1)
#define GDI_HANDLE_TYPE_MASK 0x007f0000
+#define GDI_HANDLE_BASETYPE_MASK 0x001f0000
#define GDI_HANDLE_STOCK_MASK 0x00800000
#define GDI_HANDLE_REUSE_MASK 0xff000000
#define GDI_HANDLE_UPPER_MASK
(GDI_HANDLE_TYPE_MASK|GDI_HANDLE_STOCK_MASK|GDI_HANDLE_REUSE_MASK)
@@ -33,6 +34,21 @@
#define GDI_ENTRY_REUSE_INC 0x00000100
#define GDI_ENTRY_REUSECNT_SHIFT 8
#define GDI_ENTRY_UPPER_SHIFT 16
+
+#define GDI_OBJECT_TAG_DC TAG('G', 'l', 'a', '1')
+#define GDI_OBJECT_TAG_REGION TAG('G', 'l', 'a', '4')
+#define GDI_OBJECT_TAG_BITMAP TAG('G', 'l', 'a', '5')
+#define GDI_OBJECT_TAG_CLIOBJ TAG('G', 'h', '0', '6')
+#define GDI_OBJECT_TAG_PATH TAG('G', 'h', '0', '7')
+#define GDI_OBJECT_TAG_PALETTE TAG('G', 'l', 'a', '8')
+#define GDI_OBJECT_TAG_COLSPC TAG('G', 'h', '0', '9')
+#define GDI_OBJECT_TAG_FONT TAG('G', 'l', 'a', ':')
+#define GDI_OBJECT_TAG_PFE TAG('G', 'h', '0',
'<')
+#define GDI_OBJECT_TAG_BRUSH TAG('G', 'l', 'a', '@')
+#define GDI_OBJECT_TAG_ENUMFONT TAG('G', 'h', '0', 'F')
+
+#define GDI_OBJECT_TAG_DDRAW TAG('D', 'h', ' ', '1')
+#define GDI_OBJECT_TAG_DDSURF TAG('D', 'h', ' ', '2')
/*! \defgroup GDI object types
*
@@ -40,20 +56,33 @@
*
*/
/*@{*/
-#define GDI_OBJECT_TYPE_DC 0x00010000
-#define GDI_OBJECT_TYPE_REGION 0x00040000
-#define GDI_OBJECT_TYPE_BITMAP 0x00050000
-#define GDI_OBJECT_TYPE_PALETTE 0x00080000
-#define GDI_OBJECT_TYPE_FONT 0x000a0000
-#define GDI_OBJECT_TYPE_BRUSH 0x00100000
+#define GDI_OBJECT_TYPE_DC 0x00010000
+#define GDI_OBJECT_TYPE_DIRECTDRAW 0x00020000 /* Should be moved away from gdi objects
*/
+#define GDI_OBJECT_TYPE_DD_SURFACE 0x00030000 /* Should be moved away from gdi objects
*/
+#define GDI_OBJECT_TYPE_REGION 0x00040000
+#define GDI_OBJECT_TYPE_BITMAP 0x00050000
+#define GDI_OBJECT_TYPE_CLIOBJ 0x00060000
+#define GDI_OBJECT_TYPE_PATH 0x00070000
+#define GDI_OBJECT_TYPE_PALETTE 0x00080000
+#define GDI_OBJECT_TYPE_COLORSPACE 0x00090000
+#define GDI_OBJECT_TYPE_FONT 0x000a0000
+
+#define GDI_OBJECT_TYPE_BRUSH 0x00100000
+#define GDI_OBJECT_TYPE_DD_VIDEOPORT 0x00120000 /* Should be moved away from gdi objects
*/
+#define GDI_OBJECT_TYPE_DD_MOTIONCOMP 0x00140000 /* Should be moved away from gdi objects
*/
+#define GDI_OBJECT_TYPE_ENUMFONT 0x00160000
+
+/* Following object types are derived types from the above base types
+ use 0x001f0000 as mask to get the base type */
#define GDI_OBJECT_TYPE_EMF 0x00210000
+#define GDI_OBJECT_TYPE_METAFILE 0x00260000
+#define GDI_OBJECT_TYPE_ENHMETAFILE 0x00460000
#define GDI_OBJECT_TYPE_PEN 0x00300000
#define GDI_OBJECT_TYPE_EXTPEN 0x00500000
-#define GDI_OBJECT_TYPE_COLORSPACE 0x00090000
#define GDI_OBJECT_TYPE_METADC 0x00660000
-#define GDI_OBJECT_TYPE_METAFILE 0x00260000
-#define GDI_OBJECT_TYPE_ENHMETAFILE 0x00460000
-#define GDI_OBJECT_TYPE_ENUMFONT 0x00160000
+/*#define GDI_OBJECT_TYPE_DD_PALETTE 0x00630000 unused at the moment, other value
required */
+/*#define GDI_OBJECT_TYPE_DD_CLIPPER 0x00640000 unused at the moment, other value
required */
+
/* Following object types made up for ROS */
#define GDI_OBJECT_TYPE_DONTCARE 0x007f0000
/** Not really an object type. Forces GDI_FreeObj to be silent. */
Modified: trunk/reactos/subsystems/win32/win32k/include/intddraw.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/include/intddraw.h (original)
+++ trunk/reactos/subsystems/win32/win32k/include/intddraw.h Thu Sep 6 04:28:04 2007
@@ -3,13 +3,6 @@
#include <ddrawint.h>
#include <ddkernel.h>
-
-#define GDI_OBJECT_TYPE_DIRECTDRAW 0x00600000
-#define GDI_OBJECT_TYPE_DD_SURFACE 0x00610000
-#define GDI_OBJECT_TYPE_DD_VIDEOPORT 0x00620000
-#define GDI_OBJECT_TYPE_DD_PALETTE 0x00630000
-#define GDI_OBJECT_TYPE_DD_CLIPPER 0x00640000
-#define GDI_OBJECT_TYPE_DD_MOTIONCOMP 0x00650000
typedef struct
{