The patches look good to me.
Am Sonntag, 29. April 2012, 21:43:08 schrieb Józef Kucia:
This patch series implements the DDS support for D3DXGetImageInfo functions.
Try 2: Define pitch as LONG. Try 3: Revert it back to DWORD.
dlls/d3dx9_36/surface.c | 66 ++++++++++++++++++++++++++++++++++++++++++++++- 1 files changed, 65 insertions(+), 1 deletions(-)
diff --git a/dlls/d3dx9_36/surface.c b/dlls/d3dx9_36/surface.c index 567282c..3319927 100644 --- a/dlls/d3dx9_36/surface.c +++ b/dlls/d3dx9_36/surface.c @@ -28,9 +28,73 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3dx);
/* Wine-specific WIC GUIDs */
DEFINE_GUID(GUID_WineContainerFormatTga, 0x0c44fda1,0xa5c5,0x4298,0x96,0x85,0x47,0x3f,0xc1,0x7c,0xd3,0x22);
+/* dds_header.flags */ +#define DDS_CAPS 0x1 +#define DDS_HEIGHT 0x2 +#define DDS_WIDTH 0x2 +#define DDS_PITCH 0x8 +#define DDS_PIXELFORMAT 0x1000 +#define DDS_MIPMAPCOUNT 0x20000 +#define DDS_LINEARSIZE 0x80000 +#define DDS_DEPTH 0x800000
+/* dds_header.caps */ +#define DDS_CAPS_COMPLEX 0x8 +#define DDS_CAPS_TEXTURE 0x1000 +#define DDS_CAPS_MIPMAP 0x400000
+/* dds_header.caps2 */ +#define DDS_CAPS2_CUBEMAP 0x200 +#define DDS_CAPS2_CUBEMAP_POSITIVEX 0x400 +#define DDS_CAPS2_CUBEMAP_NEGATIVEX 0x800 +#define DDS_CAPS2_CUBEMAP_POSITIVEY 0x1000 +#define DDS_CAPS2_CUBEMAP_NEGATIVEY 0x2000 +#define DDS_CAPS2_CUBEMAP_POSITIVEZ 0x4000 +#define DDS_CAPS2_CUBEMAP_NEGATIVEZ 0x8000 +#define DDS_CAPS2_VOLUME 0x200000
+/* dds_pixel_format.flags */ +#define DDS_PF_ALPHA 0x1 +#define DDS_PF_ALPHA_ONLY 0x2 +#define DDS_PF_FOURCC 0x4 +#define DDS_PF_RGB 0x40 +#define DDS_PF_YUV 0x200 +#define DDS_PF_LUMINANCE 0x20000
+struct dds_pixel_format +{
- DWORD size;
 - DWORD flags;
 - DWORD fourcc;
 - DWORD bpp;
 - DWORD rmask;
 - DWORD gmask;
 - DWORD bmask;
 - DWORD amask;
 +};
+struct dds_header +{
- DWORD signature;
 - DWORD size;
 - DWORD flags;
 - DWORD height;
 - DWORD width;
 - DWORD pitch_or_linear_size;
 - DWORD depth;
 - DWORD miplevels;
 - DWORD reserved[11];
 - struct dds_pixel_format pixel_format;
 - DWORD caps;
 - DWORD caps2;
 - DWORD caps3;
 - DWORD caps4;
 - DWORD reserved2;
 +};
/************************************************************
- D3DXGetImageInfoFromFileInMemory