Commit Graph

92 Commits

Author SHA1 Message Date
Matteo Bruni 24a4b8caf1 d3dx9: Build without -DWINE_NO_LONG_TYPES.
Based on a patch by Eric Pouech.

Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-20 16:51:02 +02:00
Sven Baars 1b0ad92db1 d3dx9: Reimplement make_pow2() in d3dx9_private.h.
Signed-off-by: Sven Baars <sbaars@codeweavers.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-02-25 23:43:18 +01:00
Paul Gofman 29c02234eb d3dx9: Don't pass usage flags for staging texture in D3DXCreateVolumeTextureFromFileInMemoryEx().
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-10-30 11:30:02 +01:00
Paul Gofman 0b03d21c8f d3dx9: Use check_texture_requirements() in D3DXCheckVolumeTextureRequirements() with correct resource type.
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-10-30 11:30:02 +01:00
Paul Gofman e50873f504 d3dx9: Use check_texture_requirements() in D3DXCheckCubeTextureRequirements() with correct resource type.
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-10-30 11:30:02 +01:00
Paul Gofman 92c8c0fc7f d3dx9: Factor our check_texture_requirements() function.
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-10-30 11:30:02 +01:00
Matteo Bruni fcdcd5d3cb d3dx9: Return an error if no fallback format is found.
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-10-30 11:30:02 +01:00
Paul Gofman a0840773f7 d3dx9: Don't pass usage flags for staging texture in D3DXCreateCubeTextureFromFileInMemoryEx().
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47974
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-10-30 11:26:02 +01:00
Christian Costa f6f90daa31 d3dx9: Correctly align texture dimensions to block size in D3DXCheckTextureRequirements().
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-10-02 23:48:29 +02:00
Matteo Bruni 81ababa864 d3dx9: WARN when the file doesn't exist in D3DXCreateTextureFromFileExW().
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-10-01 09:43:27 +02:00
Matteo Bruni 376182062f d3dx9: Handle compressed surfaces in D3DXLoadSurfaceFromMemory.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=24983
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-09-26 21:04:39 +02:00
Matteo Bruni 1f9243c757 d3dx9: Add traces to filtering functions.
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-09-26 21:03:26 +02:00
Matteo Bruni eadc7b3128 d3dx9: Get rid of unused unlock_surface() argument.
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-05 21:22:47 +02:00
Paul Gofman 378204527e d3dx9: Pass rectangle to {lock|unlock}_surface().
This fixes regressions introduced by commits
65956ae50a, 092c14b9d8.
Surface source or destination rectangles were left behind.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47546
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-05 21:22:36 +02:00
Alexandre Julliard 9fb5745a79 d3dx9: Build with msvcrt.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-05-30 20:20:09 +02:00
Paul Gofman 4e44d74afb d3dx9: Use temporary surface in D3DXFillTexture() for unmappable textures.
Fixes a regression triggered by commit 949dbbd31f.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=46453
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-01-23 16:31:31 +01:00
Zebediah Figura 7dbcbed704 d3dx9: Add stub for D3DXComputeNormalMap.
Based on a patch by Christian Costa.

Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-03-13 20:58:08 +01:00
Michael Stefaniuc f46c96332b d3dx9: Use the available ARRAY_SIZE() macro.
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-02-21 15:31:29 +01:00
Matteo Bruni 2cd9db009a d3dx9: Add stubs for D3DXFill*TextureTX().
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-08-05 14:49:10 -05:00
Matteo Bruni 4d1192ad89 d3dx9: Cleanup header includes.
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-15 14:12:29 +09:00
Paul Gofman 546c55a09d d3dx9: Don't pass usage flags when creating temporary texture
Some usage flags require D3DPOOL_DEFAULT (and not D3DPOOL_SYSTEMMEM),
and the usage of texture being created is overall not related to
intermediate buffer texture usage. If texture being created has
D3DUSAGE_AUTOGENMIPMAP, updating it from non autogenerated mipmap should
be fine according to MSDN (IDirect3DDevice9::UpdateTexture).

Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-25 23:24:14 +09:00
Andrey Gusev 07630a9eae d3dx9_36: Assorted spelling and typos fixes. 2015-03-31 00:04:42 +09:00
Matteo Bruni beb72c91af d3dx9: Improve the scoring for fallback formats. 2014-11-11 14:21:12 +09:00
Matteo Bruni 1569698d9e d3dx9: Use an alpha-capable format when creating textures with a color key. 2014-11-11 14:21:07 +09:00
Matteo Bruni 5aeb834dd4 d3dx9: Allow implicit conversions in D3DXCreateTextureFromFileInMemoryEx.
They should be generally supported by the existing code.
Specific missing format conversions are caught and reported by
D3DXLoadSurfaceFromMemory(), which is called directly or indirectly
from here.
2014-08-27 19:24:41 +02:00
Matteo Bruni 770eaec561 d3dx9: Properly evaluate fallbacks for luminance texture formats in D3DXCheckTextureRequirements. 2014-08-25 22:02:21 +02:00
Matteo Bruni 596557a57a d3dx9: Support skipping mip levels in D3DXCreateTextureFromFileInMemoryEx. 2014-03-05 19:18:17 +01:00
Matteo Bruni df3c573f63 d3dx9: Allow loading DDS volume textures into 2D textures. 2014-03-03 17:53:53 +01:00
Matteo Bruni 190877422e d3dx9: Enforce minimum texture dimensions for block-based pixel formats. 2014-02-17 20:16:21 +01:00
Matteo Bruni dda9da793f d3dx9: Add some TRACEs and FIXMEs to D3DXCreateTextureFromFileInMemoryEx. 2014-02-17 20:16:20 +01:00
Henri Verbeet 871967d0fb d3dx9: Avoid LPVOID. 2013-09-04 11:37:06 +02:00
Henri Verbeet 2a24b11af5 d3dx9: Avoid LPWSTR. 2013-09-02 18:02:46 +02:00
Henri Verbeet d35c67becd d3dx9: Simplify D3DXCreateTextureFromResourceExW(). 2013-08-29 19:56:17 +02:00
Henri Verbeet 4b56eae0f1 d3dx9: Simplify D3DXCreateTextureFromResourceExA(). 2013-08-29 19:56:17 +02:00
Rico Schüller 25ce3a4220 d3dx9: Add support for D3DFMT_A32B32G32R32F. 2013-01-16 12:20:23 +01:00
Rico Schüller 43f30fe8d6 d3dx9: Add support for D3DFMT_A16B16G16R16F. 2013-01-11 11:58:16 +01:00
Rico Schüller f7d877061d d3dx9: Use all 32 bits as mask. 2013-01-10 19:22:36 +01:00
Rico Schüller 98ef0ca8e6 d3dx9: Shift only as much as needed. 2013-01-10 19:21:31 +01:00
Rico Schüller 275f784009 d3dx9: Introduce a function for filling a texture. 2013-01-10 19:19:49 +01:00
Christian Costa 4778a5e27d d3dx9_36: Add support for RT_BITMAP resource type since it is in DIB format D3DXIFF_DIB. 2013-01-07 19:33:09 +01:00
Henri Verbeet 4ba6974345 d3dx9: Avoid LPDIRECT3DDEVICE9. 2012-10-29 10:47:03 +01:00
Henri Verbeet c4f7bcc653 d3dx9: Avoid LPDIRECT3DBASETEXTURE9. 2012-10-25 22:27:29 +02:00
Henri Verbeet 3280939563 d3dx9: Avoid LPDIRECT3DTEXTURE9. 2012-10-25 11:48:39 +02:00
Henri Verbeet 9b19d75519 d3dx9: Avoid LPDIRECT3DCUBETEXTURE9. 2012-10-25 11:48:35 +02:00
Henri Verbeet 80382486aa d3dx9: Avoid LPDIRECT3DVOLUMETEXTURE9. 2012-10-24 11:24:31 +02:00
Józef Kucia 2c19f22c8a d3dx9: Do not try to fill textures other than ARGB in fill texture functions. 2012-10-23 12:07:53 +02:00
Rico Schüller 8da8811615 d3dx9: Remove PixelFormatDesc typedef. 2012-09-03 15:51:57 +02:00
Józef Kucia 2c1968aef9 d3dx9: Allow D3DX_DEFAULT to be passed as srclevel to D3DXFilterTexture. 2012-07-23 14:55:45 +02:00
Józef Kucia ffe36a3894 d3dx9: Implement volume texture filtering in D3DXFilterTexture. 2012-07-16 16:56:17 +02:00
Józef Kucia fde802a04d d3dx9: Forward D3DXCreateVolumeTextureFromFile functions to D3DXCreateVolumeTextureFromFileInMemoryEx. 2012-07-02 11:59:24 +02:00