ID3DXBaseEffect::SetValue

Luis Carlos Busquets Pérez luis.busquets at ilidium.com
Mon Feb 6 23:02:27 CST 2012


Indeed the test I made ist for ID3DXEffect::SetValue and I refer to 
ID3DXBaseEffect::SetValue as the previous refers to this one in the 
code. Find attached my test file for your convenienve.
In the test case I have found that

1. If the functions returns E_FAIL for a sample then
   test_effect.c:1917: Test failed: Got result 80004005, expected 0 (D3D_OK)
2. For D3DXPT_VERTEXSHADER and D3DXPT_PIXELSHADER replying with E_FAIL 
avoids
  test_effect.c:1812: Test failed: Got result 0, expected 0x80004005 
(E_FAIL)
  test_effect.c:1814: Test failed: Got result 0, expected 0x80004005 
(E_FAIL)
  test_effect.c:1881: Test failed: Got result 0, expected 0x80004005 
(E_FAIL)
3. If the function just sets the memory with the data for a bool then
   test_effect.c:969: Test failed: Got 46, expected 1
4. The errors reported on checking for element are corrected by changing 
to param->bytes <=bytes as you suggested.
5. Concerning textures, the compiler does not accept arrays of textures, 
so any change to a texture type should be just a change of the pointer 
to the texture at param->data (or NULL)



El 06/02/12 19:51, Rico Schüller escribió:
> Am 06.02.2012 18:23, schrieb Luis Carlos Busquets Pérez:
>> The functin returns D3DERR_INVALIDCALL whenever it is tried on a
>> parameter with elements. A check should be included.
> Why do you think this is the case? How did you test this? I think it's 
> not possible to query the ID3DXBaseEffect interface (see 
> http://source.winehq.org/git/wine.git/blob/HEAD:/dlls/d3dx9_36/tests/effect.c#l161 
> ). Beside that, please have a look at 
> http://source.winehq.org/git/wine.git/blob/HEAD:/dlls/d3dx9_36/tests/effect.c#l1585 
> , which calls ID3DXBaseEffect::SetValue through ID3DXEffect. There it 
> doesn't return D3DERR_INVALIDCALL for D3DXPC_SCALAR, D3DXPC_VECTOR, 
> D3DXPC_MATRIX_ROWS and Elements > 0. This should be tested by e.g. 
> http://source.winehq.org/git/wine.git/blob/HEAD:/dlls/d3dx9_36/tests/effect.c#l754 
> . Could you please a be a bit more specific, where the 
> D3DERR_INVALIDCALL is returned? Maybe on e.g. D3DXPT_PIXELSHADER, 
> which isn't implemented in wine, yet?
>
> Cheers
> Rico

-------------- next part --------------
A non-text attachment was scrubbed...
Name: wine_effect.fxo
Type: application/x-extension-fxo
Size: 22883 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20120207/35381c74/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: wine_effect.fx
Type: application/octet-stream
Size: 75728 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20120207/35381c74/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test_effect.c
Type: text/x-csrc
Size: 150720 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20120207/35381c74/attachment-0001.c>


More information about the wine-devel mailing list