Re: GSoC-2011: Implement Missing Mesh Functions in Wine’s D3DX9

Stefan Dösinger stefandoesinger at gmx.at
Thu May 26 16:12:08 CDT 2011


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


Am 26.05.2011 um 16:27 schrieb Michael Mc Donnell:
> Yeah I'd prefer it too to be 100% compatible. However, I think it is
> highly unlikely that any programs depend on an exception being thrown
> by EndScene in a drawing method.
What EndScene method is this? The device's methods? I'd be surprised if this method crashed.

> But you never know, some people do
> crazy things :-) I think the current implementation is good enough as
> long as there is no evidence of programs depending on that behavior.
> 
> The problem is that UpdateSemantics in the d3dx9 library depends on
> d3d9 and the error code is generated by vertexdeclaration_init in
> d3d9.
Do the d3d9 vertexdeclaration tests pass on this Windows machine?

> I thought of managing an array of D3DVERTEXELEMENT9 in ID3DXMeshImpl
> instead of a IDirect3DVertexDeclaration9, and then have
> ID3DXMeshImpl_DrawSubset call IDirect3DDevice9_CreateVertexDeclaration
> just before IDirect3DDevice9_SetVertexDeclaration.
I suspect that this is what native does. This also fits the API design because UpdateSemantics accepts a D3DVERTEXELEMENT9 array and GetDeclaration returns a D3DVERTEXELEMENT9 array. Why did MS name those functions UpdateSemantics and GetDeclaration???

I don't think you'd have extra d3d9 calls by delaying the vdecl creation. Of course you have to keep the vdecl until the next UpdateSemantic call and not recreate it every time you draw.


-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)

iQIbBAEBAgAGBQJN3sIsAAoJEN0/YqbEcdMwIjwP+IxUGwlGAFCtgrJBuiVc9p6u
wEeG7eK412dCjQBtgjwab4SI4XEZ8+Si555ZtorcVE2LV7jhTmzpEj32VPJYuKKo
asmaNmDk9X45aR9kn7/3lwX9alI0mqwFmyB4pp7C9yr9IHhPBE8+6AAspXjgBKgw
QIU1yluABO2OvEsFFjEXW5jPG1PTcMoB496iOX/1bDKlm6JjcCYtlv+6jKda2fMm
xBe7xTAds4whdIBQ0xbsbcWQoSTLYmRrtkyiHXolKV3IRDtKlc4FHzOkCn3CURz7
gH7z+Z4Oj5HiY42smOAgJtifCD/mwszWj7bTKtxsG4fE2rnWHu/D/8g6oi4dzufp
RpWE7uMxYwGirpgcMTIESkocyfj0LHOUzcanBhHnAxdeiNYrit8G9zaF+I58YASC
JBBQtWXSTOzgZ0R8G2GcVXOcrTg2bQpsZ8nd5mJVOGQAPj16cRRgBc8iJfTlUZqY
S9NAzkqBQly+8cGlTxKi7pWKBcJR64T+/KoLlN3VzoannwkBvvF5nk4uB9WvIgEO
+OLmZI3+5bbWBbfHhc7hWs7MYcT0pnZoePRCFjmaKeV6r+z+6XZAUWKCNDhbukXJ
Sna+YSaLo47RFnNL2P1zYC8gQ3ohhHKfJbZDJ6DX+bBKsRh45OFA6H0RlYVRRkAP
8GKf5K/pnG+FBaWEIYE=
=QHcz
-----END PGP SIGNATURE-----



More information about the wine-devel mailing list