Author: greatlrd
Date: Sat Feb 24 16:58:25 2007
New Revision: 25901
URL:
http://svn.reactos.org/svn/reactos?rev=25901&view=rev
Log:
adding -dump as param to dumping out all struct and data
Modified:
trunk/rosapps/dxtest/win32kdxtest/dump.c
trunk/rosapps/dxtest/win32kdxtest/main.c
trunk/rosapps/dxtest/win32kdxtest/test.h
Modified: trunk/rosapps/dxtest/win32kdxtest/dump.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/dxtest/win32kdxtest/dump.c…
==============================================================================
--- trunk/rosapps/dxtest/win32kdxtest/dump.c (original)
+++ trunk/rosapps/dxtest/win32kdxtest/dump.c Sat Feb 24 16:58:25 2007
@@ -9,6 +9,15 @@
#include "test.h"
+
+void
+dump_CallBackFlags(DWORD *pCallBackFlags, char *text)
+{
+ printf("dumping the CallBackFlags from %s\n",text);
+ printf("pCallBackFlags[0] : 0x%08lx\n",pCallBackFlags[0]);
+ printf("pCallBackFlags[1] : 0x%08lx\n",pCallBackFlags[1]);
+ printf("pCallBackFlags[2] : 0x%08lx\n",pCallBackFlags[2]);
+}
void
dump_halinfo(DD_HALINFO *pHalInfo, char *text)
Modified: trunk/rosapps/dxtest/win32kdxtest/main.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/dxtest/win32kdxtest/main.c…
==============================================================================
--- trunk/rosapps/dxtest/win32kdxtest/main.c (original)
+++ trunk/rosapps/dxtest/win32kdxtest/main.c Sat Feb 24 16:58:25 2007
@@ -12,6 +12,8 @@
#include <dll/directx/d3d8thk.h>
#include "test.h"
+BOOL dumping_on =FALSE;
+
/* we using d3d8thk.dll it is doing the real syscall in windows 2000
* in ReactOS and Windows XP and higher d3d8thk.dll it linking to
* gdi32.dll instead doing syscall, gdi32.dll export DdEntry1-56
@@ -23,6 +25,14 @@
int main(int argc, char **argv)
{
HANDLE hDirectDrawLocal;
+
+ if (argc == 2)
+ {
+ if (stricmp(argv[1],"-dump")==0)
+ {
+ dumping_on = TRUE;
+ }
+ }
hDirectDrawLocal = test_NtGdiDdCreateDirectDrawObject();
@@ -162,11 +172,14 @@
if ((pHalInfo->dwSize != sizeof(DD_HALINFO)) &&
(pHalInfo->dwSize != sizeof(DD_HALINFO_V4)))
{
- printf("10. if this show for NT 2000/XP/2003 ignore it,
NtGdiDdQueryDirectDrawObject(hDirectDrawLocal, NULL, ...);\n");
+ printf("10. if this show for NT 2000/XP/2003 ignore it,
NtGdiDdQueryDirectDrawObject(hDirectDrawLocal, pHalInfo, NULL, ...);\n");
fails++;
}
- /* FIXME dump pHalInfo */
+ if (dumping_on == TRUE)
+ {
+ dump_halinfo(pHalInfo,"NtGdiDdQueryDirectDrawObject(hDirectDrawLocal,
pHalInfo, NULL, ...)");
+ }
/* testing OsThunkDdQueryDirectDrawObject( hDirectDrawLocal, pHalInfo,
pCallBackFlags, NULL, .... */
printf("testing DdQueryDirectDrawObject( hDD, pHalInfo, pCallBackFlags, NULL,
....)\n");
@@ -199,8 +212,11 @@
fails++;
}
- /* FIXME dump pHalInfo */
- /* FIXME dump pCallBackFlags */
+ if (dumping_on == TRUE)
+ {
+ dump_halinfo(pHalInfo,"NtGdiDdQueryDirectDrawObject(hDirectDrawLocal,
pHalInfo, pCallBackFlags, NULL, ...)");
+
dump_CallBackFlags(pCallBackFlags,"NtGdiDdQueryDirectDrawObject(hDirectDrawLocal,
pHalInfo, pCallBackFlags, NULL, ...)");
+ }
/* testing OsThunkDdQueryDirectDrawObject( hDirectDrawLocal, pHalInfo,
pCallBackFlags, NULL, .... */
printf("testing DdQueryDirectDrawObject( hDD, pHalInfo, pCallBackFlags,
puD3dCallbacks, NULL, ....)\n");
@@ -236,9 +252,12 @@
fails++;
}
- /* FIXME dump pHalInfo */
- /* FIXME dump pCallBackFlags */
- /* FIXME dump puD3dCallbacks */
+ if (dumping_on == TRUE)
+ {
+ dump_halinfo(pHalInfo,"NtGdiDdQueryDirectDrawObject(hDirectDrawLocal,
pHalInfo, pCallBackFlags, NULL, ...)");
+
dump_CallBackFlags(pCallBackFlags,"NtGdiDdQueryDirectDrawObject(hDirectDrawLocal,
pHalInfo, pCallBackFlags, NULL, ...)");
+ /* FIXME dump puD3dCallbacks */
+ }
/* testing OsThunkDdQueryDirectDrawObject( hDirectDrawLocal, pHalInfo,
pCallBackFlags, NULL, .... */
printf("testing DdQueryDirectDrawObject( hDD, pHalInfo, pCallBackFlags,
puD3dCallbacks, puD3dDriverData, NULL, ....)\n");
@@ -277,14 +296,13 @@
fails++;
}
- /* FIXME dump pHalInfo */
- /* FIXME dump pCallBackFlags */
- /* FIXME dump puD3dCallbacks */
- /* FIXME dump puD3dDriverData */
-
-
-
-
+ if (dumping_on == TRUE)
+ {
+ dump_halinfo(pHalInfo,"NtGdiDdQueryDirectDrawObject(hDirectDrawLocal,
pHalInfo, pCallBackFlags, NULL, ...)");
+
dump_CallBackFlags(pCallBackFlags,"NtGdiDdQueryDirectDrawObject(hDirectDrawLocal,
pHalInfo, pCallBackFlags, NULL, ...)");
+ /* FIXME dump puD3dCallbacks */
+ /* FIXME dump puD3dDriverData */
+ }
show_status(fails, "NtGdiDdQueryDirectDrawObject\0");
}
Modified: trunk/rosapps/dxtest/win32kdxtest/test.h
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/dxtest/win32kdxtest/test.h…
==============================================================================
--- trunk/rosapps/dxtest/win32kdxtest/test.h (original)
+++ trunk/rosapps/dxtest/win32kdxtest/test.h Sat Feb 24 16:58:25 2007
@@ -5,7 +5,7 @@
void test_NtGdiDdQueryDirectDrawObject( HANDLE hDirectDrawLocal);
void dump_halinfo(DD_HALINFO *pHalInfo, char *text);
-
+void dump_CallBackFlags(DWORD *pCallBackFlags, char *text);