mirror of
https://github.com/reactos/reactos.git
synced 2025-04-05 05:01:03 +00:00
[WINESYNC] d3dx9: Pass D3DCOMPILE_ENABLE_BACKWARDS_COMPATIBILITY when appropriate.
Manual testing shows that the backward compatible compilation is used in d3dx9 versions below 37. Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=48302 Signed-off-by: Paul Gofman <gofmanp@gmail.com> Signed-off-by: Matteo Bruni <mbruni@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org> wine commit id 13880f8e6a0a972382de7de04b56bd1a414bef67 by Paul Gofman <gofmanp@gmail.com>
This commit is contained in:
parent
89c23f17a4
commit
7d1fa6a111
2 changed files with 7 additions and 1 deletions
|
@ -428,6 +428,9 @@ HRESULT WINAPI D3DXCompileShader(const char *data, UINT length, const D3DXMACRO
|
|||
debugstr_a(data), length, defines, include, debugstr_a(function), debugstr_a(profile),
|
||||
flags, shader, error_msgs, constant_table);
|
||||
|
||||
if (D3DX_SDK_VERSION <= 36)
|
||||
flags |= D3DCOMPILE_ENABLE_BACKWARDS_COMPATIBILITY;
|
||||
|
||||
hr = D3DCompile(data, length, NULL, (D3D_SHADER_MACRO *)defines, (ID3DInclude *)include,
|
||||
function, profile, flags, 0, (ID3DBlob **)shader, (ID3DBlob **)error_msgs);
|
||||
|
||||
|
@ -508,6 +511,9 @@ HRESULT WINAPI D3DXCompileShaderFromFileW(const WCHAR *filename, const D3DXMACRO
|
|||
return D3DXERR_INVALIDDATA;
|
||||
}
|
||||
|
||||
if (D3DX_SDK_VERSION <= 36)
|
||||
flags |= D3DCOMPILE_ENABLE_BACKWARDS_COMPATIBILITY;
|
||||
|
||||
hr = D3DCompile(buffer, len, filename_a, (const D3D_SHADER_MACRO *)defines,
|
||||
(ID3DInclude *)include, entrypoint, profile, flags, 0,
|
||||
(ID3DBlob **)shader, (ID3DBlob **)error_messages);
|
||||
|
|
|
@ -15,4 +15,4 @@ files: {include/d3dx9.h: sdk/include/dxsdk/d3dx9.h, include/d3dx9anim.h: sdk/inc
|
|||
include/d3dx9mesh.h: sdk/include/dxsdk/d3dx9mesh.h, include/d3dx9of.h: sdk/include/dxsdk/d3dx9of.h,
|
||||
include/d3dx9shader.h: sdk/include/dxsdk/d3dx9shader.h, include/d3dx9shape.h: sdk/include/dxsdk/d3dx9shape.h,
|
||||
include/d3dx9tex.h: sdk/include/dxsdk/d3dx9tex.h, include/d3dx9xof.h: sdk/include/dxsdk/d3dx9xof.h}
|
||||
tags: {wine: 96dab5abeedbb0908ac11915464f71eb74383bd7}
|
||||
tags: {wine: 13880f8e6a0a972382de7de04b56bd1a414bef67}
|
||||
|
|
Loading…
Reference in a new issue