d3dx9: Implement converting and copying surface data in D3DXLoadSurfaceFromMemory (review please)

Tony Wasserka tony.wasserka at freenet.de
Mon Aug 31 04:35:17 CDT 2009

> You are right, but it would be neat to have them all grouped like they
> are in d3dx9tex.h.
Not sure about that, assuming we ever support all possible filters and
conversions in D3DXLoadSurfaceFromMemory, we probably don't want to have
the texture stuff starting suddenly at line 3k or something... We won't
be able to put the ID3DXBaseMesh, ID3DXMesh, ID3DXPatchMesh, ID3DXPMesh
and ID3DXSPMesh interface implementations in one file either.

> I seem to remember one additional thing from the MSDN:  The alpha
> channel has a specific behavior when it is added (RGB -> RGBA), it is
> set to either 0.0 or 1.0.  1.0 makes sense.  I think other channels
> are set to 0.0 if they are added.
> Better test this though.
According to
http://msdn.microsoft.com/en-us/library/bb206254%28VS.85%29.aspx (and to
my tests),  new channels are set to their maximum value with the
exception of A8, which was not yet handled in my patch but will be
trivial to add in the new version.

More information about the wine-devel mailing list