[D3DX9_*] Sync with Wine Staging 1.7.37. CORE-9246

svn path=/trunk/; revision=66490
This commit is contained in:
Amine Khaldi 2015-02-28 11:17:10 +00:00
parent b77d71098d
commit 5b09d5a99c
35 changed files with 1378 additions and 134 deletions

View file

@ -22,7 +22,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -72,7 +72,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -116,7 +116,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -22,7 +22,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -72,7 +72,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -116,7 +116,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -75,7 +75,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -119,7 +119,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -75,7 +75,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -119,7 +119,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -75,7 +75,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -119,7 +119,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -75,7 +75,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -119,7 +119,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -75,7 +75,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -119,7 +119,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -4,6 +4,7 @@ include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine)
spec2def(d3dx9_36.dll d3dx9_36.spec ADD_IMPORTLIB)
list(APPEND SOURCE
animation.c
core.c
d3dx9_36_main.c
effect.c
@ -37,6 +38,6 @@ if(CMAKE_C_COMPILER_ID STREQUAL "Clang")
target_link_libraries(d3dx9_36 mingwex)
endif()
add_importlibs(d3dx9_36 d3dcompiler_43 d3dxof user32 ole32 gdi32 msvcrt kernel32 ntdll)
add_importlibs(d3dx9_36 d3dcompiler_43 d3dxof d3dwine user32 ole32 gdi32 msvcrt kernel32 ntdll)
add_pch(d3dx9_36 d3dx9_36_private.h SOURCE)
add_cd_file(TARGET d3dx9_36 DESTINATION reactos/system32 FOR all)

View file

@ -0,0 +1,452 @@
/*
* Animation Controller operations specific to D3DX9.
*
* Copyright (C) 2015 Christian Costa
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include "d3dx9_36_private.h"
struct d3dx9_animation_controller
{
ID3DXAnimationController ID3DXAnimationController_iface;
LONG ref;
};
static inline struct d3dx9_animation_controller *impl_from_ID3DXAnimationController(ID3DXAnimationController *iface)
{
return CONTAINING_RECORD(iface, struct d3dx9_animation_controller, ID3DXAnimationController_iface);
}
static HRESULT WINAPI d3dx9_animation_controller_QueryInterface(ID3DXAnimationController *iface, REFIID riid, void **out)
{
TRACE("iface %p, riid %s, out %p.\n", iface, debugstr_guid(riid), out);
if (IsEqualGUID(riid, &IID_IUnknown) || IsEqualGUID(riid, &IID_ID3DXAnimationController))
{
IUnknown_AddRef(iface);
*out = iface;
return D3D_OK;
}
WARN("%s not implemented, returning E_NOINTERFACE\n", debugstr_guid(riid));
*out = NULL;
return E_NOINTERFACE;
}
static ULONG WINAPI d3dx9_animation_controller_AddRef(ID3DXAnimationController *iface)
{
struct d3dx9_animation_controller *animation = impl_from_ID3DXAnimationController(iface);
ULONG refcount = InterlockedIncrement(&animation->ref);
TRACE("%p increasing refcount to %u.\n", animation, refcount);
return refcount;
}
static ULONG WINAPI d3dx9_animation_controller_Release(ID3DXAnimationController *iface)
{
struct d3dx9_animation_controller *animation = impl_from_ID3DXAnimationController(iface);
ULONG refcount = InterlockedDecrement(&animation->ref);
TRACE("%p decreasing refcount to %u.\n", animation, refcount);
if (!refcount)
{
HeapFree(GetProcessHeap(), 0, animation);
}
return refcount;
}
static UINT WINAPI d3dx9_animation_controller_GetMaxNumAnimationOutputs(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return 0;
}
static UINT WINAPI d3dx9_animation_controller_GetMaxNumAnimationSets(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return 0;
}
static UINT WINAPI d3dx9_animation_controller_GetMaxNumTracks(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return 0;
}
static UINT WINAPI d3dx9_animation_controller_GetMaxNumEvents(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return 0;
}
static HRESULT WINAPI d3dx9_animation_controller_RegisterAnimationOutput(ID3DXAnimationController *iface,
const char *name, D3DXMATRIX *matrix, D3DXVECTOR3 *scale, D3DXQUATERNION *rotation, D3DXVECTOR3 *translation)
{
FIXME("iface %p, name %s, matrix %p, scale %p, rotation %p, translation %p stub.\n", iface, wine_dbgstr_a(name),
matrix, scale, rotation, translation);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_RegisterAnimationSet(ID3DXAnimationController *iface,
ID3DXAnimationSet *anim_set)
{
FIXME("iface %p, anim_set %p stub.\n", iface, anim_set);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_UnregisterAnimationSet(ID3DXAnimationController *iface,
ID3DXAnimationSet *anim_set)
{
FIXME("iface %p, anim_set %p stub.\n", iface, anim_set);
return E_NOTIMPL;
}
static UINT WINAPI d3dx9_animation_controller_GetNumAnimationSets(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return 0;
}
static HRESULT WINAPI d3dx9_animation_controller_GetAnimationSet(ID3DXAnimationController *iface,
UINT index, ID3DXAnimationSet **anim_set)
{
FIXME("iface %p, index %u, anim_set %p stub.\n", iface, index, anim_set);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_GetAnimationSetByName(ID3DXAnimationController *iface,
const char *name, ID3DXAnimationSet **anim_set)
{
FIXME("iface %p, name %s, anim_set %p stub.\n", iface, wine_dbgstr_a(name), anim_set);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_AdvanceTime(ID3DXAnimationController *iface, DOUBLE time_delta,
ID3DXAnimationCallbackHandler **callback_handler)
{
FIXME("iface %p, time_delta %g, callback_handler %p stub.\n", iface, time_delta, callback_handler);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_Reset(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return E_NOTIMPL;
}
static DOUBLE WINAPI d3dx9_animation_controller_GetTime(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return 0.0;
}
static HRESULT WINAPI d3dx9_animation_controller_SetTrackAnimationSet(ID3DXAnimationController *iface,
UINT track, ID3DXAnimationSet *anim_set)
{
FIXME("iface %p, track %u, anim_set %p stub.\n", iface, track, anim_set);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_GetTrackAnimationSet(ID3DXAnimationController *iface,
UINT track, ID3DXAnimationSet **anim_set)
{
FIXME("iface %p, track %u, anim_set %p stub.\n", iface, track, anim_set);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_GetTrackPriority(ID3DXAnimationController *iface,
UINT track, D3DXPRIORITY_TYPE *priority)
{
FIXME("iface %p, track %u, priority %p stub.\n", iface, track, priority);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_SetTrackSpeed(ID3DXAnimationController *iface,
UINT track, FLOAT speed)
{
FIXME("iface %p, track %u, speed %f stub.\n", iface, track, speed);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_SetTrackWeight(ID3DXAnimationController *iface,
UINT track, FLOAT weight)
{
FIXME("iface %p, track %u, weight %f stub.\n", iface, track, weight);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_SetTrackPosition(ID3DXAnimationController *iface,
UINT track, DOUBLE position)
{
FIXME("iface %p, track %u, position %g stub.\n", iface, track, position);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_SetTrackEnable(ID3DXAnimationController *iface,
UINT track, BOOL enable)
{
FIXME("iface %p, track %u, enable %u stub.\n", iface, track, enable);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_SetTrackDesc(ID3DXAnimationController *iface,
UINT track, D3DXTRACK_DESC *desc)
{
FIXME("iface %p, track %u, desc %p stub.\n", iface, track, desc);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_GetTrackDesc(ID3DXAnimationController *iface,
UINT track, D3DXTRACK_DESC *desc)
{
FIXME("iface %p, track %u, desc %p stub.\n", iface, track, desc);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_SetPriorityBlend(ID3DXAnimationController *iface,
FLOAT blend_weight)
{
FIXME("iface %p, blend_weight %f stub.\n", iface, blend_weight);
return E_NOTIMPL;
}
static FLOAT WINAPI d3dx9_animation_controller_GetPriorityBlend(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return 0.0;
}
static D3DXEVENTHANDLE WINAPI d3dx9_animation_controller_KeyTrackSpeed(ID3DXAnimationController *iface,
UINT track, FLOAT new_speed, DOUBLE start_time, DOUBLE duration, D3DXTRANSITION_TYPE transition)
{
FIXME("iface %p, track %u, new_speed %f, start_time %g, duration %g, transition %u stub.\n", iface,
track, new_speed, start_time, duration, transition);
return 0;
}
static D3DXEVENTHANDLE WINAPI d3dx9_animation_controller_KeyTrackWeight(ID3DXAnimationController *iface,
UINT track, FLOAT new_weight, DOUBLE start_time, DOUBLE duration, D3DXTRANSITION_TYPE transition)
{
FIXME("iface %p, track %u, new_weight %f, start_time %g, duration %g, transition %u stub.\n", iface,
track, new_weight, start_time, duration, transition);
return 0;
}
static D3DXEVENTHANDLE WINAPI d3dx9_animation_controller_KeyTrackPosition(ID3DXAnimationController *iface,
UINT track, DOUBLE new_position, DOUBLE start_time)
{
FIXME("iface %p, track %u, new_position %g, start_time %g stub.\n", iface,
track, new_position, start_time);
return 0;
}
static D3DXEVENTHANDLE WINAPI d3dx9_animation_controller_KeyTrackEnable(ID3DXAnimationController *iface,
UINT track, BOOL new_enable, DOUBLE start_time)
{
FIXME("iface %p, track %u, new_enable %u, start_time %g stub.\n", iface,
track, new_enable, start_time);
return 0;
}
static D3DXEVENTHANDLE WINAPI d3dx9_animation_controller_KeyTrackBlend(ID3DXAnimationController *iface,
FLOAT new_blend_weight, DOUBLE start_time, DOUBLE duration, D3DXTRANSITION_TYPE transition)
{
FIXME("iface %p, new_blend_weight %f, start_time %g, duration %g, transition %u stub.\n", iface,
new_blend_weight, start_time, duration, transition);
return 0;
}
static HRESULT WINAPI d3dx9_animation_controller_UnkeyEvent(ID3DXAnimationController *iface, D3DXEVENTHANDLE event)
{
FIXME("iface %p, event %u stub.\n", iface, event);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_UnkeyAllTrackEvents(ID3DXAnimationController *iface, UINT track)
{
FIXME("iface %p, track %u stub.\n", iface, track);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_UnkeyAllPriorityBlends(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return E_NOTIMPL;
}
static D3DXEVENTHANDLE WINAPI d3dx9_animation_controller_GetCurrentTrackEvent(ID3DXAnimationController *iface,
UINT track, D3DXEVENT_TYPE event_type)
{
FIXME("iface %p, track %u, event_type %u stub.\n", iface, track, event_type);
return 0;
}
static D3DXEVENTHANDLE WINAPI d3dx9_animation_controller_GetCurrentPriorityBlend(ID3DXAnimationController *iface)
{
FIXME("iface %p stub.\n", iface);
return 0;
}
static D3DXEVENTHANDLE WINAPI d3dx9_animation_controller_GetUpcomingTrackEvent(ID3DXAnimationController *iface,
UINT track, D3DXEVENTHANDLE event)
{
FIXME("iface %p, track %u, event %u stub.\n", iface, track, event);
return 0;
}
static D3DXEVENTHANDLE WINAPI d3dx9_animation_controller_GetUpcomingPriorityBlend(ID3DXAnimationController *iface,
D3DXEVENTHANDLE handle)
{
FIXME("iface %p, handle %u stub.\n", iface, handle);
return 0;
}
static HRESULT WINAPI d3dx9_animation_controller_ValidateEvent(ID3DXAnimationController *iface, D3DXEVENTHANDLE event)
{
FIXME("iface %p, event %u stub.\n", iface, event);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_GetEventDesc(ID3DXAnimationController *iface,
D3DXEVENTHANDLE event, D3DXEVENT_DESC *desc)
{
FIXME("iface %p, event %u, desc %p stub.\n", iface, event, desc);
return E_NOTIMPL;
}
static HRESULT WINAPI d3dx9_animation_controller_CloneAnimationController(ID3DXAnimationController *iface, UINT max_num_anim_outputs,
UINT max_num_anim_sets, UINT max_num_tracks, UINT max_num_events, ID3DXAnimationController **anim_controller)
{
FIXME("iface %p, max_num_anim_outputs %u, max_num_anim_sets %u, max_num_tracks %u, max_num_events %u, anim_controller %p stub.\n",
iface, max_num_anim_outputs, max_num_anim_sets, max_num_tracks, max_num_events, anim_controller);
return E_NOTIMPL;
}
static const struct ID3DXAnimationControllerVtbl d3dx9_animation_controller_vtbl =
{
d3dx9_animation_controller_QueryInterface,
d3dx9_animation_controller_AddRef,
d3dx9_animation_controller_Release,
d3dx9_animation_controller_GetMaxNumAnimationOutputs,
d3dx9_animation_controller_GetMaxNumAnimationSets,
d3dx9_animation_controller_GetMaxNumTracks,
d3dx9_animation_controller_GetMaxNumEvents,
d3dx9_animation_controller_RegisterAnimationOutput,
d3dx9_animation_controller_RegisterAnimationSet,
d3dx9_animation_controller_UnregisterAnimationSet,
d3dx9_animation_controller_GetNumAnimationSets,
d3dx9_animation_controller_GetAnimationSet,
d3dx9_animation_controller_GetAnimationSetByName,
d3dx9_animation_controller_AdvanceTime,
d3dx9_animation_controller_Reset,
d3dx9_animation_controller_GetTime,
d3dx9_animation_controller_SetTrackAnimationSet,
d3dx9_animation_controller_GetTrackAnimationSet,
d3dx9_animation_controller_GetTrackPriority,
d3dx9_animation_controller_SetTrackSpeed,
d3dx9_animation_controller_SetTrackWeight,
d3dx9_animation_controller_SetTrackPosition,
d3dx9_animation_controller_SetTrackEnable,
d3dx9_animation_controller_SetTrackDesc,
d3dx9_animation_controller_GetTrackDesc,
d3dx9_animation_controller_SetPriorityBlend,
d3dx9_animation_controller_GetPriorityBlend,
d3dx9_animation_controller_KeyTrackSpeed,
d3dx9_animation_controller_KeyTrackWeight,
d3dx9_animation_controller_KeyTrackPosition,
d3dx9_animation_controller_KeyTrackEnable,
d3dx9_animation_controller_KeyTrackBlend,
d3dx9_animation_controller_UnkeyEvent,
d3dx9_animation_controller_UnkeyAllTrackEvents,
d3dx9_animation_controller_UnkeyAllPriorityBlends,
d3dx9_animation_controller_GetCurrentTrackEvent,
d3dx9_animation_controller_GetCurrentPriorityBlend,
d3dx9_animation_controller_GetUpcomingTrackEvent,
d3dx9_animation_controller_GetUpcomingPriorityBlend,
d3dx9_animation_controller_ValidateEvent,
d3dx9_animation_controller_GetEventDesc,
d3dx9_animation_controller_CloneAnimationController
};
/***********************************************************************
* D3DXCreateAnimationController (D3DX9_36.@)
*/
HRESULT WINAPI D3DXCreateAnimationController(UINT MaxNumAnimationOutputs, UINT MaxNumAnimationSets,
UINT MaxNumTracks, UINT MaxNumEvents, ID3DXAnimationController **AnimationController)
{
struct d3dx9_animation_controller* object;
TRACE("MaxNumAnimationOutputs %u, MaxNumAnimationSets %u, MaxNumTracks %u, MaxNumEvents %u, AnimationController %p.\n",
MaxNumAnimationOutputs, MaxNumAnimationSets, MaxNumTracks, MaxNumEvents, AnimationController);
if (!AnimationController)
return D3DERR_INVALIDCALL;
object = HeapAlloc(GetProcessHeap(), 0, sizeof(*object));
if (!object)
return E_OUTOFMEMORY;
object->ID3DXAnimationController_iface.lpVtbl = &d3dx9_animation_controller_vtbl;
object->ref = 1;
*AnimationController = &object->ID3DXAnimationController_iface;
return D3D_OK;
}

View file

@ -22,15 +22,15 @@
@ stdcall -stub D3DXComputeIMTFromPerTexelSignal(ptr long ptr long long long long long ptr ptr ptr)
@ stdcall -stub D3DXComputeIMTFromSignal(ptr long long long long ptr ptr ptr ptr ptr)
@ stdcall -stub D3DXComputeIMTFromTexture(ptr ptr long long ptr ptr ptr)
@ stdcall -stub D3DXComputeNormalMap(ptr ptr ptr long long long)
@ stdcall -stub D3DXComputeNormals(ptr ptr)
@ stdcall D3DXComputeNormalMap(ptr ptr ptr long long long)
@ stdcall D3DXComputeNormals(ptr ptr)
@ stdcall -stub D3DXComputeTangent(ptr long long long long ptr)
@ stdcall -stub D3DXComputeTangentFrame(ptr long)
@ stdcall -stub D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr)
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr)
@ stdcall -stub D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr)
@ stdcall -stub D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr)
@ stdcall -stub D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr)
@ stdcall -stub D3DXCreateAnimationController(long long long long ptr)
@ stdcall D3DXCreateAnimationController(long long long long ptr)
@ stdcall D3DXCreateBox(ptr float float float ptr ptr)
@ stdcall D3DXCreateBuffer(long ptr)
@ stdcall -stub D3DXCreateCompressedAnimationSet(ptr long long ptr long ptr ptr)
@ -76,7 +76,7 @@
@ stdcall -stub D3DXCreateNPatchMesh(ptr ptr)
@ stdcall -stub D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr)
@ stdcall -stub D3DXCreatePatchMesh(ptr long long long ptr ptr ptr)
@ stdcall -stub D3DXCreatePolygon(ptr long long ptr ptr)
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr)
@ stdcall -stub D3DXCreatePRTBuffer(long long long ptr)
@ stdcall -stub D3DXCreatePRTBufferTex(long long long long ptr)
@ stdcall -stub D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr)
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long)
@ stdcall D3DXDeclaratorFromFVF(long ptr)
@ stdcall D3DXDisassembleEffect(ptr long ptr)
@ stdcall -stub D3DXDisassembleShader(ptr long ptr ptr)
@ stdcall D3DXDisassembleShader(ptr long str ptr)
@ stdcall D3DXFileCreate(ptr)
@ stdcall D3DXFillCubeTexture(ptr ptr ptr)
@ stdcall -stub D3DXFillCubeTextureTX(ptr ptr)
@ -159,13 +159,13 @@
@ stdcall D3DXGetPixelShaderProfile(ptr)
@ stdcall D3DXGetShaderConstantTable(ptr ptr)
@ stdcall D3DXGetShaderConstantTableEx(ptr long ptr)
@ stdcall -stub D3DXGetShaderInputSemantics(ptr ptr ptr)
@ stdcall -stub D3DXGetShaderOutputSemantics(ptr ptr ptr)
@ stdcall D3DXGetShaderInputSemantics(ptr ptr ptr)
@ stdcall D3DXGetShaderOutputSemantics(ptr ptr ptr)
@ stdcall D3DXGetShaderSamplers(ptr ptr ptr)
@ stdcall D3DXGetShaderSize(ptr)
@ stdcall D3DXGetShaderVersion(ptr)
@ stdcall D3DXGetVertexShaderProfile(ptr)
@ stdcall -stub D3DXIntersect(ptr ptr ptr ptr ptr ptr ptr ptr ptr ptr)
@ stdcall D3DXIntersect(ptr ptr ptr ptr ptr ptr ptr ptr ptr ptr)
@ stdcall -stub D3DXIntersectSubset(ptr long ptr ptr ptr ptr ptr ptr ptr ptr ptr)
@ stdcall D3DXIntersectTri(ptr ptr ptr ptr ptr ptr ptr ptr)
@ stdcall D3DXLoadMeshFromXA(str long ptr ptr ptr ptr ptr ptr)

View file

@ -113,6 +113,8 @@ HRESULT load_volume_from_dds(IDirect3DVolume9 *dst_volume, const PALETTEENTRY *d
const D3DXIMAGE_INFO *src_info) DECLSPEC_HIDDEN;
HRESULT load_volume_texture_from_dds(IDirect3DVolumeTexture9 *volume_texture, const void *src_data,
const PALETTEENTRY *palette, DWORD filter, DWORD color_key, const D3DXIMAGE_INFO *src_info) DECLSPEC_HIDDEN;
HRESULT save_dds_texture_to_memory(ID3DXBuffer **dst_buffer, IDirect3DBaseTexture9 *src_texture,
const PALETTEENTRY *src_palette) DECLSPEC_HIDDEN;
unsigned short float_32_to_16(const float in) DECLSPEC_HIDDEN;
float float_16_to_32(const unsigned short in) DECLSPEC_HIDDEN;

View file

@ -3113,13 +3113,41 @@ static HRESULT WINAPI ID3DXEffectImpl_ValidateTechnique(ID3DXEffect* iface, D3DX
return D3D_OK;
}
static HRESULT WINAPI ID3DXEffectImpl_FindNextValidTechnique(ID3DXEffect* iface, D3DXHANDLE technique, D3DXHANDLE* next_technique)
static HRESULT WINAPI ID3DXEffectImpl_FindNextValidTechnique(ID3DXEffect *iface,
D3DXHANDLE technique, D3DXHANDLE *next_technique)
{
struct ID3DXEffectImpl *This = impl_from_ID3DXEffect(iface);
struct d3dx9_base_effect *base_effect = &This->base_effect;
UINT i = 0;
FIXME("(%p)->(%p, %p): stub\n", This, technique, next_technique);
TRACE("iface %p, technique %p, next_technique %p\n", iface, technique, next_technique);
return E_NOTIMPL;
if (!next_technique)
return D3DERR_INVALIDCALL;
if (technique)
{
for (; i < base_effect->technique_count; i++)
{
if (technique == get_technique_handle(&base_effect->techniques[i]))
{
i++; /* Go to next technique */
break;
}
}
}
for (; i < base_effect->technique_count; i++)
{
if (SUCCEEDED(iface->lpVtbl->ValidateTechnique(iface, get_technique_handle(&base_effect->techniques[i]))))
{
*next_technique = get_technique_handle(&base_effect->techniques[i]);
return D3D_OK;
}
}
*next_technique = NULL;
return S_FALSE;
}
static BOOL WINAPI ID3DXEffectImpl_IsParameterUsed(ID3DXEffect* iface, D3DXHANDLE parameter, D3DXHANDLE technique)

View file

@ -29,8 +29,29 @@ struct d3dx_font
HDC hdc;
HFONT hfont;
UINT tex_width;
UINT tex_height;
IDirect3DTexture9 *texture;
HBITMAP bitmap;
BYTE *bits;
};
/* Returns the smallest power of 2 which is greater than or equal to num */
static UINT make_pow2(UINT num)
{
UINT result = 1;
/* In the unlikely event somebody passes a large value, make sure we don't enter an infinite loop */
if (num >= 0x80000000)
return 0x80000000;
while (result < num)
result <<= 1;
return result;
}
static inline struct d3dx_font *impl_from_ID3DXFont(ID3DXFont *iface)
{
return CONTAINING_RECORD(iface, struct d3dx_font, ID3DXFont_iface);
@ -57,19 +78,27 @@ static HRESULT WINAPI ID3DXFontImpl_QueryInterface(ID3DXFont *iface, REFIID riid
static ULONG WINAPI ID3DXFontImpl_AddRef(ID3DXFont *iface)
{
struct d3dx_font *This = impl_from_ID3DXFont(iface);
ULONG ref=InterlockedIncrement(&This->ref);
ULONG ref = InterlockedIncrement(&This->ref);
TRACE("%p increasing refcount to %u\n", iface, ref);
return ref;
}
static ULONG WINAPI ID3DXFontImpl_Release(ID3DXFont *iface)
{
struct d3dx_font *This = impl_from_ID3DXFont(iface);
ULONG ref=InterlockedDecrement(&This->ref);
ULONG ref = InterlockedDecrement(&This->ref);
TRACE("%p decreasing refcount to %u\n", iface, ref);
if(ref==0) {
if (!ref)
{
if (This->texture)
{
IDirect3DTexture9_Release(This->texture);
DeleteObject(This->bitmap);
}
DeleteObject(This->hfont);
DeleteDC(This->hdc);
IDirect3DDevice9_Release(This->device);
@ -148,7 +177,7 @@ static HRESULT WINAPI ID3DXFontImpl_GetGlyphData(ID3DXFont *iface, UINT glyph,
static HRESULT WINAPI ID3DXFontImpl_PreloadCharacters(ID3DXFont *iface, UINT first, UINT last)
{
FIXME("iface %p, first %u, last %u stub!\n", iface, first, last);
return E_NOTIMPL;
return S_OK;
}
static HRESULT WINAPI ID3DXFontImpl_PreloadGlyphs(ID3DXFont *iface, UINT first, UINT last)
@ -172,17 +201,177 @@ static HRESULT WINAPI ID3DXFontImpl_PreloadTextW(ID3DXFont *iface, const WCHAR *
static INT WINAPI ID3DXFontImpl_DrawTextA(ID3DXFont *iface, ID3DXSprite *sprite,
const char *string, INT count, RECT *rect, DWORD format, D3DCOLOR color)
{
FIXME("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x stub!\n",
LPWSTR stringW;
INT countW, ret = 0;
TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
iface, sprite, debugstr_a(string), count, wine_dbgstr_rect(rect), format, color);
return 1;
if (!string || !count)
return 0;
countW = MultiByteToWideChar(CP_ACP, 0, string, count, NULL, 0);
stringW = HeapAlloc(GetProcessHeap(), 0, countW * sizeof(WCHAR));
if (stringW)
{
MultiByteToWideChar(CP_ACP, 0, string, count, stringW, countW);
ret = ID3DXFont_DrawTextW(iface, sprite, stringW, countW, rect, format, color);
HeapFree(GetProcessHeap(), 0, stringW);
}
return ret;
}
static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
const WCHAR *string, INT count, RECT *rect, DWORD format, D3DCOLOR color)
{
FIXME("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x stub!\n",
struct d3dx_font *This = impl_from_ID3DXFont(iface);
RECT calc_rect = *rect;
INT height;
TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
iface, sprite, debugstr_w(string), count, wine_dbgstr_rect(rect), format, color);
return 1;
if (!string || !count)
return 0;
/* Strip terminating NULL characters */
while (count > 0 && !string[count-1])
count--;
height = DrawTextW(This->hdc, string, count, &calc_rect, format | DT_CALCRECT);
if (format & DT_CALCRECT)
{
*rect = calc_rect;
return height;
}
if (format & DT_CENTER)
{
UINT new_width = calc_rect.right - calc_rect.left;
calc_rect.left = (rect->right + rect->left - new_width) / 2;
calc_rect.right = calc_rect.left + new_width;
}
if (height && (calc_rect.left < calc_rect.right))
{
D3DLOCKED_RECT locked_rect;
D3DXVECTOR3 position;
UINT text_width, text_height;
RECT text_rect;
ID3DXSprite *target = sprite;
HRESULT hr;
int i, j;
/* Get rect position and dimensions */
position.x = calc_rect.left;
position.y = calc_rect.top;
position.z = 0;
text_width = calc_rect.right - calc_rect.left;
text_height = calc_rect.bottom - calc_rect.top;
text_rect.left = 0;
text_rect.top = 0;
text_rect.right = text_width;
text_rect.bottom = text_height;
/* We need to flush as it seems all draws in the begin/end sequence use only the latest updated texture */
if (sprite)
ID3DXSprite_Flush(sprite);
/* Extend texture and DIB section to contain text */
if ((text_width > This->tex_width) || (text_height > This->tex_height))
{
BITMAPINFOHEADER header;
if (text_width > This->tex_width)
This->tex_width = make_pow2(text_width);
if (text_height > This->tex_height)
This->tex_height = make_pow2(text_height);
if (This->texture)
{
IDirect3DTexture9_Release(This->texture);
DeleteObject(This->bitmap);
}
hr = D3DXCreateTexture(This->device, This->tex_width, This->tex_height, 1, 0,
D3DFMT_A8R8G8B8, D3DPOOL_DEFAULT, &This->texture);
if (FAILED(hr))
{
This->texture = NULL;
return 0;
}
header.biSize = sizeof(header);
header.biWidth = This->tex_width;
header.biHeight = -This->tex_height;
header.biPlanes = 1;
header.biBitCount = 32;
header.biCompression = BI_RGB;
header.biSizeImage = sizeof(DWORD) * This->tex_width * This->tex_height;
header.biXPelsPerMeter = 0;
header.biYPelsPerMeter = 0;
header.biClrUsed = 0;
header.biClrImportant = 0;
This->bitmap = CreateDIBSection(This->hdc, (const BITMAPINFO*)&header,
DIB_RGB_COLORS, (void**)&This->bits, NULL, 0);
if (!This->bitmap)
{
IDirect3DTexture9_Release(This->texture);
This->texture = NULL;
return 0;
}
SelectObject(This->hdc, This->bitmap);
}
if (FAILED(IDirect3DTexture9_LockRect(This->texture, 0, &locked_rect, &text_rect, D3DLOCK_DISCARD)))
return 0;
/* Clear rect */
for (i = 0; i < text_height; i++)
memset(This->bits + i * This->tex_width * sizeof(DWORD), 0,
text_width * sizeof(DWORD));
DrawTextW(This->hdc, string, count, &text_rect, format);
/* All RGB components are equal so take one as alpha and set RGB
* color to white, so it can be modulated with color parameter */
for (i = 0; i < text_height; i++)
{
DWORD *src = (DWORD *)This->bits + i * This->tex_width;
DWORD *dst = (DWORD *)((BYTE *)locked_rect.pBits + i * locked_rect.Pitch);
for (j = 0; j < text_width; j++)
{
*dst++ = (*src++ << 24) | 0xFFFFFF;
}
}
IDirect3DTexture9_UnlockRect(This->texture, 0);
if (!sprite)
{
hr = D3DXCreateSprite(This->device, &target);
if (FAILED(hr))
return 0;
ID3DXSprite_Begin(target, 0);
}
hr = target->lpVtbl->Draw(target, This->texture, &text_rect, NULL, &position, color);
if (!sprite)
{
ID3DXSprite_End(target);
ID3DXSprite_Release(target);
}
if (FAILED(hr))
return 0;
}
return height;
}
static HRESULT WINAPI ID3DXFontImpl_OnLostDevice(ID3DXFont *iface)
@ -296,46 +485,55 @@ HRESULT WINAPI D3DXCreateFontIndirectW(IDirect3DDevice9 *device, const D3DXFONT_
TRACE("(%p, %p, %p)\n", device, desc, font);
if( !device || !desc || !font ) return D3DERR_INVALIDCALL;
if (!device || !desc || !font) return D3DERR_INVALIDCALL;
/* the device MUST support D3DFMT_A8R8G8B8 */
TRACE("desc: %d %d %d %d %d %d %d %d %d %s\n", desc->Height, desc->Width, desc->Weight, desc->MipLevels, desc->Italic,
desc->CharSet, desc->OutputPrecision, desc->Quality, desc->PitchAndFamily, debugstr_w(desc->FaceName));
/* The device MUST support D3DFMT_A8R8G8B8 */
IDirect3DDevice9_GetDirect3D(device, &d3d);
IDirect3DDevice9_GetCreationParameters(device, &cpars);
IDirect3DDevice9_GetDisplayMode(device, 0, &mode);
hr = IDirect3D9_CheckDeviceFormat(d3d, cpars.AdapterOrdinal, cpars.DeviceType, mode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_A8R8G8B8);
if(FAILED(hr)) {
if (FAILED(hr))
{
IDirect3D9_Release(d3d);
return D3DXERR_INVALIDDATA;
}
IDirect3D9_Release(d3d);
object = HeapAlloc(GetProcessHeap(), 0, sizeof(struct d3dx_font));
if(object==NULL) {
*font=NULL;
object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct d3dx_font));
if (!object)
{
*font = NULL;
return E_OUTOFMEMORY;
}
object->ID3DXFont_iface.lpVtbl = &D3DXFont_Vtbl;
object->ref=1;
object->device=device;
object->desc=*desc;
object->ref = 1;
object->device = device;
object->desc = *desc;
object->hdc = CreateCompatibleDC(NULL);
if( !object->hdc ) {
if (!object->hdc)
{
HeapFree(GetProcessHeap(), 0, object);
return D3DXERR_INVALIDDATA;
}
object->hfont = CreateFontW(desc->Height, desc->Width, 0, 0, desc->Weight, desc->Italic, FALSE, FALSE, desc->CharSet,
desc->OutputPrecision, CLIP_DEFAULT_PRECIS, desc->Quality, desc->PitchAndFamily, desc->FaceName);
if( !object->hfont ) {
if (!object->hfont)
{
DeleteDC(object->hdc);
HeapFree(GetProcessHeap(), 0, object);
return D3DXERR_INVALIDDATA;
}
SelectObject(object->hdc, object->hfont);
SetTextColor(object->hdc, 0x00ffffff);
SetBkColor(object->hdc, 0x00000000);
IDirect3DDevice9_AddRef(device);
*font=&object->ID3DXFont_iface;
*font = &object->ID3DXFont_iface;
return D3D_OK;
}

View file

@ -1690,11 +1690,7 @@ static HRESULT WINAPI d3dx9_mesh_OptimizeInplace(ID3DXMesh *iface, DWORD flags,
if (FAILED(hr)) goto cleanup;
} else if (flags & D3DXMESHOPT_ATTRSORT) {
if (!(flags & D3DXMESHOPT_IGNOREVERTS))
{
FIXME("D3DXMESHOPT_ATTRSORT vertex reordering not implemented.\n");
hr = E_NOTIMPL;
goto cleanup;
}
hr = iface->lpVtbl->LockAttributeBuffer(iface, 0, &attrib_buffer);
if (FAILED(hr)) goto cleanup;
@ -2397,9 +2393,9 @@ BOOL WINAPI D3DXIntersectTri(const D3DXVECTOR3 *p0, const D3DXVECTOR3 *p1, const
D3DXVec4Transform(&vec, &vec, &m);
if ( (vec.x >= 0.0f) && (vec.y >= 0.0f) && (vec.x + vec.y <= 1.0f) && (vec.z >= 0.0f) )
{
*pu = vec.x;
*pv = vec.y;
*pdist = fabsf( vec.z );
if (pu) *pu = vec.x;
if (pv) *pv = vec.y;
if (pdist) *pdist = fabsf( vec.z );
return TRUE;
}
}
@ -4545,6 +4541,94 @@ struct vertex
D3DXVECTOR3 normal;
};
HRESULT WINAPI D3DXCreatePolygon(struct IDirect3DDevice9 *device, float length, UINT sides,
struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency)
{
HRESULT hr;
ID3DXMesh *polygon;
struct vertex *vertices;
WORD (*faces)[3];
DWORD (*adjacency_buf)[3];
float scale;
unsigned int i;
TRACE("device %p, length %f, sides %u, mesh %p, adjacency %p.\n",
device, length, sides, mesh, adjacency);
if (!device || length < 0.0f || sides < 3 || !mesh)
return D3DERR_INVALIDCALL;
if (FAILED(hr = D3DXCreateMeshFVF(sides, sides + 1, D3DXMESH_MANAGED,
D3DFVF_XYZ | D3DFVF_NORMAL, device, &polygon)))
{
return hr;
}
if (FAILED(hr = polygon->lpVtbl->LockVertexBuffer(polygon, 0, (void **)&vertices)))
{
polygon->lpVtbl->Release(polygon);
return hr;
}
if (FAILED(hr = polygon->lpVtbl->LockIndexBuffer(polygon, 0, (void **)&faces)))
{
polygon->lpVtbl->UnlockVertexBuffer(polygon);
polygon->lpVtbl->Release(polygon);
return hr;
}
scale = 0.5f * length / sinf(D3DX_PI / sides);
vertices[0].position.x = 0.0f;
vertices[0].position.y = 0.0f;
vertices[0].position.z = 0.0f;
vertices[0].normal.x = 0.0f;
vertices[0].normal.y = 0.0f;
vertices[0].normal.z = 1.0f;
for (i = 0; i < sides; ++i)
{
vertices[i + 1].position.x = cosf(2.0f * D3DX_PI * i / sides) * scale;
vertices[i + 1].position.y = sinf(2.0f * D3DX_PI * i / sides) * scale;
vertices[i + 1].position.z = 0.0f;
vertices[i + 1].normal.x = 0.0f;
vertices[i + 1].normal.y = 0.0f;
vertices[i + 1].normal.z = 1.0f;
faces[i][0] = 0;
faces[i][1] = i + 1;
faces[i][2] = i + 2;
}
faces[sides - 1][2] = 1;
polygon->lpVtbl->UnlockVertexBuffer(polygon);
polygon->lpVtbl->UnlockIndexBuffer(polygon);
if (adjacency)
{
if (FAILED(hr = D3DXCreateBuffer(sides * sizeof(DWORD) * 3, adjacency)))
{
polygon->lpVtbl->Release(polygon);
return hr;
}
adjacency_buf = ID3DXBuffer_GetBufferPointer(*adjacency);
for (i = 0; i < sides; ++i)
{
adjacency_buf[i][0] = i - 1;
adjacency_buf[i][1] = ~0U;
adjacency_buf[i][2] = i + 1;
}
adjacency_buf[0][0] = sides - 1;
adjacency_buf[sides - 1][2] = 0;
}
*mesh = polygon;
return D3D_OK;
}
HRESULT WINAPI D3DXCreateBox(struct IDirect3DDevice9 *device, float width, float height,
float depth, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency)
{
@ -7136,3 +7220,59 @@ HRESULT WINAPI D3DXOptimizeFaces(const void *indices, UINT num_faces,
error:
return hr;
}
/*************************************************************************
* D3DXComputeTangentFrameEx (D3DX9_36.@)
*/
HRESULT WINAPI D3DXComputeTangentFrameEx(ID3DXMesh *Mesh, DWORD TextureInSemantic, DWORD TextureInIndex,
DWORD UPartialOutSemantic, DWORD UPartialOutIndex, DWORD VPartialOutSemantic, DWORD VPartialOutIndex,
DWORD NormalOutSemantic, DWORD NormalOutIndex, DWORD options, const DWORD *adjacency,
FLOAT PartialEdgeThreshold, FLOAT SingularPointThreshold, FLOAT NormalEdgeThreshold,
ID3DXMesh **MeshOut, ID3DXBuffer **VertexMapping)
{
FIXME("Mesh %p, TextureInSemantic %u, TextureInIndex %u, UPartialOutSemantic %u, UPartialOutIndex %u, "
"VPartialOutSemantic %u, VPartialOutIndex %u, NormalOutSemantic %u, NormalOutIndex %u, "
"options %x, adjacency %p, PartialEdgeThreshold %f, SingularPointThreshold %f, NormalEdgeThreshold %f, "
"MeshOut %p, VertexMapping %p stub.\n",
Mesh, TextureInSemantic, TextureInIndex, UPartialOutSemantic, UPartialOutIndex, VPartialOutSemantic,
VPartialOutIndex, NormalOutSemantic, NormalOutIndex, options, adjacency, PartialEdgeThreshold,
SingularPointThreshold, NormalEdgeThreshold, MeshOut, VertexMapping);
return E_NOTIMPL;
}
/*************************************************************************
* D3DXComputeNormals (D3DX9_36.@)
*/
HRESULT WINAPI D3DXComputeNormals(ID3DXBaseMesh *mesh, const DWORD *adjacency)
{
TRACE("mesh %p, adjacency %p.\n", mesh, adjacency);
return D3DXComputeTangentFrameEx((ID3DXMesh *)mesh, D3DX_DEFAULT, 0, D3DX_DEFAULT, 0, D3DX_DEFAULT, 0,
D3DDECLUSAGE_NORMAL, 0, D3DXTANGENT_GENERATE_IN_PLACE | D3DXTANGENT_CALCULATE_NORMALS,
adjacency, -1.01f, -0.01f, -1.01f, NULL, NULL);
}
/*************************************************************************
* D3DXComputeNormalMap (D3DX9_36.@)
*/
HRESULT WINAPI D3DXComputeNormalMap(IDirect3DTexture9 *texture, IDirect3DTexture9 *src_texture,
const PALETTEENTRY *src_palette, DWORD flags, DWORD channel, FLOAT amplitude)
{
FIXME("texture %p, src_texture %p, src_palette %p, flags %#x, channel %u, amplitude %f stub.\n",
texture, src_texture, src_palette, flags, channel, amplitude);
return D3D_OK;
}
/*************************************************************************
* D3DXIntersect (D3DX9_36.@)
*/
HRESULT WINAPI D3DXIntersect(ID3DXBaseMesh *Mesh, const D3DXVECTOR3 *RayPos, const D3DXVECTOR3 *RayDir, BOOL *Hit,
DWORD *FaceIndex, FLOAT *U, FLOAT *V, FLOAT *Dist, ID3DXBuffer **AllHits, DWORD *CountOfHits)
{
FIXME("Mesh %p, RayPos %p, RayDir %p, Hit %p, FaceIndex %p, U %p, V %p, Dist %p, AllHits %p, CountOfHits %p stub.\n",
Mesh, RayPos, RayDir, Hit, FaceIndex, U, V, Dist, AllHits, CountOfHits);
return E_NOTIMPL;
}

View file

@ -1,6 +1,7 @@
/*
* Copyright 2008 Luis Busquets
* Copyright 2009 Matteo Bruni
* Copyright 2010, 2013 Christian Costa
* Copyright 2011 Travis Athougies
*
* This library is free software; you can redistribute it and/or
@ -438,6 +439,41 @@ HRESULT WINAPI D3DXCompileShader(const char *data, UINT length, const D3DXMACRO
}
}
/* Filter out D3DCompile warning messages that are not present with D3DCompileShader */
if (SUCCEEDED(hr) && error_msgs && *error_msgs)
{
char *messages = ID3DXBuffer_GetBufferPointer(*error_msgs);
DWORD size = ID3DXBuffer_GetBufferSize(*error_msgs);
/* Ensure messages are null terminated for safe processing */
if (size) messages[size - 1] = 0;
while (size > 1)
{
char *prev, *next;
/* Warning has the form "warning X3206: ... implicit truncation of vector type"
but we only search for "X3206:" in case d3dcompiler_43 has localization */
prev = next = strstr(messages, "X3206:");
if (!prev) break;
/* get pointer to beginning and end of current line */
while (prev > messages && *(prev - 1) != '\n') prev--;
while (next < messages + size - 1 && *next != '\n') next++;
if (next < messages + size - 1 && *next == '\n') next++;
memmove(prev, next, messages + size - next);
size -= (next - prev);
}
/* Only return a buffer if the resulting string is not empty as some apps depend on that */
if (size <= 1)
{
ID3DXBuffer_Release(*error_msgs);
*error_msgs = NULL;
}
}
return hr;
}
@ -2114,3 +2150,118 @@ HRESULT WINAPI D3DXGetShaderSamplers(const DWORD *byte_code, const char **sample
return D3D_OK;
}
HRESULT WINAPI D3DXDisassembleShader(const DWORD *shader, BOOL colorcode, const char *comments, ID3DXBuffer **disassembly)
{
FIXME("%p %d %s %p: stub\n", shader, colorcode, debugstr_a(comments), disassembly);
return E_OUTOFMEMORY;
}
const DWORD* skip_instruction(const DWORD *byte_code, UINT shader_model)
{
TRACE("Shader model %u\n", shader_model);
/* Handle all special instructions whose arguments may contain D3DSIO_DCL */
if ((*byte_code & D3DSI_OPCODE_MASK) == D3DSIO_COMMENT)
{
byte_code += 1 + ((*byte_code & D3DSI_COMMENTSIZE_MASK) >> D3DSI_COMMENTSIZE_SHIFT);
}
else if (shader_model >= 2)
{
byte_code += 1 + ((*byte_code & D3DSI_INSTLENGTH_MASK) >> D3DSI_INSTLENGTH_SHIFT);
}
else if ((*byte_code & D3DSI_OPCODE_MASK) == D3DSIO_DEF)
{
byte_code += 1 + 5;
}
else
{
/* Handle remaining safe instructions */
while (*++byte_code & (1 << 31));
}
return byte_code;
}
static UINT get_shader_semantics(const DWORD *byte_code, D3DXSEMANTIC *semantics, BOOL input)
{
const DWORD *ptr = byte_code;
UINT shader_model = (*ptr >> 8) & 0xff;
UINT i = 0;
TRACE("Shader version: %#x\n", *ptr);
ptr++;
while (*ptr != D3DSIO_END)
{
if (*ptr & (1 << 31))
{
FIXME("Opcode expected but got %#x\n", *ptr);
return 0;
}
else if ((*ptr & D3DSI_OPCODE_MASK) == D3DSIO_DCL)
{
DWORD param1 = *++ptr;
DWORD param2 = *++ptr;
DWORD usage = param1 & 0x1f;
DWORD usage_index = (param1 >> 16) & 0xf;
DWORD reg_type = (((param2 >> 11) & 0x3) << 3) | ((param2 >> 28) & 0x7);
TRACE("D3DSIO_DCL param1: %#x, param2: %#x, usage: %u, usage_index: %u, reg_type: %u\n",
param1, param2, usage, usage_index, reg_type);
if ((input && (reg_type == D3DSPR_INPUT)) || (!input && (reg_type == D3DSPR_OUTPUT)))
{
if (semantics)
{
semantics[i].Usage = usage;
semantics[i].UsageIndex = usage_index;
}
i++;
}
ptr++;
}
else
{
ptr = skip_instruction(ptr, shader_model);
}
}
return i;
}
HRESULT WINAPI D3DXGetShaderInputSemantics(const DWORD *byte_code, D3DXSEMANTIC *semantics, UINT *count)
{
UINT nb_semantics;
TRACE("byte_code %p, semantics %p, count %p\n", byte_code, semantics, count);
if (!byte_code)
return D3DERR_INVALIDCALL;
nb_semantics = get_shader_semantics(byte_code, semantics, TRUE);
if (count)
*count = nb_semantics;
return D3D_OK;
}
HRESULT WINAPI D3DXGetShaderOutputSemantics(const DWORD *byte_code, D3DXSEMANTIC *semantics, UINT *count)
{
UINT nb_semantics;
TRACE("byte_code %p, semantics %p, count %p\n", byte_code, semantics, count);
if (!byte_code)
return D3DERR_INVALIDCALL;
nb_semantics = get_shader_semantics(byte_code, semantics, FALSE);
if (count)
*count = nb_semantics;
return D3D_OK;
}

View file

@ -2,6 +2,7 @@
* Skin Info operations specific to D3DX9.
*
* Copyright (C) 2011 Dylan Smith
* Copyright (C) 2013 Christian Costa
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@ -372,10 +373,89 @@ static HRESULT WINAPI d3dx9_skin_info_GetDeclaration(ID3DXSkinInfo *iface,
static HRESULT WINAPI d3dx9_skin_info_UpdateSkinnedMesh(ID3DXSkinInfo *iface, const D3DXMATRIX *bone_transforms,
const D3DXMATRIX *bone_inv_transpose_transforms, const void *src_vertices, void *dst_vertices)
{
FIXME("iface %p, bone_transforms %p, bone_inv_transpose_transforms %p, src_vertices %p, dst_vertices %p stub!\n",
iface, bone_transforms, bone_inv_transpose_transforms, src_vertices, dst_vertices);
struct d3dx9_skin_info *skin = impl_from_ID3DXSkinInfo(iface);
DWORD size = D3DXGetFVFVertexSize(skin->fvf);
DWORD i, j;
return E_NOTIMPL;
TRACE("iface %p, bone_transforms %p, bone_inv_transpose_transforms %p, src_vertices %p, dst_vertices %p\n",
skin, bone_transforms, bone_inv_transpose_transforms, src_vertices, dst_vertices);
if (bone_inv_transpose_transforms)
FIXME("Skinning vertices with two position elements not supported\n");
if ((skin->fvf & D3DFVF_POSITION_MASK) != D3DFVF_XYZ) {
FIXME("Vertex type %#x not supported\n", skin->fvf & D3DFVF_POSITION_MASK);
return E_FAIL;
}
/* Reset all positions */
for (i = 0; i < skin->num_vertices; i++) {
D3DXVECTOR3 *position = (D3DXVECTOR3*)((BYTE*)dst_vertices + size * i);
position->x = 0.0f;
position->y = 0.0f;
position->z = 0.0f;
}
/* Update positions that are influenced by bones */
for (i = 0; i < skin->num_bones; i++) {
D3DXMATRIX bone_inverse, matrix;
D3DXMatrixInverse(&bone_inverse, NULL, &skin->bones[i].transform);
D3DXMatrixMultiply(&matrix, &bone_transforms[i], &bone_inverse);
D3DXMatrixMultiply(&matrix, &matrix, &skin->bones[i].transform);
for (j = 0; j < skin->bones[i].num_influences; j++) {
D3DXVECTOR3 position;
D3DXVECTOR3 *position_src = (D3DXVECTOR3*)((BYTE*)src_vertices + size * skin->bones[i].vertices[j]);
D3DXVECTOR3 *position_dest = (D3DXVECTOR3*)((BYTE*)dst_vertices + size * skin->bones[i].vertices[j]);
FLOAT weight = skin->bones[i].weights[j];
D3DXVec3TransformCoord(&position, position_src, &matrix);
position_dest->x += weight * position.x;
position_dest->y += weight * position.y;
position_dest->z += weight * position.z;
}
}
if (skin->fvf & D3DFVF_NORMAL) {
/* Reset all normals */
for (i = 0; i < skin->num_vertices; i++) {
D3DXVECTOR3 *normal = (D3DXVECTOR3*)((BYTE*)dst_vertices + size * i + sizeof(D3DXVECTOR3));
normal->x = 0.0f;
normal->y = 0.0f;
normal->z = 0.0f;
}
/* Update normals that are influenced by bones */
for (i = 0; i < skin->num_bones; i++) {
D3DXMATRIX bone_inverse, matrix;
D3DXMatrixInverse(&bone_inverse, NULL, &skin->bones[i].transform);
D3DXMatrixMultiply(&matrix, &skin->bones[i].transform, &bone_transforms[i]);
for (j = 0; j < skin->bones[i].num_influences; j++) {
D3DXVECTOR3 normal;
D3DXVECTOR3 *normal_src = (D3DXVECTOR3*)((BYTE*)src_vertices + size * skin->bones[i].vertices[j] + sizeof(D3DXVECTOR3));
D3DXVECTOR3 *normal_dest = (D3DXVECTOR3*)((BYTE*)dst_vertices + size * skin->bones[i].vertices[j] + sizeof(D3DXVECTOR3));
FLOAT weight = skin->bones[i].weights[j];
D3DXVec3TransformNormal(&normal, normal_src, &bone_inverse);
D3DXVec3TransformNormal(&normal, &normal, &matrix);
normal_dest->x += weight * normal.x;
normal_dest->y += weight * normal.y;
normal_dest->z += weight * normal.z;
}
}
/* Normalize all normals that are influenced by bones*/
for (i = 0; i < skin->num_vertices; i++) {
D3DXVECTOR3 *normal_dest = (D3DXVECTOR3*)((BYTE*)dst_vertices + (i * size) + sizeof(D3DXVECTOR3));
if ((normal_dest->x != 0.0f) && (normal_dest->y != 0.0f) && (normal_dest->z != 0.0f))
D3DXVec3Normalize(normal_dest, normal_dest);
}
}
return D3D_OK;
}
static HRESULT WINAPI d3dx9_skin_info_ConvertToBlendedMesh(ID3DXSkinInfo *iface, ID3DXMesh *mesh_in,
@ -392,13 +472,13 @@ static HRESULT WINAPI d3dx9_skin_info_ConvertToBlendedMesh(ID3DXSkinInfo *iface,
}
static HRESULT WINAPI d3dx9_skin_info_ConvertToIndexedBlendedMesh(ID3DXSkinInfo *iface, ID3DXMesh *mesh_in,
DWORD options, const DWORD *adjacency_in, DWORD *adjacency_out, DWORD *face_remap,
DWORD options, DWORD palette_size, const DWORD *adjacency_in, DWORD *adjacency_out, DWORD *face_remap,
ID3DXBuffer **vertex_remap, DWORD *max_face_infl, DWORD *num_bone_combinations,
ID3DXBuffer **bone_combination_table, ID3DXMesh **mesh_out)
{
FIXME("iface %p, mesh_in %p, options %#x, adjacency_in %p, adjacency_out %p, face_remap %p, vertex_remap %p, "
FIXME("iface %p, mesh_in %p, options %#x, palette_size %u, adjacency_in %p, adjacency_out %p, face_remap %p, vertex_remap %p, "
"max_face_infl %p, num_bone_combinations %p, bone_combination_table %p, mesh_out %p stub!\n",
iface, mesh_in, options, adjacency_in, adjacency_out, face_remap, vertex_remap,
iface, mesh_in, options, palette_size, adjacency_in, adjacency_out, face_remap, vertex_remap,
max_face_infl, num_bone_combinations, bone_combination_table, mesh_out);
return E_NOTIMPL;

View file

@ -21,6 +21,7 @@
#include "d3dx9_36_private.h"
#include <ole2.h>
#include <wine/wined3d.h>
#include <initguid.h>
#include <wincodec.h>
@ -36,6 +37,7 @@ static const struct
{ &GUID_WICPixelFormat8bppIndexed, D3DFMT_P8 },
{ &GUID_WICPixelFormat1bppIndexed, D3DFMT_P8 },
{ &GUID_WICPixelFormat4bppIndexed, D3DFMT_P8 },
{ &GUID_WICPixelFormat8bppGray, D3DFMT_L8 },
{ &GUID_WICPixelFormat16bppBGR555, D3DFMT_X1R5G5B5 },
{ &GUID_WICPixelFormat16bppBGR565, D3DFMT_R5G6B5 },
{ &GUID_WICPixelFormat24bppBGR, D3DFMT_R8G8B8 },
@ -72,7 +74,7 @@ static const GUID *d3dformat_to_wic_guid(D3DFORMAT format)
/* dds_header.flags */
#define DDS_CAPS 0x1
#define DDS_HEIGHT 0x2
#define DDS_WIDTH 0x2
#define DDS_WIDTH 0x4
#define DDS_PITCH 0x8
#define DDS_PIXELFORMAT 0x1000
#define DDS_MIPMAPCOUNT 0x20000
@ -306,6 +308,14 @@ static HRESULT d3dformat_to_dds_pixel_format(struct dds_pixel_format *pixel_form
}
}
/* Reuse dds_fourcc_to_d3dformat as D3DFORMAT and FOURCC are DWORD with same values */
if (dds_fourcc_to_d3dformat(d3dformat) != D3DFMT_UNKNOWN)
{
pixel_format->flags |= DDS_PF_FOURCC;
pixel_format->fourcc = d3dformat;
return D3D_OK;
}
WARN("Unknown pixel format %#x\n", d3dformat);
return E_NOTIMPL;
}
@ -482,13 +492,14 @@ static HRESULT save_dds_surface_to_memory(ID3DXBuffer **dst_buffer, IDirect3DSur
memset(header, 0, sizeof(*header));
header->signature = MAKEFOURCC('D','D','S',' ');
header->size = sizeof(*header);
header->flags = DDS_CAPS | DDS_HEIGHT | DDS_WIDTH | DDS_PITCH | DDS_PIXELFORMAT | DDS_MIPMAPCOUNT;
/* The signature is not really part of the DDS header */
header->size = sizeof(*header) - sizeof(header->signature);
header->flags = DDS_CAPS | DDS_HEIGHT | DDS_WIDTH | DDS_PIXELFORMAT;
/* Note that native does not set DDS_LINEARSIZE flag nor pitch_or_linear_size field for DXTn */
header->flags |= (pixel_format->block_width != 1) || (pixel_format->block_height != 1) ? DDS_LINEARSIZE : DDS_PITCH;
header->height = src_desc.Height;
header->width = src_desc.Width;
header->pitch_or_linear_size = dst_pitch;
header->depth = 1;
header->miplevels = 1;
header->caps = DDS_CAPS_TEXTURE;
hr = d3dformat_to_dds_pixel_format(&header->pixel_format, src_desc.Format);
if (FAILED(hr))
@ -516,6 +527,68 @@ static HRESULT save_dds_surface_to_memory(ID3DXBuffer **dst_buffer, IDirect3DSur
return D3D_OK;
}
static HRESULT get_surface(D3DRESOURCETYPE type, struct IDirect3DBaseTexture9 *tex,
int face, UINT level, struct IDirect3DSurface9 **surf)
{
switch (type)
{
case D3DRTYPE_TEXTURE:
return IDirect3DTexture9_GetSurfaceLevel((IDirect3DTexture9*) tex, level, surf);
case D3DRTYPE_CUBETEXTURE:
return IDirect3DCubeTexture9_GetCubeMapSurface((IDirect3DCubeTexture9*) tex, face, level, surf);
default:
ERR("Unexpected texture type\n");
return E_NOTIMPL;
}
}
HRESULT save_dds_texture_to_memory(ID3DXBuffer **dst_buffer, IDirect3DBaseTexture9 *src_texture, const PALETTEENTRY *src_palette)
{
HRESULT hr;
D3DRESOURCETYPE type;
UINT mip_levels;
IDirect3DSurface9 *surface;
type = IDirect3DBaseTexture9_GetType(src_texture);
if ((type != D3DRTYPE_TEXTURE) && (type != D3DRTYPE_CUBETEXTURE) && (type != D3DRTYPE_VOLUMETEXTURE))
return D3DERR_INVALIDCALL;
if (type == D3DRTYPE_CUBETEXTURE)
{
FIXME("Cube texture not supported yet\n");
return E_NOTIMPL;
}
else if (type == D3DRTYPE_VOLUMETEXTURE)
{
FIXME("Volume texture not supported yet\n");
return E_NOTIMPL;
}
mip_levels = IDirect3DTexture9_GetLevelCount(src_texture);
if (mip_levels > 1)
{
FIXME("Mipmap not supported yet\n");
return E_NOTIMPL;
}
if (src_palette)
{
FIXME("Saving surfaces with palettized pixel formats not implemented yet\n");
return E_NOTIMPL;
}
hr = get_surface(type, src_texture, D3DCUBEMAP_FACE_POSITIVE_X, 0, &surface);
if (SUCCEEDED(hr))
{
hr = save_dds_surface_to_memory(dst_buffer, surface, NULL);
IDirect3DSurface9_Release(surface);
}
return hr;
}
HRESULT load_volume_from_dds(IDirect3DVolume9 *dst_volume, const PALETTEENTRY *dst_palette,
const D3DBOX *dst_box, const void *src_data, const D3DBOX *src_box, DWORD filter, D3DCOLOR color_key,
const D3DXIMAGE_INFO *src_info)
@ -1711,6 +1784,27 @@ void point_filter_argb_pixels(const BYTE *src, UINT src_row_pitch, UINT src_slic
}
}
typedef BOOL (*dxtn_conversion_func)(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out,
enum wined3d_format_id format, unsigned int w, unsigned int h);
static dxtn_conversion_func get_dxtn_conversion_func(D3DFORMAT format, BOOL encode)
{
switch (format)
{
case D3DFMT_DXT1:
if (!wined3d_dxtn_supported()) return NULL;
return encode ? wined3d_dxt1_encode : wined3d_dxt1_decode;
case D3DFMT_DXT3:
if (!wined3d_dxtn_supported()) return NULL;
return encode ? wined3d_dxt3_encode : wined3d_dxt3_decode;
case D3DFMT_DXT5:
if (!wined3d_dxtn_supported()) return NULL;
return encode ? wined3d_dxt5_encode : wined3d_dxt5_decode;
default:
return NULL;
}
}
/************************************************************
* D3DXLoadSurfaceFromMemory
*
@ -1752,6 +1846,7 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
D3DSURFACE_DESC surfdesc;
D3DLOCKED_RECT lockrect;
struct volume src_size, dst_size;
HRESULT ret = D3D_OK;
TRACE("(%p, %p, %s, %p, %#x, %u, %p, %s %#x, 0x%08x)\n",
dst_surface, dst_palette, wine_dbgstr_rect(dst_rect), src_memory, src_format,
@ -1833,8 +1928,15 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
}
else /* Stretching or format conversion. */
{
if (((srcformatdesc->type != FORMAT_ARGB) && (srcformatdesc->type != FORMAT_INDEX)) ||
(destformatdesc->type != FORMAT_ARGB))
dxtn_conversion_func pre_convert, post_convert;
void *tmp_src_memory = NULL, *tmp_dst_memory = NULL;
UINT tmp_src_pitch, tmp_dst_pitch;
pre_convert = get_dxtn_conversion_func(srcformatdesc->format, FALSE);
post_convert = get_dxtn_conversion_func(destformatdesc->format, TRUE);
if ((!pre_convert && (srcformatdesc->type != FORMAT_ARGB) && (srcformatdesc->type != FORMAT_INDEX)) ||
(!post_convert && (destformatdesc->type != FORMAT_ARGB)))
{
FIXME("Format conversion missing %#x -> %#x\n", src_format, surfdesc.Format);
return E_NOTIMPL;
@ -1843,10 +1945,52 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
if (FAILED(IDirect3DSurface9_LockRect(dst_surface, &lockrect, dst_rect, 0)))
return D3DXERR_INVALIDDATA;
/* handle pre-conversion */
if (pre_convert)
{
tmp_src_memory = HeapAlloc(GetProcessHeap(), 0, src_size.width * src_size.height * sizeof(DWORD));
if (!tmp_src_memory)
{
ret = E_OUTOFMEMORY;
goto error;
}
tmp_src_pitch = src_size.width * sizeof(DWORD);
if (!pre_convert(src_memory, tmp_src_memory, src_pitch, tmp_src_pitch,
WINED3DFMT_B8G8R8A8_UNORM, src_size.width, src_size.height))
{
ret = E_FAIL;
goto error;
}
srcformatdesc = get_format_info(D3DFMT_A8R8G8B8);
}
else
{
tmp_src_memory = (void *)src_memory;
tmp_src_pitch = src_pitch;
}
/* handle post-conversion */
if (post_convert)
{
tmp_dst_memory = HeapAlloc(GetProcessHeap(), 0, dst_size.width * dst_size.height * sizeof(DWORD));
if (!tmp_dst_memory)
{
ret = E_OUTOFMEMORY;
goto error;
}
tmp_dst_pitch = dst_size.width * sizeof(DWORD);
destformatdesc = get_format_info(D3DFMT_A8R8G8B8);
}
else
{
tmp_dst_memory = lockrect.pBits;
tmp_dst_pitch = lockrect.Pitch;
}
if ((filter & 0xf) == D3DX_FILTER_NONE)
{
convert_argb_pixels(src_memory, src_pitch, 0, &src_size, srcformatdesc,
lockrect.pBits, lockrect.Pitch, 0, &dst_size, destformatdesc, color_key, src_palette);
convert_argb_pixels(tmp_src_memory, tmp_src_pitch, 0, &src_size, srcformatdesc,
tmp_dst_memory, tmp_dst_pitch, 0, &dst_size, destformatdesc, color_key, src_palette);
}
else /* if ((filter & 0xf) == D3DX_FILTER_POINT) */
{
@ -1855,14 +1999,30 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
/* Always apply a point filter until D3DX_FILTER_LINEAR,
* D3DX_FILTER_TRIANGLE and D3DX_FILTER_BOX are implemented. */
point_filter_argb_pixels(src_memory, src_pitch, 0, &src_size, srcformatdesc,
lockrect.pBits, lockrect.Pitch, 0, &dst_size, destformatdesc, color_key, src_palette);
point_filter_argb_pixels(tmp_src_memory, tmp_src_pitch, 0, &src_size, srcformatdesc,
tmp_dst_memory, tmp_dst_pitch, 0, &dst_size, destformatdesc, color_key, src_palette);
}
/* handle post-conversion */
if (post_convert)
{
if (!post_convert(tmp_dst_memory, lockrect.pBits, tmp_dst_pitch, lockrect.Pitch,
WINED3DFMT_B8G8R8A8_UNORM, dst_size.width, dst_size.height))
{
ret = E_FAIL;
goto error;
}
}
error:
if (pre_convert)
HeapFree(GetProcessHeap(), 0, tmp_src_memory);
if (post_convert)
HeapFree(GetProcessHeap(), 0, tmp_dst_memory);
IDirect3DSurface9_UnlockRect(dst_surface);
}
return D3D_OK;
return ret;
}
/************************************************************

View file

@ -298,12 +298,13 @@ HRESULT WINAPI D3DXCheckTextureRequirements(struct IDirect3DDevice9 *device, UIN
/* This format can be used, let's evaluate it.
Weights chosen quite arbitrarily... */
score = 16 - 4 * (curchannels - channels);
score = 512 * (curfmt->type == fmt->type);
score -= 32 * (curchannels - channels);
for (j = 0; j < 4; j++)
{
int diff = curfmt->bits[j] - fmt->bits[j];
score += 16 - (diff < 0 ? -diff * 4 : diff);
score -= (diff < 0 ? -diff * 8 : diff) * (j == 0 ? 1 : 2);
}
if (score > bestscore)
@ -329,10 +330,10 @@ HRESULT WINAPI D3DXCheckTextureRequirements(struct IDirect3DDevice9 *device, UIN
if (fmt->block_width != 1 || fmt->block_height != 1)
{
if (w < fmt->block_width)
w = fmt->block_width;
if (h < fmt->block_height)
h = fmt->block_height;
if (w % fmt->block_width)
w += fmt->block_width - w % fmt->block_width;
if (h % fmt->block_height)
h += fmt->block_height - h % fmt->block_height;
}
if ((caps.TextureCaps & D3DPTEXTURECAPS_POW2) && (!is_pow2(w)))
@ -534,6 +535,29 @@ HRESULT WINAPI D3DXCreateTexture(struct IDirect3DDevice9 *device, UINT width, UI
return IDirect3DDevice9_CreateTexture(device, width, height, miplevels, usage, format, pool, texture, NULL);
}
static D3DFORMAT get_alpha_replacement_format(D3DFORMAT format)
{
static const struct
{
D3DFORMAT orig_format;
D3DFORMAT replacement_format;
}
replacement_formats[] =
{
{D3DFMT_X8R8G8B8, D3DFMT_A8R8G8B8},
{D3DFMT_X1R5G5B5, D3DFMT_A1R5G5B5},
{D3DFMT_X4R4G4B4, D3DFMT_A4R4G4B4},
{D3DFMT_X8B8G8R8, D3DFMT_A8B8G8R8},
{D3DFMT_L8, D3DFMT_A8L8},
};
unsigned int i;
for (i = 0; i < sizeof(replacement_formats) / sizeof(replacement_formats[0]); ++i)
if (replacement_formats[i].orig_format == format)
return replacement_formats[i].replacement_format;
return format;
}
HRESULT WINAPI D3DXCreateTextureFromFileInMemoryEx(struct IDirect3DDevice9 *device, const void *srcdata,
UINT srcdatasize, UINT width, UINT height, UINT miplevels, DWORD usage, D3DFORMAT format,
D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo,
@ -542,7 +566,7 @@ HRESULT WINAPI D3DXCreateTextureFromFileInMemoryEx(struct IDirect3DDevice9 *devi
IDirect3DTexture9 **texptr;
IDirect3DTexture9 *buftex;
IDirect3DSurface9 *surface;
BOOL dynamic_texture;
BOOL dynamic_texture, format_specified = FALSE;
D3DXIMAGE_INFO imginfo;
UINT loaded_miplevels, skip_levels;
D3DCAPS9 caps;
@ -581,6 +605,8 @@ HRESULT WINAPI D3DXCreateTextureFromFileInMemoryEx(struct IDirect3DDevice9 *devi
if (format == D3DFMT_UNKNOWN || format == D3DX_DEFAULT)
format = imginfo.Format;
else
format_specified = TRUE;
if (width == D3DX_FROM_FILE)
{
@ -626,6 +652,9 @@ HRESULT WINAPI D3DXCreateTextureFromFileInMemoryEx(struct IDirect3DDevice9 *devi
return hr;
}
if (colorkey && !format_specified)
format = get_alpha_replacement_format(format);
if (imginfo.MipLevels < miplevels && (D3DFMT_DXT1 <= imginfo.Format && imginfo.Format <= D3DFMT_DXT5))
{
FIXME("Generation of mipmaps for compressed pixel formats is not implemented yet\n");
@ -1840,10 +1869,7 @@ HRESULT WINAPI D3DXSaveTextureToFileInMemory(ID3DXBuffer **dst_buffer, D3DXIMAGE
if (!dst_buffer || !src_texture) return D3DERR_INVALIDCALL;
if (file_format == D3DXIFF_DDS)
{
FIXME("DDS file format isn't supported yet\n");
return E_NOTIMPL;
}
return save_dds_texture_to_memory(dst_buffer, src_texture, src_palette);
type = IDirect3DBaseTexture9_GetType(src_texture);
switch (type)

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -76,7 +76,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -120,7 +120,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -26,7 +26,7 @@
@ stdcall D3DXComputeNormals(ptr ptr) d3dx9_36.D3DXComputeNormals
@ stdcall D3DXComputeTangent(ptr long long long long ptr) d3dx9_36.D3DXComputeTangent
@ stdcall D3DXComputeTangentFrame(ptr long) d3dx9_36.D3DXComputeTangentFrame
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr long long long ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXComputeTangentFrameEx(ptr long long long long long long long long long ptr float float float ptr ptr) d3dx9_36.D3DXComputeTangentFrameEx
@ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes
@ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip
@ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips
@ -74,7 +74,7 @@
@ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh
@ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream
@ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh
@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon
@ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer
@ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex
@ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer
@ -118,7 +118,7 @@
@ stdcall D3DXDebugMute(long) d3dx9_36.D3DXDebugMute
@ stdcall D3DXDeclaratorFromFVF(long ptr) d3dx9_36.D3DXDeclaratorFromFVF
@ stdcall D3DXDisassembleEffect(ptr long ptr) d3dx9_36.D3DXDisassembleEffect
@ stdcall D3DXDisassembleShader(ptr long ptr ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXDisassembleShader(ptr long str ptr) d3dx9_36.D3DXDisassembleShader
@ stdcall D3DXFileCreate(ptr) d3dx9_36.D3DXFileCreate
@ stdcall D3DXFillCubeTexture(ptr ptr ptr) d3dx9_36.D3DXFillCubeTexture
@ stdcall D3DXFillCubeTextureTX(ptr ptr) d3dx9_36.D3DXFillCubeTextureTX

View file

@ -327,7 +327,7 @@ DECLARE_INTERFACE_(ID3DXAnimationController, IUnknown)
STDMETHOD_(UINT, GetNumAnimationSets)(THIS) PURE;
STDMETHOD(GetAnimationSet)(THIS_ UINT index, ID3DXAnimationSet **anim_set) PURE;
STDMETHOD(GetAnimationSetByName)(THIS_ const char *name, ID3DXAnimationSet **anim_set) PURE;
STDMETHOD(AdvanceTime)(THIS_ double time_delta, ID3DXAnimationCallbackHandler **callback_handler) PURE;
STDMETHOD(AdvanceTime)(THIS_ DOUBLE time_delta, ID3DXAnimationCallbackHandler **callback_handler) PURE;
STDMETHOD(ResetTime)(THIS) PURE;
STDMETHOD_(DOUBLE, GetTime)(THIS) PURE;
STDMETHOD(SetTrackAnimationSet)(THIS_ UINT track, ID3DXAnimationSet *anim_set) PURE;
@ -337,8 +337,8 @@ DECLARE_INTERFACE_(ID3DXAnimationController, IUnknown)
STDMETHOD(SetTrackWeight)(THIS_ UINT track, FLOAT weight) PURE;
STDMETHOD(SetTrackPosition)(THIS_ UINT track, DOUBLE position) PURE;
STDMETHOD(SetTrackEnable)(THIS_ UINT track, BOOL enable) PURE;
STDMETHOD(SetTrackDesc)(THIS_ UINT track, LPD3DXTRACK_DESC desc) PURE;
STDMETHOD(GetTrackDesc)(THIS_ UINT track, LPD3DXTRACK_DESC desc) PURE;
STDMETHOD(SetTrackDesc)(THIS_ UINT track, D3DXTRACK_DESC *desc) PURE;
STDMETHOD(GetTrackDesc)(THIS_ UINT track, D3DXTRACK_DESC *desc) PURE;
STDMETHOD(SetPriorityBlend)(THIS_ FLOAT blend_weight) PURE;
STDMETHOD_(FLOAT, GetPriorityBlend)(THIS) PURE;
STDMETHOD_(D3DXEVENTHANDLE, KeyTrackSpeed)(THIS_ UINT track, FLOAT new_speed,
@ -357,7 +357,7 @@ DECLARE_INTERFACE_(ID3DXAnimationController, IUnknown)
STDMETHOD_(D3DXEVENTHANDLE, GetUpcomingTrackEvent)(THIS_ UINT track, D3DXEVENTHANDLE event) PURE;
STDMETHOD_(D3DXEVENTHANDLE, GetUpcomingPriorityBlend)(THIS_ D3DXEVENTHANDLE handle) PURE;
STDMETHOD(ValidateEvent)(THIS_ D3DXEVENTHANDLE event) PURE;
STDMETHOD(GetEventDesc)(THIS_ D3DXEVENTHANDLE event, LPD3DXEVENT_DESC desc) PURE;
STDMETHOD(GetEventDesc)(THIS_ D3DXEVENTHANDLE event, D3DXEVENT_DESC *desc) PURE;
STDMETHOD(CloneAnimationController)(THIS_ UINT max_num_anim_outputs, UINT max_num_anim_sets,
UINT max_num_tracks, UINT max_num_events, ID3DXAnimationController **anim_controller) PURE;
};

View file

@ -544,9 +544,10 @@ DECLARE_INTERFACE_(ID3DXSkinInfo, IUnknown)
STDMETHOD(ConvertToBlendedMesh)(THIS_ ID3DXMesh *mesh_in, DWORD options, const DWORD *adjacency_in,
DWORD *adjacency_out, DWORD *face_remap, ID3DXBuffer **vertex_remap, DWORD *max_face_infl,
DWORD *num_bone_combinations, ID3DXBuffer **bone_combination_table, ID3DXMesh **mesh_out) PURE;
STDMETHOD(ConvertToIndexedBlendedMesh)(THIS_ ID3DXMesh *mesh_in, DWORD options, const DWORD *adjacency_in,
DWORD *adjacency_out, DWORD *face_remap, ID3DXBuffer **vertex_remap, DWORD *max_face_infl,
DWORD *num_bone_combinations, ID3DXBuffer **bone_combination_table, ID3DXMesh **mesh_out) PURE;
STDMETHOD(ConvertToIndexedBlendedMesh)(THIS_ ID3DXMesh *mesh_in, DWORD options, DWORD palette_size,
const DWORD *adjacency_in, DWORD *adjacency_out, DWORD *face_remap, ID3DXBuffer **vertex_remap,
DWORD *max_face_infl, DWORD *num_bone_combinations, ID3DXBuffer **bone_combination_table,
ID3DXMesh **mesh_out) PURE;
};
#undef INTERFACE

View file

@ -315,6 +315,7 @@ DWORD WINAPI D3DXGetShaderVersion(const DWORD *byte_code);
const char * WINAPI D3DXGetVertexShaderProfile(struct IDirect3DDevice9 *device);
HRESULT WINAPI D3DXFindShaderComment(const DWORD *byte_code, DWORD fourcc, const void **data, UINT *size);
HRESULT WINAPI D3DXGetShaderSamplers(const DWORD *byte_code, const char **samplers, UINT *count);
HRESULT WINAPI D3DXGetShaderInputSemantics(const DWORD *byte_code, D3DXSEMANTIC *semantics, UINT *count);
HRESULT WINAPI D3DXAssembleShaderFromFileA(const char *filename, const D3DXMACRO *defines,
ID3DXInclude *include, DWORD flags, ID3DXBuffer **shader, ID3DXBuffer **error_messages);

View file

@ -29,6 +29,8 @@ HRESULT WINAPI D3DXCreateBox(struct IDirect3DDevice9 *device, float width, float
float depth, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency);
HRESULT WINAPI D3DXCreateCylinder(struct IDirect3DDevice9 *device, float radius1, float radius2,
float length, UINT slices, UINT stacks, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency);
HRESULT WINAPI D3DXCreatePolygon(struct IDirect3DDevice9 *device, float length, UINT sides, struct ID3DXMesh **mesh,
ID3DXBuffer **adjacency);
HRESULT WINAPI D3DXCreateSphere(struct IDirect3DDevice9 *device, float radius, UINT slices,
UINT stacks, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency);
HRESULT WINAPI D3DXCreateTeapot(struct IDirect3DDevice9 *device,
@ -37,6 +39,8 @@ HRESULT WINAPI D3DXCreateTextA(struct IDirect3DDevice9 *device, HDC hdc, const c
float extrusion, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency, GLYPHMETRICSFLOAT *glyphmetrics);
HRESULT WINAPI D3DXCreateTextW(struct IDirect3DDevice9 *device, HDC hdc, const WCHAR *text, float deviation,
FLOAT extrusion, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency, GLYPHMETRICSFLOAT *glyphmetrics);
HRESULT WINAPI D3DXCreateTorus(struct IDirect3DDevice9 *device,
float innerradius, float outerradius, UINT sides, UINT rings, struct ID3DXMesh **mesh, ID3DXBuffer **adjacency);
#define D3DXCreateText WINELIB_NAME_AW(D3DXCreateText)
#ifdef __cplusplus

View file

@ -32,7 +32,7 @@ reactos/dll/directx/wine/d3d8 # Synced to WineStaging-1.7.37
reactos/dll/directx/wine/d3d9 # Synced to WineStaging-1.7.37
reactos/dll/directx/wine/d3dcompiler_43 # Synced to WineStaging-1.7.37
reactos/dll/directx/wine/d3drm # Synced to WineStaging-1.7.37
reactos/dll/directx/wine/d3dx9_24 => 43 # Synced to Wine-1.7.27
reactos/dll/directx/wine/d3dx9_24 => 43 # Synced to WineStaging-1.7.37
reactos/dll/directx/wine/d3dxof # Synced to WineStaging-1.7.37
reactos/dll/directx/wine/ddraw # Synced to WineStaging-1.7.37
reactos/dll/directx/wine/devenum # Synced to Wine-1.7.27