Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2008 Tony Wasserka |
| 3 | * |
| 4 | * This library is free software; you can redistribute it and/or |
| 5 | * modify it under the terms of the GNU Lesser General Public |
| 6 | * License as published by the Free Software Foundation; either |
| 7 | * version 2.1 of the License, or (at your option) any later version. |
| 8 | * |
| 9 | * This library is distributed in the hope that it will be useful, |
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 12 | * Lesser General Public License for more details. |
| 13 | * |
| 14 | * You should have received a copy of the GNU Lesser General Public |
| 15 | * License along with this library; if not, write to the Free Software |
| 16 | * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA |
| 17 | */ |
| 18 | |
| 19 | #include <d3dx9.h> |
| 20 | |
| 21 | #ifndef __WINE_D3DX9TEX_H |
| 22 | #define __WINE_D3DX9TEX_H |
| 23 | |
| 24 | /********************************************** |
| 25 | ***************** Definitions **************** |
| 26 | **********************************************/ |
| 27 | #define D3DX_FILTER_NONE 0x00000001 |
| 28 | #define D3DX_FILTER_POINT 0x00000002 |
| 29 | #define D3DX_FILTER_LINEAR 0x00000003 |
| 30 | #define D3DX_FILTER_TRIANGLE 0x00000004 |
| 31 | #define D3DX_FILTER_BOX 0x00000005 |
| 32 | #define D3DX_FILTER_MIRROR_U 0x00010000 |
| 33 | #define D3DX_FILTER_MIRROR_V 0x00020000 |
| 34 | #define D3DX_FILTER_MIRROR_W 0x00040000 |
| 35 | #define D3DX_FILTER_MIRROR 0x00070000 |
| 36 | #define D3DX_FILTER_DITHER 0x00080000 |
| 37 | #define D3DX_FILTER_DITHER_DIFFUSION 0x00100000 |
| 38 | #define D3DX_FILTER_SRGB_IN 0x00200000 |
| 39 | #define D3DX_FILTER_SRGB_OUT 0x00400000 |
| 40 | #define D3DX_FILTER_SRGB 0x00600000 |
| 41 | |
| 42 | #define D3DX_NORMALMAP_MIRROR_U 0x00010000 |
| 43 | #define D3DX_NORMALMAP_MIRROR_V 0x00020000 |
| 44 | #define D3DX_NORMALMAP_MIRROR 0x00030000 |
| 45 | #define D3DX_NORMALMAP_INVERTSIGN 0x00080000 |
| 46 | #define D3DX_NORMALMAP_COMPUTE_OCCLUSION 0x00100000 |
| 47 | |
| 48 | #define D3DX_CHANNEL_RED 0x00000001 |
| 49 | #define D3DX_CHANNEL_BLUE 0x00000002 |
| 50 | #define D3DX_CHANNEL_GREEN 0x00000004 |
| 51 | #define D3DX_CHANNEL_ALPHA 0x00000008 |
| 52 | #define D3DX_CHANNEL_LUMINANCE 0x00000010 |
| 53 | |
| 54 | /********************************************** |
Christian Costa | f36f49f | 2012-02-08 19:19:36 +0100 | [diff] [blame] | 55 | ****************** Typedefs ****************** |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 56 | **********************************************/ |
| 57 | typedef enum _D3DXIMAGE_FILEFORMAT |
| 58 | { |
| 59 | D3DXIFF_BMP, |
| 60 | D3DXIFF_JPG, |
| 61 | D3DXIFF_TGA, |
| 62 | D3DXIFF_PNG, |
| 63 | D3DXIFF_DDS, |
| 64 | D3DXIFF_PPM, |
| 65 | D3DXIFF_DIB, |
Christian Costa | f36f49f | 2012-02-08 19:19:36 +0100 | [diff] [blame] | 66 | D3DXIFF_HDR, |
| 67 | D3DXIFF_PFM, |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 68 | D3DXIFF_FORCE_DWORD = 0x7fffffff |
| 69 | } D3DXIMAGE_FILEFORMAT; |
| 70 | |
| 71 | typedef struct _D3DXIMAGE_INFO |
| 72 | { |
| 73 | UINT Width; |
| 74 | UINT Height; |
| 75 | UINT Depth; |
| 76 | UINT MipLevels; |
| 77 | D3DFORMAT Format; |
| 78 | D3DRESOURCETYPE ResourceType; |
| 79 | D3DXIMAGE_FILEFORMAT ImageFileFormat; |
| 80 | } D3DXIMAGE_INFO; |
| 81 | |
| 82 | /********************************************** |
| 83 | ****************** Functions ***************** |
| 84 | **********************************************/ |
| 85 | /* Typedefs for callback functions */ |
| 86 | typedef VOID (WINAPI *LPD3DXFILL2D)(D3DXVECTOR4 *out, CONST D3DXVECTOR2 *texcoord, CONST D3DXVECTOR2 *texelsize, LPVOID data); |
| 87 | typedef VOID (WINAPI *LPD3DXFILL3D)(D3DXVECTOR4 *out, CONST D3DXVECTOR3 *texcoord, CONST D3DXVECTOR3 *texelsize, LPVOID data); |
| 88 | |
| 89 | #ifdef __cplusplus |
| 90 | extern "C" { |
| 91 | #endif |
| 92 | |
| 93 | |
| 94 | /* Image Information */ |
| 95 | HRESULT WINAPI D3DXGetImageInfoFromFileA(LPCSTR file, D3DXIMAGE_INFO *info); |
| 96 | HRESULT WINAPI D3DXGetImageInfoFromFileW(LPCWSTR file, D3DXIMAGE_INFO *info); |
| 97 | #define D3DXGetImageInfoFromFile WINELIB_NAME_AW(D3DXGetImageInfoFromFile) |
| 98 | |
| 99 | HRESULT WINAPI D3DXGetImageInfoFromResourceA(HMODULE module, LPCSTR resource, D3DXIMAGE_INFO *info); |
| 100 | HRESULT WINAPI D3DXGetImageInfoFromResourceW(HMODULE module, LPCWSTR resource, D3DXIMAGE_INFO *info); |
| 101 | #define D3DXGetImageInfoFromResource WINELIB_NAME_AW(D3DXGetImageInfoFromResource) |
| 102 | |
| 103 | HRESULT WINAPI D3DXGetImageInfoFromFileInMemory(LPCVOID data, UINT datasize, D3DXIMAGE_INFO *info); |
| 104 | |
| 105 | |
| 106 | /* Surface Loading/Saving */ |
Henri Verbeet | 9ec7cdf | 2012-10-28 20:54:50 +0100 | [diff] [blame] | 107 | HRESULT WINAPI D3DXLoadSurfaceFromFileA(struct IDirect3DSurface9 *destsurface, |
| 108 | const PALETTEENTRY *destpalette, const RECT *destrect, const char *srcfile, |
| 109 | const RECT *srcrect, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
| 110 | HRESULT WINAPI D3DXLoadSurfaceFromFileW(struct IDirect3DSurface9 *destsurface, |
| 111 | const PALETTEENTRY *destpalette, const RECT *destrect, const WCHAR *srcfile, |
| 112 | const RECT *srcrect, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
| 113 | #define D3DXLoadSurfaceFromFile WINELIB_NAME_AW(D3DXLoadSurfaceFromFile) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 114 | |
Henri Verbeet | 9ec7cdf | 2012-10-28 20:54:50 +0100 | [diff] [blame] | 115 | HRESULT WINAPI D3DXLoadSurfaceFromResourceA(struct IDirect3DSurface9 *destsurface, |
| 116 | const PALETTEENTRY *destpalette, const RECT *destrect, HMODULE srcmodule, const char *resource, |
| 117 | const RECT *srcrect, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
| 118 | HRESULT WINAPI D3DXLoadSurfaceFromResourceW(struct IDirect3DSurface9 *destsurface, |
| 119 | const PALETTEENTRY *destpalette, const RECT *destrect, HMODULE srcmodule, const WCHAR *resource, |
| 120 | const RECT *srcrect, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
| 121 | #define D3DXLoadSurfaceFromResource WINELIB_NAME_AW(D3DXLoadSurfaceFromResource) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 122 | |
Henri Verbeet | 9ec7cdf | 2012-10-28 20:54:50 +0100 | [diff] [blame] | 123 | HRESULT WINAPI D3DXLoadSurfaceFromFileInMemory(struct IDirect3DSurface9 *destsurface, |
| 124 | const PALETTEENTRY *destpalette, const RECT *destrect, const void *srcdata, UINT srcdatasize, |
| 125 | const RECT *srcrect, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 126 | |
Henri Verbeet | 9ec7cdf | 2012-10-28 20:54:50 +0100 | [diff] [blame] | 127 | HRESULT WINAPI D3DXLoadSurfaceFromSurface(struct IDirect3DSurface9 *destsurface, |
| 128 | const PALETTEENTRY *destpalette, const RECT *destrect, struct IDirect3DSurface9 *srcsurface, |
| 129 | const PALETTEENTRY *srcpalette, const RECT *srcrect, DWORD filter, D3DCOLOR colorkey); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 130 | |
Henri Verbeet | b8f6c9c | 2012-04-30 21:30:20 +0200 | [diff] [blame] | 131 | HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface, |
| 132 | const PALETTEENTRY *dst_palette, const RECT *dst_rect, const void *src_memory, |
| 133 | D3DFORMAT src_format, UINT src_pitch, const PALETTEENTRY *src_palette, const RECT *src_rect, |
| 134 | DWORD filter, D3DCOLOR color_key); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 135 | |
Henri Verbeet | 9ec7cdf | 2012-10-28 20:54:50 +0100 | [diff] [blame] | 136 | HRESULT WINAPI D3DXSaveSurfaceToFileInMemory(struct ID3DXBuffer **destbuffer, |
| 137 | D3DXIMAGE_FILEFORMAT destformat, struct IDirect3DSurface9 *srcsurface, |
| 138 | const PALETTEENTRY *srcpalette, const RECT *srcrect); |
Józef Kucia | 70b1bff | 2012-05-29 11:29:22 +0200 | [diff] [blame] | 139 | |
Henri Verbeet | 9ec7cdf | 2012-10-28 20:54:50 +0100 | [diff] [blame] | 140 | HRESULT WINAPI D3DXSaveSurfaceToFileA(const char *destfile, D3DXIMAGE_FILEFORMAT destformat, |
| 141 | struct IDirect3DSurface9 *srcsurface, const PALETTEENTRY *srcpalette, const RECT *srcrect); |
| 142 | HRESULT WINAPI D3DXSaveSurfaceToFileW(const WCHAR *destfile, D3DXIMAGE_FILEFORMAT destformat, |
| 143 | struct IDirect3DSurface9 *srcsurface, const PALETTEENTRY *srcpalette, const RECT *srcrect); |
| 144 | #define D3DXSaveSurfaceToFile WINELIB_NAME_AW(D3DXSaveSurfaceToFile) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 145 | |
| 146 | |
| 147 | /* Volume Loading/Saving */ |
Henri Verbeet | 6c26a0f | 2012-10-28 20:54:51 +0100 | [diff] [blame] | 148 | HRESULT WINAPI D3DXLoadVolumeFromFileA(struct IDirect3DVolume9 *destvolume, |
| 149 | const PALETTEENTRY *destpalette, const D3DBOX *destbox, const char *srcfile, |
| 150 | const D3DBOX *srcbox, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
| 151 | HRESULT WINAPI D3DXLoadVolumeFromFileW( struct IDirect3DVolume9 *destvolume, |
| 152 | const PALETTEENTRY *destpalette, const D3DBOX *destbox, const WCHAR *srcfile, |
| 153 | const D3DBOX *srcbox, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
| 154 | #define D3DXLoadVolumeFromFile WINELIB_NAME_AW(D3DXLoadVolumeFromFile) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 155 | |
Henri Verbeet | 6c26a0f | 2012-10-28 20:54:51 +0100 | [diff] [blame] | 156 | HRESULT WINAPI D3DXLoadVolumeFromResourceA(struct IDirect3DVolume9 *destvolume, |
| 157 | const PALETTEENTRY *destpalette, const D3DBOX *destbox, HMODULE srcmodule, const char *resource, |
| 158 | const D3DBOX *srcbox, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
| 159 | HRESULT WINAPI D3DXLoadVolumeFromResourceW(struct IDirect3DVolume9 *destvolume, |
| 160 | const PALETTEENTRY *destpalette, const D3DBOX *destbox, HMODULE srcmodule, const WCHAR *resource, |
| 161 | const D3DBOX *srcbox, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
| 162 | #define D3DXLoadVolumeFromResource WINELIB_NAME_AW(D3DXLoadVolumeFromResource) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 163 | |
Henri Verbeet | 6c26a0f | 2012-10-28 20:54:51 +0100 | [diff] [blame] | 164 | HRESULT WINAPI D3DXLoadVolumeFromFileInMemory(struct IDirect3DVolume9 *destvolume, |
| 165 | const PALETTEENTRY *destpalette, const D3DBOX *destbox, const void *srcdata, UINT srcdatasize, |
| 166 | const D3DBOX *srcbox, DWORD filter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 167 | |
Henri Verbeet | 6c26a0f | 2012-10-28 20:54:51 +0100 | [diff] [blame] | 168 | HRESULT WINAPI D3DXLoadVolumeFromVolume(struct IDirect3DVolume9 *destvolume, |
| 169 | const PALETTEENTRY *destpalette, const D3DBOX *destbox, struct IDirect3DVolume9 *srcvolume, |
| 170 | const PALETTEENTRY *srcpalette, const D3DBOX *srcbox, DWORD filter, D3DCOLOR colorkey); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 171 | |
Henri Verbeet | 6c26a0f | 2012-10-28 20:54:51 +0100 | [diff] [blame] | 172 | HRESULT WINAPI D3DXLoadVolumeFromMemory(struct IDirect3DVolume9 *destvolume, |
| 173 | const PALETTEENTRY *destpalette, const D3DBOX *destbox, const void *srcmemory, |
| 174 | D3DFORMAT srcformat, UINT srcrowpitch, UINT srcslicepitch, const PALETTEENTRY *srcpalette, |
| 175 | const D3DBOX *srcbox, DWORD filter, D3DCOLOR colorkey); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 176 | |
Henri Verbeet | 6c26a0f | 2012-10-28 20:54:51 +0100 | [diff] [blame] | 177 | HRESULT WINAPI D3DXSaveVolumeToFileA(const char *destfile, D3DXIMAGE_FILEFORMAT destformat, |
| 178 | struct IDirect3DVolume9 *srcvolume, const PALETTEENTRY *srcpalette, const D3DBOX *srcbox); |
| 179 | HRESULT WINAPI D3DXSaveVolumeToFileW(const WCHAR *destfile, D3DXIMAGE_FILEFORMAT destformat, |
| 180 | struct IDirect3DVolume9 *srcvolume, const PALETTEENTRY *srcpalette, const D3DBOX *srcbox); |
| 181 | #define D3DXSaveVolumeToFile WINELIB_NAME_AW(D3DXSaveVolumeToFile) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 182 | |
| 183 | |
| 184 | /* Texture, cube texture and volume texture creation */ |
Henri Verbeet | 4ba6974 | 2012-10-28 20:54:52 +0100 | [diff] [blame] | 185 | HRESULT WINAPI D3DXCheckTextureRequirements(struct IDirect3DDevice9 *device, UINT *width, UINT *height, |
| 186 | UINT *miplevels, DWORD usage, D3DFORMAT *format, D3DPOOL pool); |
| 187 | HRESULT WINAPI D3DXCheckCubeTextureRequirements(struct IDirect3DDevice9 *device, UINT *size, |
| 188 | UINT *miplevels, DWORD usage, D3DFORMAT *format, D3DPOOL pool); |
| 189 | HRESULT WINAPI D3DXCheckVolumeTextureRequirements(struct IDirect3DDevice9 *device, UINT *width, UINT *height, |
| 190 | UINT *depth, UINT *miplevels, DWORD usage, D3DFORMAT *format, D3DPOOL pool); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 191 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 192 | HRESULT WINAPI D3DXCreateTexture(struct IDirect3DDevice9 *device, UINT width, UINT height, |
| 193 | UINT miplevels, DWORD usage, D3DFORMAT format, D3DPOOL pool, struct IDirect3DTexture9 **texture); |
Henri Verbeet | 9b19d75 | 2012-10-24 21:23:38 +0200 | [diff] [blame] | 194 | HRESULT WINAPI D3DXCreateCubeTexture(struct IDirect3DDevice9 *device, UINT size, |
| 195 | UINT miplevels, DWORD usage, D3DFORMAT format, D3DPOOL pool, struct IDirect3DCubeTexture9 **cube); |
Henri Verbeet | 8038248 | 2012-10-23 21:01:08 +0200 | [diff] [blame] | 196 | HRESULT WINAPI D3DXCreateVolumeTexture(struct IDirect3DDevice9 *device, UINT width, UINT height, UINT depth, |
| 197 | UINT miplevels, DWORD usage, D3DFORMAT format, D3DPOOL pool, struct IDirect3DVolumeTexture9 **volume); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 198 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 199 | HRESULT WINAPI D3DXCreateTextureFromFileA(struct IDirect3DDevice9 *device, |
| 200 | const char *srcfile, struct IDirect3DTexture9 **texture); |
| 201 | HRESULT WINAPI D3DXCreateTextureFromFileW(struct IDirect3DDevice9 *device, |
| 202 | const WCHAR *srcfile, struct IDirect3DTexture9 **texture); |
| 203 | #define D3DXCreateTextureFromFile WINELIB_NAME_AW(D3DXCreateTextureFromFile) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 204 | |
Henri Verbeet | 9b19d75 | 2012-10-24 21:23:38 +0200 | [diff] [blame] | 205 | HRESULT WINAPI D3DXCreateCubeTextureFromFileA(struct IDirect3DDevice9 *device, |
| 206 | const char *srcfile, struct IDirect3DCubeTexture9 **cube); |
| 207 | HRESULT WINAPI D3DXCreateCubeTextureFromFileW(struct IDirect3DDevice9 *device, |
| 208 | const WCHAR *srcfile, struct IDirect3DCubeTexture9 **cube); |
| 209 | #define D3DXCreateCubeTextureFromFile WINELIB_NAME_AW(D3DXCreateCubeTextureFromFile) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 210 | |
Henri Verbeet | 8038248 | 2012-10-23 21:01:08 +0200 | [diff] [blame] | 211 | HRESULT WINAPI D3DXCreateVolumeTextureFromFileA(struct IDirect3DDevice9 *device, |
| 212 | const char *srcfile, struct IDirect3DVolumeTexture9 **volume); |
| 213 | HRESULT WINAPI D3DXCreateVolumeTextureFromFileW(struct IDirect3DDevice9 *device, |
| 214 | const WCHAR *srcfile, struct IDirect3DVolumeTexture9 **volume); |
| 215 | #define D3DXCreateVolumeTextureFromFile WINELIB_NAME_AW(D3DXCreateVolumeTextureFromFile) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 216 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 217 | HRESULT WINAPI D3DXCreateTextureFromResourceA(struct IDirect3DDevice9 *device, |
| 218 | HMODULE srcmodule, const char *resource, struct IDirect3DTexture9 **texture); |
| 219 | HRESULT WINAPI D3DXCreateTextureFromResourceW(struct IDirect3DDevice9 *device, |
| 220 | HMODULE srcmodule, const WCHAR *resource, struct IDirect3DTexture9 **texture); |
| 221 | #define D3DXCreateTextureFromResource WINELIB_NAME_AW(D3DXCreateTextureFromResource) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 222 | |
Henri Verbeet | 9b19d75 | 2012-10-24 21:23:38 +0200 | [diff] [blame] | 223 | HRESULT WINAPI D3DXCreateCubeTextureFromResourceA(struct IDirect3DDevice9 *device, |
| 224 | HMODULE srcmodule, const char *resource, struct IDirect3DCubeTexture9 **cube); |
| 225 | HRESULT WINAPI D3DXCreateCubeTextureFromResourceW(struct IDirect3DDevice9 *device, |
| 226 | HMODULE srcmodule, const WCHAR *resource, struct IDirect3DCubeTexture9 **cube); |
| 227 | #define D3DXCreateCubeTextureFromResource WINELIB_NAME_AW(D3DXCreateCubeTextureFromResource) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 228 | |
Henri Verbeet | 8038248 | 2012-10-23 21:01:08 +0200 | [diff] [blame] | 229 | HRESULT WINAPI D3DXCreateVolumeTextureFromResourceA(struct IDirect3DDevice9 *device, |
| 230 | HMODULE srcmodule, const char *resource, struct IDirect3DVolumeTexture9 **volume); |
| 231 | HRESULT WINAPI D3DXCreateVolumeTextureFromResourceW(struct IDirect3DDevice9 *device, |
| 232 | HMODULE srcmodule, const WCHAR *resource, struct IDirect3DVolumeTexture9 **volume); |
| 233 | #define D3DXCreateVolumeTextureFromResource WINELIB_NAME_AW(D3DXCreateVolumeTextureFromResource) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 234 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 235 | HRESULT WINAPI D3DXCreateTextureFromFileExA(struct IDirect3DDevice9 *device, const char *srcfile, |
| 236 | UINT width, UINT height, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 237 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 238 | PALETTEENTRY *palette, struct IDirect3DTexture9 **texture); |
| 239 | HRESULT WINAPI D3DXCreateTextureFromFileExW(struct IDirect3DDevice9 *device, const WCHAR *srcfile, |
| 240 | UINT width, UINT height, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 241 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 242 | PALETTEENTRY *palette, struct IDirect3DTexture9 **texture); |
| 243 | #define D3DXCreateTextureFromFileEx WINELIB_NAME_AW(D3DXCreateTextureFromFileEx) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 244 | |
Henri Verbeet | 9b19d75 | 2012-10-24 21:23:38 +0200 | [diff] [blame] | 245 | HRESULT WINAPI D3DXCreateCubeTextureFromFileExA(struct IDirect3DDevice9 *device, const char *srcfile, |
| 246 | UINT size, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 247 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 248 | PALETTEENTRY *palette, struct IDirect3DCubeTexture9 **cube); |
| 249 | HRESULT WINAPI D3DXCreateCubeTextureFromFileExW(struct IDirect3DDevice9 *device, const WCHAR *srcfile, |
| 250 | UINT size, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 251 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 252 | PALETTEENTRY *palette, struct IDirect3DCubeTexture9 **cube); |
| 253 | #define D3DXCreateCubeTextureFromFileEx WINELIB_NAME_AW(D3DXCreateCubeTextureFromFileEx) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 254 | |
Henri Verbeet | 8038248 | 2012-10-23 21:01:08 +0200 | [diff] [blame] | 255 | HRESULT WINAPI D3DXCreateVolumeTextureFromFileExA(struct IDirect3DDevice9 *device, const char *srcfile, |
| 256 | UINT width, UINT height, UINT depth, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 257 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 258 | PALETTEENTRY *palette, struct IDirect3DVolumeTexture9 **volume); |
| 259 | HRESULT WINAPI D3DXCreateVolumeTextureFromFileExW(struct IDirect3DDevice9 *device, const WCHAR *srcfile, |
| 260 | UINT width, UINT height, UINT depth, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 261 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 262 | PALETTEENTRY *palette, struct IDirect3DVolumeTexture9 **volume); |
| 263 | #define D3DXCreateVolumeTextureFromFileEx WINELIB_NAME_AW(D3DXCreateVolumeTextureFromFileEx) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 264 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 265 | HRESULT WINAPI D3DXCreateTextureFromResourceExA(struct IDirect3DDevice9 *device, HMODULE srcmodule, |
| 266 | const char *resource, UINT width, UINT height, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 267 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 268 | PALETTEENTRY *palette, struct IDirect3DTexture9 **texture); |
| 269 | HRESULT WINAPI D3DXCreateTextureFromResourceExW(struct IDirect3DDevice9 *device, HMODULE srcmodule, |
| 270 | const WCHAR *resource, UINT width, UINT height, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 271 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 272 | PALETTEENTRY *palette, struct IDirect3DTexture9 **texture); |
| 273 | #define D3DXCreateTextureFromResourceEx WINELIB_NAME_AW(D3DXCreateTextureFromResourceEx) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 274 | |
Henri Verbeet | 9b19d75 | 2012-10-24 21:23:38 +0200 | [diff] [blame] | 275 | HRESULT WINAPI D3DXCreateCubeTextureFromResourceExA(struct IDirect3DDevice9 *device, HMODULE srcmodule, |
| 276 | const char *resource, UINT size, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 277 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 278 | PALETTEENTRY *palette, struct IDirect3DCubeTexture9 **cube); |
| 279 | HRESULT WINAPI D3DXCreateCubeTextureFromResourceExW(struct IDirect3DDevice9 *device, HMODULE srcmodule, |
| 280 | const WCHAR *resource, UINT size, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 281 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 282 | PALETTEENTRY *palette, struct IDirect3DCubeTexture9 **cube); |
| 283 | #define D3DXCreateCubeTextureFromResourceEx WINELIB_NAME_AW(D3DXCreateCubeTextureFromResourceEx) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 284 | |
Henri Verbeet | 8038248 | 2012-10-23 21:01:08 +0200 | [diff] [blame] | 285 | HRESULT WINAPI D3DXCreateVolumeTextureFromResourceExA(struct IDirect3DDevice9 *device, HMODULE srcmodule, |
| 286 | const char *resource, UINT width, UINT height, UINT depth, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 287 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 288 | PALETTEENTRY *palette, struct IDirect3DVolumeTexture9 **volume); |
| 289 | HRESULT WINAPI D3DXCreateVolumeTextureFromResourceExW(struct IDirect3DDevice9 *device, HMODULE srcmodule, |
| 290 | const WCHAR *resource, UINT width, UINT height, UINT depth, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 291 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 292 | PALETTEENTRY *palette, struct IDirect3DVolumeTexture9 **volume); |
| 293 | #define D3DXCreateVolumeTextureFromResourceEx WINELIB_NAME_AW(D3DXCreateVolumeTextureFromResourceEx) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 294 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 295 | HRESULT WINAPI D3DXCreateTextureFromFileInMemory(struct IDirect3DDevice9 *device, |
| 296 | const void *srcdata, UINT srcdatasize, struct IDirect3DTexture9 **texture); |
Henri Verbeet | 9b19d75 | 2012-10-24 21:23:38 +0200 | [diff] [blame] | 297 | HRESULT WINAPI D3DXCreateCubeTextureFromFileInMemory(struct IDirect3DDevice9 *device, |
| 298 | const void *srcdata, UINT srcdatasize, struct IDirect3DCubeTexture9 **cube); |
Henri Verbeet | 8038248 | 2012-10-23 21:01:08 +0200 | [diff] [blame] | 299 | HRESULT WINAPI D3DXCreateVolumeTextureFromFileInMemory(struct IDirect3DDevice9 *device, |
| 300 | const void *srcdata, UINT srcdatasize, struct IDirect3DVolumeTexture9 **volume); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 301 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 302 | HRESULT WINAPI D3DXCreateTextureFromFileInMemoryEx(struct IDirect3DDevice9 *device, const void *srcdata, |
| 303 | UINT srcdatasize, UINT width, UINT height, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 304 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 305 | PALETTEENTRY *palette, struct IDirect3DTexture9 **texture); |
Henri Verbeet | 9b19d75 | 2012-10-24 21:23:38 +0200 | [diff] [blame] | 306 | HRESULT WINAPI D3DXCreateCubeTextureFromFileInMemoryEx(struct IDirect3DDevice9 *device, const void *srcdata, |
| 307 | UINT srcdatasize, UINT size, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 308 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 309 | PALETTEENTRY *palette, struct IDirect3DCubeTexture9 **cube); |
Henri Verbeet | 8038248 | 2012-10-23 21:01:08 +0200 | [diff] [blame] | 310 | HRESULT WINAPI D3DXCreateVolumeTextureFromFileInMemoryEx(struct IDirect3DDevice9 *device, const void *srcdata, |
| 311 | UINT srcdatasize, UINT width, UINT height, UINT depth, UINT miplevels, DWORD usage, D3DFORMAT format, |
| 312 | D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, |
| 313 | PALETTEENTRY *palette, struct IDirect3DVolumeTexture9 **volume); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 314 | |
Henri Verbeet | c4f7bcc | 2012-10-25 21:21:37 +0200 | [diff] [blame] | 315 | HRESULT WINAPI D3DXSaveTextureToFileInMemory(struct ID3DXBuffer **destbuffer, D3DXIMAGE_FILEFORMAT destformat, |
| 316 | struct IDirect3DBaseTexture9 *srctexture, const PALETTEENTRY *srcpalette); |
| 317 | HRESULT WINAPI D3DXSaveTextureToFileA(const char *destfile, D3DXIMAGE_FILEFORMAT destformat, |
| 318 | struct IDirect3DBaseTexture9 *srctexture, const PALETTEENTRY *srcpalette); |
| 319 | HRESULT WINAPI D3DXSaveTextureToFileW(const WCHAR *destfile, D3DXIMAGE_FILEFORMAT destformat, |
| 320 | struct IDirect3DBaseTexture9 *srctexture, const PALETTEENTRY *srcpalette); |
| 321 | #define D3DXSaveTextureToFile WINELIB_NAME_AW(D3DXSaveTextureToFile) |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 322 | |
| 323 | /* Other functions */ |
Henri Verbeet | c4f7bcc | 2012-10-25 21:21:37 +0200 | [diff] [blame] | 324 | HRESULT WINAPI D3DXFilterTexture(struct IDirect3DBaseTexture9 *texture, |
| 325 | const PALETTEENTRY *palette, UINT srclevel, DWORD filter); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 326 | #define D3DXFilterCubeTexture D3DXFilterTexture |
| 327 | #define D3DXFilterVolumeTexture D3DXFilterTexture |
| 328 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 329 | HRESULT WINAPI D3DXFillTexture(struct IDirect3DTexture9 *texture, LPD3DXFILL2D function, void *data); |
Henri Verbeet | 9b19d75 | 2012-10-24 21:23:38 +0200 | [diff] [blame] | 330 | HRESULT WINAPI D3DXFillCubeTexture(struct IDirect3DCubeTexture9 *cube, LPD3DXFILL3D function, void *data); |
Henri Verbeet | 8038248 | 2012-10-23 21:01:08 +0200 | [diff] [blame] | 331 | HRESULT WINAPI D3DXFillVolumeTexture(struct IDirect3DVolumeTexture9 *volume, LPD3DXFILL3D function, void *data); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 332 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 333 | HRESULT WINAPI D3DXFillTextureTX(struct IDirect3DTexture9 *texture, const DWORD *function, |
| 334 | const D3DXVECTOR4 *constants, UINT numconstants); |
Henri Verbeet | 9b19d75 | 2012-10-24 21:23:38 +0200 | [diff] [blame] | 335 | HRESULT WINAPI D3DXFillCubeTextureTX(struct IDirect3DCubeTexture9 *cube, const DWORD *function, |
| 336 | const D3DXVECTOR4 *constants, UINT numconstants); |
Henri Verbeet | 8038248 | 2012-10-23 21:01:08 +0200 | [diff] [blame] | 337 | HRESULT WINAPI D3DXFillVolumeTextureTX(struct IDirect3DVolumeTexture9 *volume, const DWORD *function, |
| 338 | const D3DXVECTOR4 *constants, UINT numconstants); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 339 | |
Henri Verbeet | 3280939 | 2012-10-24 21:23:39 +0200 | [diff] [blame] | 340 | HRESULT WINAPI D3DXComputeNormalMap(IDirect3DTexture9 *texture, IDirect3DTexture9 *srctexture, |
| 341 | const PALETTEENTRY *srcpalette, DWORD flags, DWORD channel, float amplitude); |
Tony Wasserka | d9e98ea | 2008-04-15 15:30:03 +0200 | [diff] [blame] | 342 | |
| 343 | #ifdef __cplusplus |
| 344 | } |
| 345 | #endif |
| 346 | |
| 347 | #endif /* __WINE_D3DX9TEX_H */ |