Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
a07195bb
Commit
a07195bb
authored
Aug 31, 2009
by
Francois Gouget
Committed by
Alexandre Julliard
Aug 31, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ddrawex: Fix compilation on systems that don't support nameless unions.
parent
74b5da9a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
15 deletions
+18
-15
ddraw.c
dlls/ddrawex/ddraw.c
+18
-15
No files found.
dlls/ddrawex/ddraw.c
View file @
a07195bb
...
@@ -15,10 +15,12 @@
...
@@ -15,10 +15,12 @@
* License along with this library; if not, write to the Free Software
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#include "wine/debug.h"
#define COBJMACROS
#define COBJMACROS
#define NONAMELESSUNION
#include <stdarg.h>
#include "windef.h"
#include "winbase.h"
#include "winbase.h"
#include "wingdi.h"
#include "wingdi.h"
...
@@ -26,6 +28,7 @@
...
@@ -26,6 +28,7 @@
#include "d3d.h"
#include "d3d.h"
#include "ddrawex_private.h"
#include "ddrawex_private.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
ddrawex
);
WINE_DEFAULT_DEBUG_CHANNEL
(
ddrawex
);
...
@@ -426,21 +429,21 @@ void DDSD_to_DDSD2(const DDSURFACEDESC *in, DDSURFACEDESC2 *out)
...
@@ -426,21 +429,21 @@ void DDSD_to_DDSD2(const DDSURFACEDESC *in, DDSURFACEDESC2 *out)
out
->
dwFlags
=
in
->
dwFlags
;
out
->
dwFlags
=
in
->
dwFlags
;
if
(
in
->
dwFlags
&
DDSD_WIDTH
)
out
->
dwWidth
=
in
->
dwWidth
;
if
(
in
->
dwFlags
&
DDSD_WIDTH
)
out
->
dwWidth
=
in
->
dwWidth
;
if
(
in
->
dwFlags
&
DDSD_HEIGHT
)
out
->
dwHeight
=
in
->
dwHeight
;
if
(
in
->
dwFlags
&
DDSD_HEIGHT
)
out
->
dwHeight
=
in
->
dwHeight
;
if
(
in
->
dwFlags
&
DDSD_PIXELFORMAT
)
out
->
ddpfPixelFormat
=
in
->
ddpfPixelFormat
;
if
(
in
->
dwFlags
&
DDSD_PIXELFORMAT
)
out
->
u4
.
ddpfPixelFormat
=
in
->
ddpfPixelFormat
;
if
(
in
->
dwFlags
&
DDSD_CAPS
)
out
->
ddsCaps
.
dwCaps
=
in
->
ddsCaps
.
dwCaps
;
if
(
in
->
dwFlags
&
DDSD_CAPS
)
out
->
ddsCaps
.
dwCaps
=
in
->
ddsCaps
.
dwCaps
;
if
(
in
->
dwFlags
&
DDSD_PITCH
)
out
->
lPitch
=
in
->
lPitch
;
if
(
in
->
dwFlags
&
DDSD_PITCH
)
out
->
u1
.
lPitch
=
in
->
u1
.
lPitch
;
if
(
in
->
dwFlags
&
DDSD_BACKBUFFERCOUNT
)
out
->
dwBackBufferCount
=
in
->
dwBackBufferCount
;
if
(
in
->
dwFlags
&
DDSD_BACKBUFFERCOUNT
)
out
->
dwBackBufferCount
=
in
->
dwBackBufferCount
;
if
(
in
->
dwFlags
&
DDSD_ZBUFFERBITDEPTH
)
out
->
dwMipMapCount
=
in
->
dwZBufferBitDepth
;
/* same union */
if
(
in
->
dwFlags
&
DDSD_ZBUFFERBITDEPTH
)
out
->
u2
.
dwMipMapCount
=
in
->
u2
.
dwZBufferBitDepth
;
/* same union */
if
(
in
->
dwFlags
&
DDSD_ALPHABITDEPTH
)
out
->
dwAlphaBitDepth
=
in
->
dwAlphaBitDepth
;
if
(
in
->
dwFlags
&
DDSD_ALPHABITDEPTH
)
out
->
dwAlphaBitDepth
=
in
->
dwAlphaBitDepth
;
/* DDraw(native, and wine) does not set the DDSD_LPSURFACE, so always copy */
/* DDraw(native, and wine) does not set the DDSD_LPSURFACE, so always copy */
out
->
lpSurface
=
in
->
lpSurface
;
out
->
lpSurface
=
in
->
lpSurface
;
if
(
in
->
dwFlags
&
DDSD_CKDESTOVERLAY
)
out
->
ddckCKDestOverlay
=
in
->
ddckCKDestOverlay
;
if
(
in
->
dwFlags
&
DDSD_CKDESTOVERLAY
)
out
->
u3
.
ddckCKDestOverlay
=
in
->
ddckCKDestOverlay
;
if
(
in
->
dwFlags
&
DDSD_CKDESTBLT
)
out
->
ddckCKDestBlt
=
in
->
ddckCKDestBlt
;
if
(
in
->
dwFlags
&
DDSD_CKDESTBLT
)
out
->
ddckCKDestBlt
=
in
->
ddckCKDestBlt
;
if
(
in
->
dwFlags
&
DDSD_CKSRCOVERLAY
)
out
->
ddckCKSrcOverlay
=
in
->
ddckCKSrcOverlay
;
if
(
in
->
dwFlags
&
DDSD_CKSRCOVERLAY
)
out
->
ddckCKSrcOverlay
=
in
->
ddckCKSrcOverlay
;
if
(
in
->
dwFlags
&
DDSD_CKSRCBLT
)
out
->
ddckCKSrcBlt
=
in
->
ddckCKSrcBlt
;
if
(
in
->
dwFlags
&
DDSD_CKSRCBLT
)
out
->
ddckCKSrcBlt
=
in
->
ddckCKSrcBlt
;
if
(
in
->
dwFlags
&
DDSD_MIPMAPCOUNT
)
out
->
dwMipMapCount
=
in
->
dwMipMapCount
;
if
(
in
->
dwFlags
&
DDSD_MIPMAPCOUNT
)
out
->
u2
.
dwMipMapCount
=
in
->
u2
.
dwMipMapCount
;
if
(
in
->
dwFlags
&
DDSD_REFRESHRATE
)
out
->
dwRefreshRate
=
in
->
dwRefreshRate
;
if
(
in
->
dwFlags
&
DDSD_REFRESHRATE
)
out
->
u2
.
dwRefreshRate
=
in
->
u2
.
dwRefreshRate
;
if
(
in
->
dwFlags
&
DDSD_LINEARSIZE
)
out
->
dwLinearSize
=
in
->
dwLinearSize
;
if
(
in
->
dwFlags
&
DDSD_LINEARSIZE
)
out
->
u1
.
dwLinearSize
=
in
->
u1
.
dwLinearSize
;
/* Does not exist in DDSURFACEDESC:
/* Does not exist in DDSURFACEDESC:
* DDSD_TEXTURESTAGE, DDSD_FVF, DDSD_SRCVBHANDLE,
* DDSD_TEXTURESTAGE, DDSD_FVF, DDSD_SRCVBHANDLE,
*/
*/
...
@@ -453,21 +456,21 @@ void DDSD2_to_DDSD(const DDSURFACEDESC2 *in, DDSURFACEDESC *out)
...
@@ -453,21 +456,21 @@ void DDSD2_to_DDSD(const DDSURFACEDESC2 *in, DDSURFACEDESC *out)
out
->
dwFlags
=
in
->
dwFlags
;
out
->
dwFlags
=
in
->
dwFlags
;
if
(
in
->
dwFlags
&
DDSD_WIDTH
)
out
->
dwWidth
=
in
->
dwWidth
;
if
(
in
->
dwFlags
&
DDSD_WIDTH
)
out
->
dwWidth
=
in
->
dwWidth
;
if
(
in
->
dwFlags
&
DDSD_HEIGHT
)
out
->
dwHeight
=
in
->
dwHeight
;
if
(
in
->
dwFlags
&
DDSD_HEIGHT
)
out
->
dwHeight
=
in
->
dwHeight
;
if
(
in
->
dwFlags
&
DDSD_PIXELFORMAT
)
out
->
ddpfPixelFormat
=
in
->
ddpfPixelFormat
;
if
(
in
->
dwFlags
&
DDSD_PIXELFORMAT
)
out
->
ddpfPixelFormat
=
in
->
u4
.
ddpfPixelFormat
;
if
(
in
->
dwFlags
&
DDSD_CAPS
)
out
->
ddsCaps
.
dwCaps
=
in
->
ddsCaps
.
dwCaps
;
if
(
in
->
dwFlags
&
DDSD_CAPS
)
out
->
ddsCaps
.
dwCaps
=
in
->
ddsCaps
.
dwCaps
;
if
(
in
->
dwFlags
&
DDSD_PITCH
)
out
->
lPitch
=
in
->
lPitch
;
if
(
in
->
dwFlags
&
DDSD_PITCH
)
out
->
u1
.
lPitch
=
in
->
u1
.
lPitch
;
if
(
in
->
dwFlags
&
DDSD_BACKBUFFERCOUNT
)
out
->
dwBackBufferCount
=
in
->
dwBackBufferCount
;
if
(
in
->
dwFlags
&
DDSD_BACKBUFFERCOUNT
)
out
->
dwBackBufferCount
=
in
->
dwBackBufferCount
;
if
(
in
->
dwFlags
&
DDSD_ZBUFFERBITDEPTH
)
out
->
dwZBufferBitDepth
=
in
->
dwMipMapCount
;
/* same union */
if
(
in
->
dwFlags
&
DDSD_ZBUFFERBITDEPTH
)
out
->
u2
.
dwZBufferBitDepth
=
in
->
u2
.
dwMipMapCount
;
/* same union */
if
(
in
->
dwFlags
&
DDSD_ALPHABITDEPTH
)
out
->
dwAlphaBitDepth
=
in
->
dwAlphaBitDepth
;
if
(
in
->
dwFlags
&
DDSD_ALPHABITDEPTH
)
out
->
dwAlphaBitDepth
=
in
->
dwAlphaBitDepth
;
/* DDraw(native, and wine) does not set the DDSD_LPSURFACE, so always copy */
/* DDraw(native, and wine) does not set the DDSD_LPSURFACE, so always copy */
out
->
lpSurface
=
in
->
lpSurface
;
out
->
lpSurface
=
in
->
lpSurface
;
if
(
in
->
dwFlags
&
DDSD_CKDESTOVERLAY
)
out
->
ddckCKDestOverlay
=
in
->
ddckCKDestOverlay
;
if
(
in
->
dwFlags
&
DDSD_CKDESTOVERLAY
)
out
->
ddckCKDestOverlay
=
in
->
u3
.
ddckCKDestOverlay
;
if
(
in
->
dwFlags
&
DDSD_CKDESTBLT
)
out
->
ddckCKDestBlt
=
in
->
ddckCKDestBlt
;
if
(
in
->
dwFlags
&
DDSD_CKDESTBLT
)
out
->
ddckCKDestBlt
=
in
->
ddckCKDestBlt
;
if
(
in
->
dwFlags
&
DDSD_CKSRCOVERLAY
)
out
->
ddckCKSrcOverlay
=
in
->
ddckCKSrcOverlay
;
if
(
in
->
dwFlags
&
DDSD_CKSRCOVERLAY
)
out
->
ddckCKSrcOverlay
=
in
->
ddckCKSrcOverlay
;
if
(
in
->
dwFlags
&
DDSD_CKSRCBLT
)
out
->
ddckCKSrcBlt
=
in
->
ddckCKSrcBlt
;
if
(
in
->
dwFlags
&
DDSD_CKSRCBLT
)
out
->
ddckCKSrcBlt
=
in
->
ddckCKSrcBlt
;
if
(
in
->
dwFlags
&
DDSD_MIPMAPCOUNT
)
out
->
dwMipMapCount
=
in
->
dwMipMapCount
;
if
(
in
->
dwFlags
&
DDSD_MIPMAPCOUNT
)
out
->
u2
.
dwMipMapCount
=
in
->
u2
.
dwMipMapCount
;
if
(
in
->
dwFlags
&
DDSD_REFRESHRATE
)
out
->
dwRefreshRate
=
in
->
dwRefreshRate
;
if
(
in
->
dwFlags
&
DDSD_REFRESHRATE
)
out
->
u2
.
dwRefreshRate
=
in
->
u2
.
dwRefreshRate
;
if
(
in
->
dwFlags
&
DDSD_LINEARSIZE
)
out
->
dwLinearSize
=
in
->
dwLinearSize
;
if
(
in
->
dwFlags
&
DDSD_LINEARSIZE
)
out
->
u1
.
dwLinearSize
=
in
->
u1
.
dwLinearSize
;
/* Does not exist in DDSURFACEDESC:
/* Does not exist in DDSURFACEDESC:
* DDSD_TEXTURESTAGE, DDSD_FVF, DDSD_SRCVBHANDLE,
* DDSD_TEXTURESTAGE, DDSD_FVF, DDSD_SRCVBHANDLE,
*/
*/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment