Commit 99acd7df authored by Francois Gouget's avatar Francois Gouget Committed by Alexandre Julliard

Use the DUMMYUNIONNAME macros so that the headers can be used in

Winelib.
parent e4d09327
...@@ -429,7 +429,7 @@ HRESULT WINAPI MESA_IDirect3DDevice2Impl_EndScene(LPDIRECT3DDEVICE2 iface) { ...@@ -429,7 +429,7 @@ HRESULT WINAPI MESA_IDirect3DDevice2Impl_EndScene(LPDIRECT3DDEVICE2 iface) {
I am currently working on a set of patches for Mesa to have OSMesa support I am currently working on a set of patches for Mesa to have OSMesa support
16 bpp surfaces => we will able to render directly onto the surface, no 16 bpp surfaces => we will able to render directly onto the surface, no
need to do a bpp conversion */ need to do a bpp conversion */
dest = (unsigned short *) sdesc.y.lpSurface; dest = (unsigned short *) sdesc.u2.lpSurface;
src = ((unsigned char *) odev->buffer) + 4 * (sdesc.dwWidth * (sdesc.dwHeight - 1)); src = ((unsigned char *) odev->buffer) + 4 * (sdesc.dwWidth * (sdesc.dwHeight - 1));
for (y = 0; y < sdesc.dwHeight; y++) { for (y = 0; y < sdesc.dwHeight; y++) {
unsigned char *lsrc = src; unsigned char *lsrc = src;
...@@ -448,7 +448,7 @@ HRESULT WINAPI MESA_IDirect3DDevice2Impl_EndScene(LPDIRECT3DDEVICE2 iface) { ...@@ -448,7 +448,7 @@ HRESULT WINAPI MESA_IDirect3DDevice2Impl_EndScene(LPDIRECT3DDEVICE2 iface) {
} }
/* Unlock the surface */ /* Unlock the surface */
IDirectDrawSurface3_Unlock(surf,sdesc.y.lpSurface); IDirectDrawSurface3_Unlock(surf,sdesc.u2.lpSurface);
#else #else
/* No need to do anything here... */ /* No need to do anything here... */
#endif #endif
...@@ -698,45 +698,45 @@ static HRESULT WINAPI MESA_IDirect3DDevice2Impl_SetTransform( ...@@ -698,45 +698,45 @@ static HRESULT WINAPI MESA_IDirect3DDevice2Impl_SetTransform(
case D3DVT_VERTEX: { \ case D3DVT_VERTEX: { \
D3DVERTEX *vx = ((D3DVERTEX *) lpvertex) + INDEX; \ D3DVERTEX *vx = ((D3DVERTEX *) lpvertex) + INDEX; \
\ \
glNormal3f(vx->nx.nx, vx->ny.ny, vx->nz.nz); \ glNormal3f(vx->u4.nx, vx->u5.ny, vx->u6.nz); \
glVertex3f(vx->x.x, vx->y.y, vx->z.z); \ glVertex3f(vx->u1.x, vx->u2.y, vx->u3.z); \
TRACE(" V: %f %f %f\n", vx->x.x, vx->y.y, vx->z.z); \ TRACE(" V: %f %f %f\n", vx->u1.x, vx->u2.y, vx->u3.z); \
} break; \ } break; \
\ \
case D3DVT_LVERTEX: { \ case D3DVT_LVERTEX: { \
D3DLVERTEX *vx = ((D3DLVERTEX *) lpvertex) + INDEX; \ D3DLVERTEX *vx = ((D3DLVERTEX *) lpvertex) + INDEX; \
DWORD col = vx->c.color; \ DWORD col = vx->u4.color; \
\ \
glColor3f(((col >> 16) & 0xFF) / 255.0, \ glColor3f(((col >> 16) & 0xFF) / 255.0, \
((col >> 8) & 0xFF) / 255.0, \ ((col >> 8) & 0xFF) / 255.0, \
((col >> 0) & 0xFF) / 255.0); \ ((col >> 0) & 0xFF) / 255.0); \
glVertex3f(vx->x.x, vx->y.y, vx->z.z); \ glVertex3f(vx->u1.x, vx->u2.y, vx->u3.z); \
TRACE(" LV: %f %f %f (%02lx %02lx %02lx)\n", \ TRACE(" LV: %f %f %f (%02lx %02lx %02lx)\n", \
vx->x.x, vx->y.y, vx->z.z, \ vx->u1.x, vx->u2.y, vx->u3.z, \
((col >> 16) & 0xFF), ((col >> 8) & 0xFF), ((col >> 0) & 0xFF));\ ((col >> 16) & 0xFF), ((col >> 8) & 0xFF), ((col >> 0) & 0xFF));\
} break; \ } break; \
\ \
case D3DVT_TLVERTEX: { \ case D3DVT_TLVERTEX: { \
D3DTLVERTEX *vx = ((D3DTLVERTEX *) lpvertex) + INDEX; \ D3DTLVERTEX *vx = ((D3DTLVERTEX *) lpvertex) + INDEX; \
DWORD col = vx->c.color; \ DWORD col = vx->u5.color; \
\ \
glColor3f(((col >> 16) & 0xFF) / 255.0, \ glColor3f(((col >> 16) & 0xFF) / 255.0, \
((col >> 8) & 0xFF) / 255.0, \ ((col >> 8) & 0xFF) / 255.0, \
((col >> 0) & 0xFF) / 255.0); \ ((col >> 0) & 0xFF) / 255.0); \
glTexCoord2f(vx->u.tu, vx->v.tv); \ glTexCoord2f(vx->u7.tu, vx->u8.tv); \
if (vx->r.rhw < 0.01) \ if (vx->u4.rhw < 0.01) \
glVertex3f(vx->x.sx, \ glVertex3f(vx->u1.sx, \
vx->y.sy, \ vx->u2.sy, \
vx->z.sz); \ vx->u3.sz); \
else \ else \
glVertex4f(vx->x.sx / vx->r.rhw, \ glVertex4f(vx->u1.sx / vx->u4.rhw, \
vx->y.sy / vx->r.rhw, \ vx->u2.sy / vx->u4.rhw, \
vx->z.sz / vx->r.rhw, \ vx->u3.sz / vx->u4.rhw, \
1.0 / vx->r.rhw); \ 1.0 / vx->u4.rhw); \
TRACE(" TLV: %f %f %f (%02lx %02lx %02lx) (%f %f) (%f)\n", \ TRACE(" TLV: %f %f %f (%02lx %02lx %02lx) (%f %f) (%f)\n", \
vx->x.sx, vx->y.sy, vx->z.sz, \ vx->u1.sx, vx->u2.sy, vx->u3.sz, \
((col >> 16) & 0xFF), ((col >> 8) & 0xFF), ((col >> 0) & 0xFF),\ ((col >> 16) & 0xFF), ((col >> 8) & 0xFF), ((col >> 0) & 0xFF),\
vx->u.tu, vx->v.tv, vx->r.rhw); \ vx->u7.tu, vx->u8.tv, vx->u4.rhw); \
} break; \ } break; \
\ \
default: \ default: \
...@@ -985,7 +985,7 @@ static HRESULT WINAPI MESA_IDirect3DDeviceImpl_BeginScene(LPDIRECT3DDEVICE iface ...@@ -985,7 +985,7 @@ static HRESULT WINAPI MESA_IDirect3DDeviceImpl_BeginScene(LPDIRECT3DDEVICE iface
FIXME("(%p)->(): stub\n", This); FIXME("(%p)->(): stub\n", This);
/* We get the pointer to the surface (should be done on flip) */ /* We get the pointer to the surface (should be done on flip) */
/* odev->zb->pbuf = This->surface->s.surface_desc.y.lpSurface; */ /* odev->zb->pbuf = This->surface->s.surface_desc.u2.lpSurface; */
return DD_OK; return DD_OK;
} }
...@@ -1018,7 +1018,7 @@ static HRESULT WINAPI MESA_IDirect3DDeviceImpl_EndScene(LPDIRECT3DDEVICE iface) ...@@ -1018,7 +1018,7 @@ static HRESULT WINAPI MESA_IDirect3DDeviceImpl_EndScene(LPDIRECT3DDEVICE iface)
I am currently working on a set of patches for Mesa to have OSMesa support I am currently working on a set of patches for Mesa to have OSMesa support
16 bpp surfaces => we will able to render directly onto the surface, no 16 bpp surfaces => we will able to render directly onto the surface, no
need to do a bpp conversion */ need to do a bpp conversion */
dest = (unsigned short *) sdesc.y.lpSurface; dest = (unsigned short *) sdesc.u2.lpSurface;
src = ((unsigned char *) odev->buffer) + 4 * (sdesc.dwWidth * (sdesc.dwHeight - 1)); src = ((unsigned char *) odev->buffer) + 4 * (sdesc.dwWidth * (sdesc.dwHeight - 1));
for (y = 0; y < sdesc.dwHeight; y++) { for (y = 0; y < sdesc.dwHeight; y++) {
unsigned char *lsrc = src; unsigned char *lsrc = src;
...@@ -1038,7 +1038,7 @@ static HRESULT WINAPI MESA_IDirect3DDeviceImpl_EndScene(LPDIRECT3DDEVICE iface) ...@@ -1038,7 +1038,7 @@ static HRESULT WINAPI MESA_IDirect3DDeviceImpl_EndScene(LPDIRECT3DDEVICE iface)
} }
/* Unlock the surface */ /* Unlock the surface */
IDirectDrawSurface3_Unlock(surf,sdesc.y.lpSurface); IDirectDrawSurface3_Unlock(surf,sdesc.u2.lpSurface);
#else #else
/* No need to do anything here... */ /* No need to do anything here... */
#endif #endif
......
...@@ -106,25 +106,25 @@ void _dump_executedata(LPD3DEXECUTEDATA lpData) { ...@@ -106,25 +106,25 @@ void _dump_executedata(LPD3DEXECUTEDATA lpData) {
#define DO_TLVERTEX(index) \ #define DO_TLVERTEX(index) \
{ \ { \
D3DTLVERTEX *vx = &(tl_vx[index]); \ D3DTLVERTEX *vx = &(tl_vx[index]); \
DWORD col = vx->c.color; \ DWORD col = vx->u5.color; \
\ \
glColor3f(((col >> 16) & 0xFF) / 255.0, \ glColor3f(((col >> 16) & 0xFF) / 255.0, \
((col >> 8) & 0xFF) / 255.0, \ ((col >> 8) & 0xFF) / 255.0, \
((col >> 0) & 0xFF) / 255.0); \ ((col >> 0) & 0xFF) / 255.0); \
glTexCoord2f(vx->u.tu, vx->v.tv); \ glTexCoord2f(vx->u7.tu, vx->u8.tv); \
if (vx->r.rhw < 0.01) \ if (vx->u4.rhw < 0.01) \
glVertex3f(vx->x.sx, \ glVertex3f(vx->u1.sx, \
vx->y.sy, \ vx->u2.sy, \
vx->z.sz); \ vx->u3.sz); \
else \ else \
glVertex4f(vx->x.sx / vx->r.rhw, \ glVertex4f(vx->u1.sx / vx->u4.rhw, \
vx->y.sy / vx->r.rhw, \ vx->u2.sy / vx->u4.rhw, \
vx->z.sz / vx->r.rhw, \ vx->u3.sz / vx->u4.rhw, \
1.0 / vx->r.rhw); \ 1.0 / vx->u4.rhw); \
TRACE(" TLV: %f %f %f (%02lx %02lx %02lx) (%f %f) (%f)\n", \ TRACE(" TLV: %f %f %f (%02lx %02lx %02lx) (%f %f) (%f)\n", \
vx->x.sx, vx->y.sy, vx->z.sz, \ vx->u1.sx, vx->u2.sy, vx->u3.sz, \
((col >> 16) & 0xFF), ((col >> 8) & 0xFF), ((col >> 0) & 0xFF), \ ((col >> 16) & 0xFF), ((col >> 8) & 0xFF), ((col >> 0) & 0xFF), \
vx->u.tu, vx->v.tv, vx->r.rhw); \ vx->u7.tu, vx->u8.tv, vx->u4.rhw); \
} }
#define TRIANGLE_LOOP(macro) \ #define TRIANGLE_LOOP(macro) \
...@@ -134,7 +134,7 @@ void _dump_executedata(LPD3DEXECUTEDATA lpData) { ...@@ -134,7 +134,7 @@ void _dump_executedata(LPD3DEXECUTEDATA lpData) {
LPD3DTRIANGLE ci = (LPD3DTRIANGLE) instr; \ LPD3DTRIANGLE ci = (LPD3DTRIANGLE) instr; \
\ \
TRACE(" v1: %d v2: %d v3: %d\n", \ TRACE(" v1: %d v2: %d v3: %d\n", \
ci->v1.v1, ci->v2.v2, ci->v3.v3); \ ci->u1.v1, ci->u2.v2, ci->u3.v3); \
TRACE(" Flags : "); \ TRACE(" Flags : "); \
if (TRACE_ON(ddraw)) { \ if (TRACE_ON(ddraw)) { \
/* Wireframe */ \ /* Wireframe */ \
...@@ -158,9 +158,9 @@ void _dump_executedata(LPD3DEXECUTEDATA lpData) { ...@@ -158,9 +158,9 @@ void _dump_executedata(LPD3DEXECUTEDATA lpData) {
} \ } \
\ \
/* Draw the triangle */ \ /* Draw the triangle */ \
macro(ci->v1.v1); \ macro(ci->u1.v1); \
macro(ci->v2.v2); \ macro(ci->u2.v2); \
macro(ci->v3.v3); \ macro(ci->u3.v3); \
\ \
instr += size; \ instr += size; \
} \ } \
...@@ -367,24 +367,24 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff, ...@@ -367,24 +367,24 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff,
LPD3DSTATE ci = (LPD3DSTATE) instr; LPD3DSTATE ci = (LPD3DSTATE) instr;
/* Handle the state transform */ /* Handle the state transform */
switch (ci->t.dtstTransformStateType) { switch (ci->u1.dtstTransformStateType) {
case D3DTRANSFORMSTATE_WORLD: { case D3DTRANSFORMSTATE_WORLD: {
TRACE(" WORLD (%p)\n", (D3DMATRIX*) ci->v.dwArg[0]); TRACE(" WORLD (%p)\n", (D3DMATRIX*) ci->u2.dwArg[0]);
odev->world_mat = (D3DMATRIX*) ci->v.dwArg[0]; odev->world_mat = (D3DMATRIX*) ci->u2.dwArg[0];
} break; } break;
case D3DTRANSFORMSTATE_VIEW: { case D3DTRANSFORMSTATE_VIEW: {
TRACE(" VIEW (%p)\n", (D3DMATRIX*) ci->v.dwArg[0]); TRACE(" VIEW (%p)\n", (D3DMATRIX*) ci->u2.dwArg[0]);
odev->view_mat = (D3DMATRIX*) ci->v.dwArg[0]; odev->view_mat = (D3DMATRIX*) ci->u2.dwArg[0];
} break; } break;
case D3DTRANSFORMSTATE_PROJECTION: { case D3DTRANSFORMSTATE_PROJECTION: {
TRACE(" PROJECTION (%p)\n", (D3DMATRIX*) ci->v.dwArg[0]); TRACE(" PROJECTION (%p)\n", (D3DMATRIX*) ci->u2.dwArg[0]);
odev->proj_mat = (D3DMATRIX*) ci->v.dwArg[0]; odev->proj_mat = (D3DMATRIX*) ci->u2.dwArg[0];
} break; } break;
default: default:
ERR(" Unhandled state transformation !! (%d)\n", (int) ci->t.dtstTransformStateType); ERR(" Unhandled state transformation !! (%d)\n", (int) ci->u1.dtstTransformStateType);
break; break;
} }
...@@ -401,9 +401,9 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff, ...@@ -401,9 +401,9 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff,
LPD3DSTATE ci = (LPD3DSTATE) instr; LPD3DSTATE ci = (LPD3DSTATE) instr;
/* Handle the state transform */ /* Handle the state transform */
switch (ci->t.dlstLightStateType) { switch (ci->u1.dlstLightStateType) {
case D3DLIGHTSTATE_MATERIAL: { case D3DLIGHTSTATE_MATERIAL: {
IDirect3DMaterial2Impl* mat = (IDirect3DMaterial2Impl*) ci->v.dwArg[0]; IDirect3DMaterial2Impl* mat = (IDirect3DMaterial2Impl*) ci->u2.dwArg[0];
TRACE(" MATERIAL\n"); TRACE(" MATERIAL\n");
if (mat != NULL) { if (mat != NULL) {
...@@ -415,7 +415,7 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff, ...@@ -415,7 +415,7 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff,
case D3DLIGHTSTATE_AMBIENT: { case D3DLIGHTSTATE_AMBIENT: {
float light[4]; float light[4];
DWORD dwLightState = ci->v.dwArg[0]; DWORD dwLightState = ci->u2.dwArg[0];
TRACE(" AMBIENT\n"); TRACE(" AMBIENT\n");
light[0] = ((dwLightState >> 16) & 0xFF) / 255.0; light[0] = ((dwLightState >> 16) & 0xFF) / 255.0;
...@@ -452,7 +452,7 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff, ...@@ -452,7 +452,7 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff,
} break ; } break ;
default: default:
ERR(" Unhandled light state !! (%d)\n", (int) ci->t.dlstLightStateType); ERR(" Unhandled light state !! (%d)\n", (int) ci->u1.dlstLightStateType);
break; break;
} }
instr += size; instr += size;
...@@ -467,7 +467,7 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff, ...@@ -467,7 +467,7 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff,
LPD3DSTATE ci = (LPD3DSTATE) instr; LPD3DSTATE ci = (LPD3DSTATE) instr;
/* Handle the state transform */ /* Handle the state transform */
set_render_state(ci->t.drstRenderStateType, ci->v.dwArg[0], &(odev->rs)); set_render_state(ci->u1.drstRenderStateType, ci->u2.dwArg[0], &(odev->rs));
instr += size; instr += size;
} }
...@@ -539,18 +539,18 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff, ...@@ -539,18 +539,18 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff,
for (nb = 0; nb < ci->dwCount; nb++) { for (nb = 0; nb < ci->dwCount; nb++) {
/* For the moment, no normal transformation... */ /* For the moment, no normal transformation... */
dst->nx = src->nx.nx; dst->nx = src->u4.nx;
dst->ny = src->ny.ny; dst->ny = src->u5.ny;
dst->nz = src->nz.nz; dst->nz = src->u6.nz;
dst->u = src->u.tu; dst->u = src->u7.tu;
dst->v = src->v.tv; dst->v = src->u8.tv;
/* Now, the matrix multiplication */ /* Now, the matrix multiplication */
dst->x = (src->x.x * mat->_11) + (src->y.y * mat->_21) + (src->z.z * mat->_31) + (1.0 * mat->_41); dst->x = (src->u1.x * mat->_11) + (src->u2.y * mat->_21) + (src->u3.z * mat->_31) + (1.0 * mat->_41);
dst->y = (src->x.x * mat->_12) + (src->y.y * mat->_22) + (src->z.z * mat->_32) + (1.0 * mat->_42); dst->y = (src->u1.x * mat->_12) + (src->u2.y * mat->_22) + (src->u3.z * mat->_32) + (1.0 * mat->_42);
dst->z = (src->x.x * mat->_13) + (src->y.y * mat->_23) + (src->z.z * mat->_33) + (1.0 * mat->_43); dst->z = (src->u1.x * mat->_13) + (src->u2.y * mat->_23) + (src->u3.z * mat->_33) + (1.0 * mat->_43);
dst->w = (src->x.x * mat->_14) + (src->y.y * mat->_24) + (src->z.z * mat->_34) + (1.0 * mat->_44); dst->w = (src->u1.x * mat->_14) + (src->u2.y * mat->_24) + (src->u3.z * mat->_34) + (1.0 * mat->_44);
src++; src++;
dst++; dst++;
...@@ -567,16 +567,16 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff, ...@@ -567,16 +567,16 @@ static void execute(LPDIRECT3DEXECUTEBUFFER lpBuff,
ilpBuff->vertex_type = D3DVT_LVERTEX; ilpBuff->vertex_type = D3DVT_LVERTEX;
for (nb = 0; nb < ci->dwCount; nb++) { for (nb = 0; nb < ci->dwCount; nb++) {
dst->c = src->c.color; dst->c = src->u4.color;
dst->sc = src->s.specular; dst->sc = src->u5.specular;
dst->u = src->u.tu; dst->u = src->u6.tu;
dst->v = src->v.tv; dst->v = src->u7.tv;
/* Now, the matrix multiplication */ /* Now, the matrix multiplication */
dst->x = (src->x.x * mat->_11) + (src->y.y * mat->_21) + (src->z.z * mat->_31) + (1.0 * mat->_41); dst->x = (src->u1.x * mat->_11) + (src->u2.y * mat->_21) + (src->u3.z * mat->_31) + (1.0 * mat->_41);
dst->y = (src->x.x * mat->_12) + (src->y.y * mat->_22) + (src->z.z * mat->_32) + (1.0 * mat->_42); dst->y = (src->u1.x * mat->_12) + (src->u2.y * mat->_22) + (src->u3.z * mat->_32) + (1.0 * mat->_42);
dst->z = (src->x.x * mat->_13) + (src->y.y * mat->_23) + (src->z.z * mat->_33) + (1.0 * mat->_43); dst->z = (src->u1.x * mat->_13) + (src->u2.y * mat->_23) + (src->u3.z * mat->_33) + (1.0 * mat->_43);
dst->w = (src->x.x * mat->_14) + (src->y.y * mat->_24) + (src->z.z * mat->_34) + (1.0 * mat->_44); dst->w = (src->u1.x * mat->_14) + (src->u2.y * mat->_24) + (src->u3.z * mat->_34) + (1.0 * mat->_44);
src++; src++;
dst++; dst++;
......
...@@ -33,25 +33,25 @@ static void activate(IDirect3DMaterial2Impl* This) { ...@@ -33,25 +33,25 @@ static void activate(IDirect3DMaterial2Impl* This) {
This->device.active_device1->set_context(This->device.active_device1); This->device.active_device1->set_context(This->device.active_device1);
/* Set the current Material */ /* Set the current Material */
_dump_colorvalue("Diffuse", This->mat.a.diffuse); _dump_colorvalue("Diffuse", This->mat.u.diffuse);
glMaterialfv(GL_FRONT, glMaterialfv(GL_FRONT,
GL_DIFFUSE, GL_DIFFUSE,
(float *) &(This->mat.a.diffuse)); (float *) &(This->mat.u.diffuse));
_dump_colorvalue("Ambient", This->mat.b.ambient); _dump_colorvalue("Ambient", This->mat.u1.ambient);
glMaterialfv(GL_FRONT, glMaterialfv(GL_FRONT,
GL_AMBIENT, GL_AMBIENT,
(float *) &(This->mat.b.ambient)); (float *) &(This->mat.u1.ambient));
_dump_colorvalue("Specular", This->mat.c.specular); _dump_colorvalue("Specular", This->mat.u2.specular);
glMaterialfv(GL_FRONT, glMaterialfv(GL_FRONT,
GL_SPECULAR, GL_SPECULAR,
(float *) &(This->mat.c.specular)); (float *) &(This->mat.u2.specular));
_dump_colorvalue("Emissive", This->mat.d.emissive); _dump_colorvalue("Emissive", This->mat.u3.emissive);
glMaterialfv(GL_FRONT, glMaterialfv(GL_FRONT,
GL_EMISSION, GL_EMISSION,
(float *) &(This->mat.d.emissive)); (float *) &(This->mat.u3.emissive));
TRACE("Size : %ld\n", This->mat.dwSize); TRACE("Size : %ld\n", This->mat.dwSize);
TRACE("Power : %f\n", This->mat.e.power); TRACE("Power : %f\n", This->mat.u4.power);
TRACE("Texture handle : %08lx\n", (DWORD)This->mat.hTexture); TRACE("Texture handle : %08lx\n", (DWORD)This->mat.hTexture);
LEAVE_GL(); LEAVE_GL();
......
...@@ -647,20 +647,20 @@ void DPLAYX_CopyConnStructA( LPDPLCONNECTION dest, LPDPLCONNECTION src ) ...@@ -647,20 +647,20 @@ void DPLAYX_CopyConnStructA( LPDPLCONNECTION dest, LPDPLCONNECTION src )
CopyMemory( dest->lpSessionDesc, src->lpSessionDesc, sizeof( DPSESSIONDESC2 ) ); CopyMemory( dest->lpSessionDesc, src->lpSessionDesc, sizeof( DPSESSIONDESC2 ) );
/* Session names may or may not exist */ /* Session names may or may not exist */
if( src->lpSessionDesc->sess.lpszSessionNameA ) if( src->lpSessionDesc->u1.lpszSessionNameA )
{ {
strcpy( (LPSTR)lpStartOfFreeSpace, src->lpSessionDesc->sess.lpszSessionNameA ); strcpy( (LPSTR)lpStartOfFreeSpace, src->lpSessionDesc->u1.lpszSessionNameA );
dest->lpSessionDesc->sess.lpszSessionNameA = (LPSTR)lpStartOfFreeSpace; dest->lpSessionDesc->u1.lpszSessionNameA = (LPSTR)lpStartOfFreeSpace;
lpStartOfFreeSpace += lpStartOfFreeSpace +=
strlen( (LPSTR)dest->lpSessionDesc->sess.lpszSessionNameA ) + 1; strlen( (LPSTR)dest->lpSessionDesc->u1.lpszSessionNameA ) + 1;
} }
if( src->lpSessionDesc->pass.lpszPasswordA ) if( src->lpSessionDesc->u2.lpszPasswordA )
{ {
strcpy( (LPSTR)lpStartOfFreeSpace, src->lpSessionDesc->pass.lpszPasswordA ); strcpy( (LPSTR)lpStartOfFreeSpace, src->lpSessionDesc->u2.lpszPasswordA );
dest->lpSessionDesc->pass.lpszPasswordA = (LPSTR)lpStartOfFreeSpace; dest->lpSessionDesc->u2.lpszPasswordA = (LPSTR)lpStartOfFreeSpace;
lpStartOfFreeSpace += lpStartOfFreeSpace +=
strlen( (LPSTR)dest->lpSessionDesc->pass.lpszPasswordA ) + 1; strlen( (LPSTR)dest->lpSessionDesc->u2.lpszPasswordA ) + 1;
} }
} }
...@@ -671,20 +671,20 @@ void DPLAYX_CopyConnStructA( LPDPLCONNECTION dest, LPDPLCONNECTION src ) ...@@ -671,20 +671,20 @@ void DPLAYX_CopyConnStructA( LPDPLCONNECTION dest, LPDPLCONNECTION src )
lpStartOfFreeSpace += sizeof( DPNAME ); lpStartOfFreeSpace += sizeof( DPNAME );
CopyMemory( dest->lpPlayerName, src->lpPlayerName, sizeof( DPNAME ) ); CopyMemory( dest->lpPlayerName, src->lpPlayerName, sizeof( DPNAME ) );
if( src->lpPlayerName->psn.lpszShortNameA ) if( src->lpPlayerName->u1.lpszShortNameA )
{ {
strcpy( (LPSTR)lpStartOfFreeSpace, src->lpPlayerName->psn.lpszShortNameA ); strcpy( (LPSTR)lpStartOfFreeSpace, src->lpPlayerName->u1.lpszShortNameA );
dest->lpPlayerName->psn.lpszShortNameA = (LPSTR)lpStartOfFreeSpace; dest->lpPlayerName->u1.lpszShortNameA = (LPSTR)lpStartOfFreeSpace;
lpStartOfFreeSpace += lpStartOfFreeSpace +=
strlen( (LPSTR)dest->lpPlayerName->psn.lpszShortNameA ) + 1; strlen( (LPSTR)dest->lpPlayerName->u1.lpszShortNameA ) + 1;
} }
if( src->lpPlayerName->pln.lpszLongNameA ) if( src->lpPlayerName->u2.lpszLongNameA )
{ {
strcpy( (LPSTR)lpStartOfFreeSpace, src->lpPlayerName->pln.lpszLongNameA ); strcpy( (LPSTR)lpStartOfFreeSpace, src->lpPlayerName->u2.lpszLongNameA );
dest->lpPlayerName->pln.lpszLongNameA = (LPSTR)lpStartOfFreeSpace; dest->lpPlayerName->u2.lpszLongNameA = (LPSTR)lpStartOfFreeSpace;
lpStartOfFreeSpace += lpStartOfFreeSpace +=
strlen( (LPSTR)dest->lpPlayerName->pln.lpszLongName ) + 1 ; strlen( (LPSTR)dest->lpPlayerName->u2.lpszLongName ) + 1 ;
} }
} }
...@@ -769,20 +769,20 @@ void DPLAYX_CopyConnStructW( LPDPLCONNECTION dest, LPDPLCONNECTION src ) ...@@ -769,20 +769,20 @@ void DPLAYX_CopyConnStructW( LPDPLCONNECTION dest, LPDPLCONNECTION src )
CopyMemory( dest->lpSessionDesc, src->lpSessionDesc, sizeof( DPSESSIONDESC2 ) ); CopyMemory( dest->lpSessionDesc, src->lpSessionDesc, sizeof( DPSESSIONDESC2 ) );
/* Session names may or may not exist */ /* Session names may or may not exist */
if( src->lpSessionDesc->sess.lpszSessionName ) if( src->lpSessionDesc->u1.lpszSessionName )
{ {
strcpyW( (LPWSTR)lpStartOfFreeSpace, dest->lpSessionDesc->sess.lpszSessionName ); strcpyW( (LPWSTR)lpStartOfFreeSpace, dest->lpSessionDesc->u1.lpszSessionName );
src->lpSessionDesc->sess.lpszSessionName = (LPWSTR)lpStartOfFreeSpace; src->lpSessionDesc->u1.lpszSessionName = (LPWSTR)lpStartOfFreeSpace;
lpStartOfFreeSpace += sizeof(WCHAR) * lpStartOfFreeSpace += sizeof(WCHAR) *
( strlenW( (LPWSTR)dest->lpSessionDesc->sess.lpszSessionName ) + 1 ); ( strlenW( (LPWSTR)dest->lpSessionDesc->u1.lpszSessionName ) + 1 );
} }
if( src->lpSessionDesc->pass.lpszPassword ) if( src->lpSessionDesc->u2.lpszPassword )
{ {
strcpyW( (LPWSTR)lpStartOfFreeSpace, src->lpSessionDesc->pass.lpszPassword ); strcpyW( (LPWSTR)lpStartOfFreeSpace, src->lpSessionDesc->u2.lpszPassword );
dest->lpSessionDesc->pass.lpszPassword = (LPWSTR)lpStartOfFreeSpace; dest->lpSessionDesc->u2.lpszPassword = (LPWSTR)lpStartOfFreeSpace;
lpStartOfFreeSpace += sizeof(WCHAR) * lpStartOfFreeSpace += sizeof(WCHAR) *
( strlenW( (LPWSTR)dest->lpSessionDesc->pass.lpszPassword ) + 1 ); ( strlenW( (LPWSTR)dest->lpSessionDesc->u2.lpszPassword ) + 1 );
} }
} }
...@@ -793,20 +793,20 @@ void DPLAYX_CopyConnStructW( LPDPLCONNECTION dest, LPDPLCONNECTION src ) ...@@ -793,20 +793,20 @@ void DPLAYX_CopyConnStructW( LPDPLCONNECTION dest, LPDPLCONNECTION src )
lpStartOfFreeSpace += sizeof( DPNAME ); lpStartOfFreeSpace += sizeof( DPNAME );
CopyMemory( dest->lpPlayerName, src->lpPlayerName, sizeof( DPNAME ) ); CopyMemory( dest->lpPlayerName, src->lpPlayerName, sizeof( DPNAME ) );
if( src->lpPlayerName->psn.lpszShortName ) if( src->lpPlayerName->u1.lpszShortName )
{ {
strcpyW( (LPWSTR)lpStartOfFreeSpace, src->lpPlayerName->psn.lpszShortName ); strcpyW( (LPWSTR)lpStartOfFreeSpace, src->lpPlayerName->u1.lpszShortName );
dest->lpPlayerName->psn.lpszShortName = (LPWSTR)lpStartOfFreeSpace; dest->lpPlayerName->u1.lpszShortName = (LPWSTR)lpStartOfFreeSpace;
lpStartOfFreeSpace += sizeof(WCHAR) * lpStartOfFreeSpace += sizeof(WCHAR) *
( strlenW( (LPWSTR)dest->lpPlayerName->psn.lpszShortName ) + 1 ); ( strlenW( (LPWSTR)dest->lpPlayerName->u1.lpszShortName ) + 1 );
} }
if( src->lpPlayerName->pln.lpszLongName ) if( src->lpPlayerName->u2.lpszLongName )
{ {
strcpyW( (LPWSTR)lpStartOfFreeSpace, src->lpPlayerName->pln.lpszLongName ); strcpyW( (LPWSTR)lpStartOfFreeSpace, src->lpPlayerName->u2.lpszLongName );
dest->lpPlayerName->pln.lpszLongName = (LPWSTR)lpStartOfFreeSpace; dest->lpPlayerName->u2.lpszLongName = (LPWSTR)lpStartOfFreeSpace;
lpStartOfFreeSpace += sizeof(WCHAR) * lpStartOfFreeSpace += sizeof(WCHAR) *
( strlenW( (LPWSTR)dest->lpPlayerName->pln.lpszLongName ) + 1 ); ( strlenW( (LPWSTR)dest->lpPlayerName->u2.lpszLongName ) + 1 );
} }
} }
...@@ -952,14 +952,14 @@ DWORD DPLAYX_SizeOfLobbyDataA( LPDPLCONNECTION lpConn ) ...@@ -952,14 +952,14 @@ DWORD DPLAYX_SizeOfLobbyDataA( LPDPLCONNECTION lpConn )
{ {
dwTotalSize += sizeof( DPSESSIONDESC2 ); dwTotalSize += sizeof( DPSESSIONDESC2 );
if( lpConn->lpSessionDesc->sess.lpszSessionNameA ) if( lpConn->lpSessionDesc->u1.lpszSessionNameA )
{ {
dwTotalSize += strlen( lpConn->lpSessionDesc->sess.lpszSessionNameA ) + 1; dwTotalSize += strlen( lpConn->lpSessionDesc->u1.lpszSessionNameA ) + 1;
} }
if( lpConn->lpSessionDesc->pass.lpszPasswordA ) if( lpConn->lpSessionDesc->u2.lpszPasswordA )
{ {
dwTotalSize += strlen( lpConn->lpSessionDesc->pass.lpszPasswordA ) + 1; dwTotalSize += strlen( lpConn->lpSessionDesc->u2.lpszPasswordA ) + 1;
} }
} }
...@@ -967,14 +967,14 @@ DWORD DPLAYX_SizeOfLobbyDataA( LPDPLCONNECTION lpConn ) ...@@ -967,14 +967,14 @@ DWORD DPLAYX_SizeOfLobbyDataA( LPDPLCONNECTION lpConn )
{ {
dwTotalSize += sizeof( DPNAME ); dwTotalSize += sizeof( DPNAME );
if( lpConn->lpPlayerName->psn.lpszShortNameA ) if( lpConn->lpPlayerName->u1.lpszShortNameA )
{ {
dwTotalSize += strlen( lpConn->lpPlayerName->psn.lpszShortNameA ) + 1; dwTotalSize += strlen( lpConn->lpPlayerName->u1.lpszShortNameA ) + 1;
} }
if( lpConn->lpPlayerName->pln.lpszLongNameA ) if( lpConn->lpPlayerName->u2.lpszLongNameA )
{ {
dwTotalSize += strlen( lpConn->lpPlayerName->pln.lpszLongNameA ) + 1; dwTotalSize += strlen( lpConn->lpPlayerName->u2.lpszLongNameA ) + 1;
} }
} }
...@@ -999,16 +999,16 @@ DWORD DPLAYX_SizeOfLobbyDataW( LPDPLCONNECTION lpConn ) ...@@ -999,16 +999,16 @@ DWORD DPLAYX_SizeOfLobbyDataW( LPDPLCONNECTION lpConn )
{ {
dwTotalSize += sizeof( DPSESSIONDESC2 ); dwTotalSize += sizeof( DPSESSIONDESC2 );
if( lpConn->lpSessionDesc->sess.lpszSessionName ) if( lpConn->lpSessionDesc->u1.lpszSessionName )
{ {
dwTotalSize += sizeof( WCHAR ) * dwTotalSize += sizeof( WCHAR ) *
( strlenW( lpConn->lpSessionDesc->sess.lpszSessionName ) + 1 ); ( strlenW( lpConn->lpSessionDesc->u1.lpszSessionName ) + 1 );
} }
if( lpConn->lpSessionDesc->pass.lpszPassword ) if( lpConn->lpSessionDesc->u2.lpszPassword )
{ {
dwTotalSize += sizeof( WCHAR ) * dwTotalSize += sizeof( WCHAR ) *
( strlenW( lpConn->lpSessionDesc->pass.lpszPassword ) + 1 ); ( strlenW( lpConn->lpSessionDesc->u2.lpszPassword ) + 1 );
} }
} }
...@@ -1016,16 +1016,16 @@ DWORD DPLAYX_SizeOfLobbyDataW( LPDPLCONNECTION lpConn ) ...@@ -1016,16 +1016,16 @@ DWORD DPLAYX_SizeOfLobbyDataW( LPDPLCONNECTION lpConn )
{ {
dwTotalSize += sizeof( DPNAME ); dwTotalSize += sizeof( DPNAME );
if( lpConn->lpPlayerName->psn.lpszShortName ) if( lpConn->lpPlayerName->u1.lpszShortName )
{ {
dwTotalSize += sizeof( WCHAR ) * dwTotalSize += sizeof( WCHAR ) *
( strlenW( lpConn->lpPlayerName->psn.lpszShortName ) + 1 ); ( strlenW( lpConn->lpPlayerName->u1.lpszShortName ) + 1 );
} }
if( lpConn->lpPlayerName->pln.lpszLongName ) if( lpConn->lpPlayerName->u2.lpszLongName )
{ {
dwTotalSize += sizeof( WCHAR ) * dwTotalSize += sizeof( WCHAR ) *
( strlenW( lpConn->lpPlayerName->pln.lpszLongName ) + 1 ); ( strlenW( lpConn->lpPlayerName->u2.lpszLongName ) + 1 );
} }
} }
...@@ -1053,17 +1053,17 @@ BOOL DPLAYX_CopyIntoSessionDesc2A( LPDPSESSIONDESC2 lpSessionDest, ...@@ -1053,17 +1053,17 @@ BOOL DPLAYX_CopyIntoSessionDesc2A( LPDPSESSIONDESC2 lpSessionDest,
{ {
CopyMemory( lpSessionDest, lpSessionSrc, sizeof( *lpSessionSrc ) ); CopyMemory( lpSessionDest, lpSessionSrc, sizeof( *lpSessionSrc ) );
if( lpSessionSrc->sess.lpszSessionNameA ) if( lpSessionSrc->u1.lpszSessionNameA )
{ {
if ((lpSessionDest->sess.lpszSessionNameA = HeapAlloc( GetProcessHeap(), 0, if ((lpSessionDest->u1.lpszSessionNameA = HeapAlloc( GetProcessHeap(), 0,
strlen(lpSessionSrc->sess.lpszSessionNameA)+1 ))) strlen(lpSessionSrc->u1.lpszSessionNameA)+1 )))
strcpy( lpSessionDest->sess.lpszSessionNameA, lpSessionSrc->sess.lpszSessionNameA ); strcpy( lpSessionDest->u1.lpszSessionNameA, lpSessionSrc->u1.lpszSessionNameA );
} }
if( lpSessionSrc->pass.lpszPasswordA ) if( lpSessionSrc->u2.lpszPasswordA )
{ {
if ((lpSessionDest->pass.lpszPasswordA = HeapAlloc( GetProcessHeap(), 0, if ((lpSessionDest->u2.lpszPasswordA = HeapAlloc( GetProcessHeap(), 0,
strlen(lpSessionSrc->pass.lpszPasswordA)+1 ))) strlen(lpSessionSrc->u2.lpszPasswordA)+1 )))
strcpy( lpSessionDest->pass.lpszPasswordA, lpSessionSrc->pass.lpszPasswordA ); strcpy( lpSessionDest->u2.lpszPasswordA, lpSessionSrc->u2.lpszPasswordA );
} }
return TRUE; return TRUE;
......
...@@ -932,7 +932,7 @@ static HRESULT WINAPI IDirectPlayLobbyAImpl_EnumLocalApplications ...@@ -932,7 +932,7 @@ static HRESULT WINAPI IDirectPlayLobbyAImpl_EnumLocalApplications
dplAppInfo.dwSize = sizeof( dplAppInfo ); dplAppInfo.dwSize = sizeof( dplAppInfo );
dplAppInfo.guidApplication = serviceProviderGUID; dplAppInfo.guidApplication = serviceProviderGUID;
dplAppInfo.appName.lpszAppNameA = subKeyName; dplAppInfo.u.lpszAppNameA = subKeyName;
EnterCriticalSection( &This->unk->DPL_lock ); EnterCriticalSection( &This->unk->DPL_lock );
......
...@@ -118,9 +118,9 @@ void NS_SetRemoteComputerAsNameServer( LPVOID lpNSAddrHdr, ...@@ -118,9 +118,9 @@ void NS_SetRemoteComputerAsNameServer( LPVOID lpNSAddrHdr,
CopyMemory( lpCacheNode->data, &lpMsg->sd, sizeof( *lpCacheNode->data ) ); CopyMemory( lpCacheNode->data, &lpMsg->sd, sizeof( *lpCacheNode->data ) );
len = WideCharToMultiByte( CP_ACP, 0, (LPWSTR)(lpMsg+1), -1, NULL, 0, NULL, NULL ); len = WideCharToMultiByte( CP_ACP, 0, (LPWSTR)(lpMsg+1), -1, NULL, 0, NULL, NULL );
if ((lpCacheNode->data->sess.lpszSessionNameA = HeapAlloc( GetProcessHeap(), 0, len ))) if ((lpCacheNode->data->u1.lpszSessionNameA = HeapAlloc( GetProcessHeap(), 0, len )))
WideCharToMultiByte( CP_ACP, 0, (LPWSTR)(lpMsg+1), -1, WideCharToMultiByte( CP_ACP, 0, (LPWSTR)(lpMsg+1), -1,
lpCacheNode->data->sess.lpszSessionNameA, len, NULL, NULL ); lpCacheNode->data->u1.lpszSessionNameA, len, NULL, NULL );
lpCacheNode->dwTime = timeGetTime(); lpCacheNode->dwTime = timeGetTime();
...@@ -341,10 +341,10 @@ void NS_ReplyToEnumSessionsRequest( LPVOID lpMsg, ...@@ -341,10 +341,10 @@ void NS_ReplyToEnumSessionsRequest( LPVOID lpMsg,
if (bAnsi) if (bAnsi)
dwVariableLen = MultiByteToWideChar( CP_ACP, 0, dwVariableLen = MultiByteToWideChar( CP_ACP, 0,
lpDP->dp2->lpSessionDesc->sess.lpszSessionNameA, lpDP->dp2->lpSessionDesc->u1.lpszSessionNameA,
-1, NULL, 0 ); -1, NULL, 0 );
else else
dwVariableLen = strlenW( lpDP->dp2->lpSessionDesc->sess.lpszSessionName ) + 1; dwVariableLen = strlenW( lpDP->dp2->lpSessionDesc->u1.lpszSessionName ) + 1;
dwVariableSize = dwVariableLen * sizeof( WCHAR ); dwVariableSize = dwVariableLen * sizeof( WCHAR );
...@@ -364,8 +364,8 @@ void NS_ReplyToEnumSessionsRequest( LPVOID lpMsg, ...@@ -364,8 +364,8 @@ void NS_ReplyToEnumSessionsRequest( LPVOID lpMsg,
sizeof( lpDP->dp2->lpSessionDesc->dwSize ) ); sizeof( lpDP->dp2->lpSessionDesc->dwSize ) );
rmsg->dwUnknown = 0x0000005c; rmsg->dwUnknown = 0x0000005c;
if( bAnsi ) if( bAnsi )
MultiByteToWideChar( CP_ACP, 0, lpDP->dp2->lpSessionDesc->sess.lpszSessionNameA, -1, MultiByteToWideChar( CP_ACP, 0, lpDP->dp2->lpSessionDesc->u1.lpszSessionNameA, -1,
(LPWSTR)(rmsg+1), dwVariableLen ); (LPWSTR)(rmsg+1), dwVariableLen );
else else
strcpyW( (LPWSTR)(rmsg+1), lpDP->dp2->lpSessionDesc->sess.lpszSessionName ); strcpyW( (LPWSTR)(rmsg+1), lpDP->dp2->lpSessionDesc->u1.lpszSessionName );
} }
...@@ -156,15 +156,15 @@ typedef struct _D3DHVERTEX { ...@@ -156,15 +156,15 @@ typedef struct _D3DHVERTEX {
union { union {
D3DVALUE hx; D3DVALUE hx;
D3DVALUE dvHX; D3DVALUE dvHX;
} x; } DUMMYUNIONNAME1;
union { union {
D3DVALUE hy; D3DVALUE hy;
D3DVALUE dvHY; D3DVALUE dvHY;
} y; } DUMMYUNIONNAME2;
union { union {
D3DVALUE hz; D3DVALUE hz;
D3DVALUE dvHZ; D3DVALUE dvHZ;
} z; } DUMMYUNIONNAME3;
} D3DHVERTEX, *LPD3DHVERTEX; } D3DHVERTEX, *LPD3DHVERTEX;
/* /*
...@@ -174,35 +174,35 @@ typedef struct { ...@@ -174,35 +174,35 @@ typedef struct {
union { union {
D3DVALUE sx; D3DVALUE sx;
D3DVALUE dvSX; D3DVALUE dvSX;
} x; } DUMMYUNIONNAME1;
union { union {
D3DVALUE sy; D3DVALUE sy;
D3DVALUE dvSY; D3DVALUE dvSY;
} y; } DUMMYUNIONNAME2;
union { union {
D3DVALUE sz; D3DVALUE sz;
D3DVALUE dvSZ; D3DVALUE dvSZ;
} z; } DUMMYUNIONNAME3;
union { union {
D3DVALUE rhw; D3DVALUE rhw;
D3DVALUE dvRHW; D3DVALUE dvRHW;
} r; } DUMMYUNIONNAME4;
union { union {
D3DCOLOR color; D3DCOLOR color;
D3DCOLOR dcColor; D3DCOLOR dcColor;
} c; } DUMMYUNIONNAME5;
union { union {
D3DCOLOR specular; D3DCOLOR specular;
D3DCOLOR dcSpecular; D3DCOLOR dcSpecular;
} s; } DUMMYUNIONNAME6;
union { union {
D3DVALUE tu; D3DVALUE tu;
D3DVALUE dvTU; D3DVALUE dvTU;
} u; } DUMMYUNIONNAME7;
union { union {
D3DVALUE tv; D3DVALUE tv;
D3DVALUE dvTV; D3DVALUE dvTV;
} v; } DUMMYUNIONNAME8;
/* There are C++ members associated with this class */ /* There are C++ members associated with this class */
} D3DTLVERTEX, *LPD3DTLVERTEX; } D3DTLVERTEX, *LPD3DTLVERTEX;
...@@ -210,67 +210,67 @@ typedef struct _D3DLVERTEX { ...@@ -210,67 +210,67 @@ typedef struct _D3DLVERTEX {
union { union {
D3DVALUE x; D3DVALUE x;
D3DVALUE dvX; D3DVALUE dvX;
} x; } DUMMYUNIONNAME1;
union { union {
D3DVALUE y; D3DVALUE y;
D3DVALUE dvY; D3DVALUE dvY;
} y; } DUMMYUNIONNAME2;
union { union {
D3DVALUE z; D3DVALUE z;
D3DVALUE dvZ; D3DVALUE dvZ;
} z; } DUMMYUNIONNAME3;
DWORD dwReserved; DWORD dwReserved;
union { union {
D3DCOLOR color; D3DCOLOR color;
D3DCOLOR dcColor; D3DCOLOR dcColor;
} c; } DUMMYUNIONNAME4;
union { union {
D3DCOLOR specular; D3DCOLOR specular;
D3DCOLOR dcSpecular; D3DCOLOR dcSpecular;
} s; } DUMMYUNIONNAME5;
union { union {
D3DVALUE tu; D3DVALUE tu;
D3DVALUE dvTU; D3DVALUE dvTU;
} u; } DUMMYUNIONNAME6;
union { union {
D3DVALUE tv; D3DVALUE tv;
D3DVALUE dvTV; D3DVALUE dvTV;
} v; } DUMMYUNIONNAME7;
} D3DLVERTEX, *LPD3DLVERTEX; } D3DLVERTEX, *LPD3DLVERTEX;
typedef struct _D3DVERTEX { typedef struct _D3DVERTEX {
union { union {
D3DVALUE x; D3DVALUE x;
D3DVALUE dvX; D3DVALUE dvX;
} x; } DUMMYUNIONNAME1;
union { union {
D3DVALUE y; D3DVALUE y;
D3DVALUE dvY; D3DVALUE dvY;
} y; } DUMMYUNIONNAME2;
union { union {
D3DVALUE z; D3DVALUE z;
D3DVALUE dvZ; D3DVALUE dvZ;
} z; } DUMMYUNIONNAME3;
union { union {
D3DVALUE nx; D3DVALUE nx;
D3DVALUE dvNX; D3DVALUE dvNX;
} nx; } DUMMYUNIONNAME4;
union { union {
D3DVALUE ny; D3DVALUE ny;
D3DVALUE dvNY; D3DVALUE dvNY;
} ny; } DUMMYUNIONNAME5;
union { union {
D3DVALUE nz; D3DVALUE nz;
D3DVALUE dvNZ; D3DVALUE dvNZ;
} nz; } DUMMYUNIONNAME6;
union { union {
D3DVALUE tu; D3DVALUE tu;
D3DVALUE dvTU; D3DVALUE dvTU;
} u; } DUMMYUNIONNAME7;
union { union {
D3DVALUE tv; D3DVALUE tv;
D3DVALUE dvTV; D3DVALUE dvTV;
} v; } DUMMYUNIONNAME8;
/* FIXME: Some C++ stuff to go here */ /* FIXME: Some C++ stuff to go here */
} D3DVERTEX, *LPD3DVERTEX; } D3DVERTEX, *LPD3DVERTEX;
...@@ -432,23 +432,23 @@ typedef struct _D3DMATERIAL { ...@@ -432,23 +432,23 @@ typedef struct _D3DMATERIAL {
union { union {
D3DCOLORVALUE diffuse; D3DCOLORVALUE diffuse;
D3DCOLORVALUE dcvDiffuse; D3DCOLORVALUE dcvDiffuse;
} a; } DUMMYUNIONNAME;
union { union {
D3DCOLORVALUE ambient; D3DCOLORVALUE ambient;
D3DCOLORVALUE dcvAmbient; D3DCOLORVALUE dcvAmbient;
} b; } DUMMYUNIONNAME1;
union { union {
D3DCOLORVALUE specular; D3DCOLORVALUE specular;
D3DCOLORVALUE dcvSpecular; D3DCOLORVALUE dcvSpecular;
} c; } DUMMYUNIONNAME2;
union { union {
D3DCOLORVALUE emissive; D3DCOLORVALUE emissive;
D3DCOLORVALUE dcvEmissive; D3DCOLORVALUE dcvEmissive;
} d; } DUMMYUNIONNAME3;
union { union {
D3DVALUE power; D3DVALUE power;
D3DVALUE dvPower; D3DVALUE dvPower;
} e; } DUMMYUNIONNAME4;
D3DTEXTUREHANDLE hTexture; D3DTEXTUREHANDLE hTexture;
DWORD dwRampSize; DWORD dwRampSize;
} D3DMATERIAL, *LPD3DMATERIAL; } D3DMATERIAL, *LPD3DMATERIAL;
...@@ -911,11 +911,11 @@ typedef struct _D3DSTATE { ...@@ -911,11 +911,11 @@ typedef struct _D3DSTATE {
D3DTRANSFORMSTATETYPE dtstTransformStateType; D3DTRANSFORMSTATETYPE dtstTransformStateType;
D3DLIGHTSTATETYPE dlstLightStateType; D3DLIGHTSTATETYPE dlstLightStateType;
D3DRENDERSTATETYPE drstRenderStateType; D3DRENDERSTATETYPE drstRenderStateType;
} t; } DUMMYUNIONNAME1;
union { union {
DWORD dwArg[1]; DWORD dwArg[1];
D3DVALUE dvArg[1]; D3DVALUE dvArg[1];
} v; } DUMMYUNIONNAME2;
} D3DSTATE, *LPD3DSTATE; } D3DSTATE, *LPD3DSTATE;
typedef struct _D3DMATRIXLOAD { typedef struct _D3DMATRIXLOAD {
...@@ -1064,15 +1064,15 @@ typedef struct _D3DTRIANGLE { ...@@ -1064,15 +1064,15 @@ typedef struct _D3DTRIANGLE {
union { union {
WORD v1; WORD v1;
WORD wV1; WORD wV1;
} v1; } DUMMYUNIONNAME1;
union { union {
WORD v2; WORD v2;
WORD wV2; WORD wV2;
} v2; } DUMMYUNIONNAME2;
union { union {
WORD v3; WORD v3;
WORD wV3; WORD wV3;
} v3; } DUMMYUNIONNAME3;
WORD wFlags; WORD wFlags;
} D3DTRIANGLE, *LPD3DTRIANGLE; } D3DTRIANGLE, *LPD3DTRIANGLE;
...@@ -1080,11 +1080,11 @@ typedef struct _D3DLINE { ...@@ -1080,11 +1080,11 @@ typedef struct _D3DLINE {
union { union {
WORD v1; WORD v1;
WORD wV1; WORD wV1;
} v1; } DUMMYUNIONNAME1;
union { union {
WORD v2; WORD v2;
WORD wV2; WORD wV2;
} v2; } DUMMYUNIONNAME2;
} D3DLINE, *LPD3DLINE; } D3DLINE, *LPD3DLINE;
typedef struct _D3DSPAN { typedef struct _D3DSPAN {
......
#ifndef __WINE_DPLAY_H #ifndef __WINE_DPLAY_H
#define __WINE_DPLAY_H #define __WINE_DPLAY_H
/* FIXME: GCC doesn't yet support annon structures so some of the structures
* defined here don't match the sdk exactly. I've tried to come up with
* suitably terse names, but this file won't cut it for inclusion into a
* Winelib app.
*/
#include "wine/obj_base.h" #include "wine/obj_base.h"
#ifdef __cplusplus #ifdef __cplusplus
...@@ -182,13 +176,13 @@ typedef struct tagDPNAME ...@@ -182,13 +176,13 @@ typedef struct tagDPNAME
{ {
LPWSTR lpszShortName; LPWSTR lpszShortName;
LPSTR lpszShortNameA; LPSTR lpszShortNameA;
}psn; } DUMMYUNIONNAME1;
union /*playerLongName */ /* Player's formal/real name */ union /*playerLongName */ /* Player's formal/real name */
{ {
LPWSTR lpszLongName; LPWSTR lpszLongName;
LPSTR lpszLongNameA; LPSTR lpszLongNameA;
}pln; } DUMMYUNIONNAME2;
} DPNAME, *LPDPNAME; } DPNAME, *LPDPNAME;
...@@ -232,13 +226,13 @@ typedef struct tagDPSESSIONDESC2 ...@@ -232,13 +226,13 @@ typedef struct tagDPSESSIONDESC2
{ {
LPWSTR lpszSessionName; LPWSTR lpszSessionName;
LPSTR lpszSessionNameA; LPSTR lpszSessionNameA;
}sess; } DUMMYUNIONNAME1;
union /* Optional password */ union /* Optional password */
{ {
LPWSTR lpszPassword; LPWSTR lpszPassword;
LPSTR lpszPasswordA; LPSTR lpszPasswordA;
}pass; } DUMMYUNIONNAME2;
DWORD dwReserved1; DWORD dwReserved1;
DWORD dwReserved2; DWORD dwReserved2;
...@@ -289,7 +283,7 @@ typedef struct tagDPCHAT ...@@ -289,7 +283,7 @@ typedef struct tagDPCHAT
{ /* Message string */ { /* Message string */
LPWSTR lpszMessage; /* Unicode */ LPWSTR lpszMessage; /* Unicode */
LPSTR lpszMessageA; /* ANSI */ LPSTR lpszMessageA; /* ANSI */
}msgstr; } DUMMYUNIONNAME;
} DPCHAT, *LPDPCHAT; } DPCHAT, *LPDPCHAT;
typedef struct typedef struct
...@@ -307,12 +301,12 @@ typedef struct tagDPSECURITYDESC ...@@ -307,12 +301,12 @@ typedef struct tagDPSECURITYDESC
{ /* SSPI provider name */ { /* SSPI provider name */
LPWSTR lpszSSPIProvider; /* Unicode */ LPWSTR lpszSSPIProvider; /* Unicode */
LPSTR lpszSSPIProviderA; /* ANSI */ LPSTR lpszSSPIProviderA; /* ANSI */
}sspi; } DUMMYUNIONNAME1;
union union
{ /* CAPI provider name */ { /* CAPI provider name */
LPWSTR lpszCAPIProvider; /* Unicode */ LPWSTR lpszCAPIProvider; /* Unicode */
LPSTR lpszCAPIProviderA; /* ANSI */ LPSTR lpszCAPIProviderA; /* ANSI */
}capi; } DUMMYUNIONNAME2;
DWORD dwCAPIProviderType; /* Crypto Service Provider type */ DWORD dwCAPIProviderType; /* Crypto Service Provider type */
DWORD dwEncryptionAlgorithm; /* Encryption Algorithm type */ DWORD dwEncryptionAlgorithm; /* Encryption Algorithm type */
} DPSECURITYDESC, *LPDPSECURITYDESC; } DPSECURITYDESC, *LPDPSECURITYDESC;
...@@ -327,17 +321,17 @@ typedef struct tagDPCREDENTIALS ...@@ -327,17 +321,17 @@ typedef struct tagDPCREDENTIALS
{ /* User name of the account */ { /* User name of the account */
LPWSTR lpszUsername; /* Unicode */ LPWSTR lpszUsername; /* Unicode */
LPSTR lpszUsernameA; /* ANSI */ LPSTR lpszUsernameA; /* ANSI */
}name; } DUMMYUNIONNAME1;
union union
{ /* Password of the account */ { /* Password of the account */
LPWSTR lpszPassword; /* Unicode */ LPWSTR lpszPassword; /* Unicode */
LPSTR lpszPasswordA; /* ANSI */ LPSTR lpszPasswordA; /* ANSI */
}pass; } DUMMYUNIONNAME2;
union union
{ /* Domain name of the account */ { /* Domain name of the account */
LPWSTR lpszDomain; /* Unicode */ LPWSTR lpszDomain; /* Unicode */
LPSTR lpszDomainA; /* ANSI */ LPSTR lpszDomainA; /* ANSI */
}domain; } DUMMYUNIONNAME3;
} DPCREDENTIALS, *LPDPCREDENTIALS; } DPCREDENTIALS, *LPDPCREDENTIALS;
typedef const DPCREDENTIALS *LPCDPCREDENTIALS; typedef const DPCREDENTIALS *LPCDPCREDENTIALS;
......
#ifndef __WINE_DPLOBBY_H #ifndef __WINE_DPLOBBY_H
#define __WINE_DPLOBBY_H #define __WINE_DPLOBBY_H
/* FIXME: GCC doesn't yet support annon structures so some of the structures
* defined here don't match the sdk exactly. I've tried to come up with
* suitably terse names, but this file won't cut it for inclusion into a
* Winelib app.
*/
#include "dplay.h" #include "dplay.h"
#ifdef __cplusplus #ifdef __cplusplus
...@@ -276,7 +270,7 @@ typedef struct tagDPLAPPINFO ...@@ -276,7 +270,7 @@ typedef struct tagDPLAPPINFO
{ {
LPSTR lpszAppNameA; LPSTR lpszAppNameA;
LPWSTR lpszAppName; LPWSTR lpszAppName;
} appName; } DUMMYUNIONNAME;
} DPLAPPINFO, *LPDPLAPPINFO; } DPLAPPINFO, *LPDPLAPPINFO;
typedef const DPLAPPINFO *LPCDPLAPPINFO; typedef const DPLAPPINFO *LPCDPLAPPINFO;
...@@ -298,7 +292,7 @@ typedef struct tagDPAPPLICATIONDESC ...@@ -298,7 +292,7 @@ typedef struct tagDPAPPLICATIONDESC
{ {
LPSTR lpszApplicationNameA; LPSTR lpszApplicationNameA;
LPWSTR lpszApplicationName; LPWSTR lpszApplicationName;
} appName; } DUMMYUNIONNAME1;
GUID guidApplication; GUID guidApplication;
...@@ -306,25 +300,25 @@ typedef struct tagDPAPPLICATIONDESC ...@@ -306,25 +300,25 @@ typedef struct tagDPAPPLICATIONDESC
{ {
LPSTR lpszFilenameA; LPSTR lpszFilenameA;
LPWSTR lpszFilename; LPWSTR lpszFilename;
} fileName; } DUMMYUNIONNAME2;
union union
{ {
LPSTR lpszCommandLineA; LPSTR lpszCommandLineA;
LPWSTR lpszCommandLine; LPWSTR lpszCommandLine;
} cmdLine; } DUMMYUNIONNAME3;
union union
{ {
LPSTR lpszPathA; LPSTR lpszPathA;
LPWSTR lpszPath; LPWSTR lpszPath;
} path; } DUMMYUNIONNAME4;
union union
{ {
LPSTR lpszCurrentDirectoryA; LPSTR lpszCurrentDirectoryA;
LPWSTR lpszCurrentDirectory; LPWSTR lpszCurrentDirectory;
} curDir; } DUMMYUNIONNAME5;
LPSTR lpszDescriptionA; LPSTR lpszDescriptionA;
LPWSTR lpszDescriptionW; LPWSTR lpszDescriptionW;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment