ReactOS 0.4.16-dev-306-g647d351
main.c
Go to the documentation of this file.
1
2#include <windows.h>
3#include <stdio.h>
4
5#include <ddrawi.h>
6#include <d3dhal.h>
7
8/* Black Box program for D3DParseUnknownCommand in ddraw.dll
9 *
10 * This program scaning all return valu that D3DParseUnknownCommand have in ddraw.dll
11 * This command is not 100% document in MSDN so I using ddk kit doc and WinCE document
12 * and ms ddk / ms sdk to figout the basic. and MSDN was unclare what this command support for
13 * D3DHAL_DP2COMMAND dp2command->bCommand so I wrote this small scanner
14 *
15 * it will show D3DParseUnknownCommand dp2command->bCommand support follow command
16 * command hex dec
17 * D3DDP2OP_VIEWPORTINFO (aka 0x1c) 28
18 * D3DDP2OP_WINFO (aka 0x1d) 29
19 * Unknown (aka 0x0d) 13
20 *
21 * no doc in msdn about command 13 (dec) I will exaime it later
22 *
23 */
24
26VOID BuildReturnCode(DWORD * ReturnCode);
27
29{
30 DWORD ReturnCode[256];
31
32 BuildReturnCode(ReturnCode);
33
34 return 0;
35}
36
38{
39 INT t;
40 D3DHAL_DP2COMMAND dp2command;
41 DWORD lplpvReturnedCommand[2];
42
43 for (t=0;t<256;t++)
44 {
45 dp2command.bCommand = t;
46 ReturnCode[t] = D3DParseUnknownCommand ( (LPVOID) &dp2command, (LPVOID *) lplpvReturnedCommand) ;
47 printf("D3DParseUnknownCommand return code = %x command %d \n", (UINT)ReturnCode[t], t);
48 }
49}
static int argc
Definition: ServiceArgs.c:12
HRESULT WINAPI D3DParseUnknownCommand(LPVOID lpCmd, LPVOID *lpRetCmd)
Definition: main.c:357
int main()
Definition: test.c:6
unsigned long DWORD
Definition: ntddk_ex.h:95
#define printf
Definition: freeldr.h:97
GLdouble GLdouble t
Definition: gl.h:2047
VOID BuildReturnCode(DWORD *ReturnCode)
Definition: main.c:37
#define argv
Definition: mplay32.c:18
unsigned int UINT
Definition: ndis.h:50
int32_t INT
Definition: typedefs.h:58
char TCHAR
Definition: xmlstorage.h:189