2 * DirectX File private interfaces (D3DXOF.DLL)
4 * Copyright 2004, 2008 Christian Costa
6 * This file contains the (internal) driver registration functions,
7 * driver enumeration APIs and DirectDraw creation functions.
9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Lesser General Public
11 * License as published by the Free Software Foundation; either
12 * version 2.1 of the License, or (at your option) any later version.
14 * This library is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 * Lesser General Public License for more details.
19 * You should have received a copy of the GNU Lesser General Public
20 * License along with this library; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
24 #ifndef __D3DXOF_PRIVATE_INCLUDED__
25 #define __D3DXOF_PRIVATE_INCLUDED__
36 #define MAX_NAME_LEN 32
37 #define MAX_ARRAY_DIM 4
38 #define MAX_MEMBERS 50
39 #define MAX_CHILDREN 100
40 #define MAX_TEMPLATES 200
41 #define MAX_OBJECTS 500
42 #define MAX_SUBOBJECTS 2000
43 #define MAX_STRINGS_BUFFER 10000
48 char name[MAX_NAME_LEN];
50 BOOL dim_fixed[MAX_ARRAY_DIM]; /* fixed or variable */
51 ULONG dim_value[MAX_ARRAY_DIM]; /* fixed value or member index */
55 char name[MAX_NAME_LEN];
60 char children[MAX_CHILDREN][MAX_NAME_LEN];
62 member members[MAX_MEMBERS];
73 struct _xobject* ptarget;
74 char name[MAX_NAME_LEN];
81 xobject_member members[MAX_MEMBERS];
84 struct _xobject * children[MAX_CHILDREN];
85 struct _xobject * root;
88 typedef struct _xobject xobject;
91 IDirectXFile IDirectXFile_iface;
94 xtemplate xtemplates[MAX_TEMPLATES];
98 IDirectXFileBinary IDirectXFileBinary_iface;
100 } IDirectXFileBinaryImpl;
103 IDirectXFileData IDirectXFileData_iface;
110 } IDirectXFileDataImpl;
113 IDirectXFileDataReference IDirectXFileDataReference_iface;
116 } IDirectXFileDataReferenceImpl;
119 IDirectXFileObject IDirectXFileObject_iface;
121 } IDirectXFileObjectImpl;
124 /* Buffer to parse */
134 xobject** pxo_globals;
135 ULONG nb_pxo_globals;
137 IDirectXFileImpl* pdxf;
139 xtemplate* pxt[MAX_SUBOBJECTS];
147 IDirectXFileEnumObject IDirectXFileEnumObject_iface;
149 LPBYTE mapped_memory;
150 LPBYTE decomp_buffer;
152 IDirectXFileImpl* pDirectXFile;
154 xobject* xobjects[MAX_OBJECTS];
155 IDirectXFileData* pRefObjects[MAX_OBJECTS];
156 } IDirectXFileEnumObjectImpl;
159 IDirectXFileSaveObject IDirectXFileSaveObject_iface;
161 } IDirectXFileSaveObjectImpl;
163 HRESULT IDirectXFileImpl_Create(IUnknown *pUnkOuter, LPVOID *ppObj) DECLSPEC_HIDDEN;
165 HRESULT parse_header(parse_buffer *buf, BYTE **decomp_buffer_ptr) DECLSPEC_HIDDEN;
166 BOOL parse_object(parse_buffer * buf) DECLSPEC_HIDDEN;
167 BOOL parse_templates(parse_buffer * buf) DECLSPEC_HIDDEN;
169 int mszip_decompress(int inlen, int outlen, char* inbuffer, char* outbuffer) DECLSPEC_HIDDEN;
171 #endif /* __D3DXOF_PRIVATE_INCLUDED__ */