----------------------------------------
-- File : d3dx9core.ads --
-- Translator:Dongfeng.Gu,2018/10/14 --
-- Mail: [email protected] --
-- Progress:100% --
----------------------------------------
with win32; use win32;
with win32.windef; use win32.windef;
with win32.wingdi; use win32.wingdi;
with win32.rpcdce; use win32.rpcdce;
with win32.objbase; use win32.Objbase;
with d3d9; use d3d9;
with d3d9types; use d3d9types;
package d3dx9core is
D3DX_VERSION : constant := 16#0902#;
D3DX_SDK_VERSION : constant := 43;
function D3DXCheckVersion(D3DSdkVersion:UINT;D3DXSdkVersion:UINT) return bool with Import,Convention=>stdcall,external_name=>"D3DXCheckVersion";
function D3DXDebugMute(Mute:BOOL) return bool with Import,Convention=>stdcall,external_name=>"D3DXDebugMute";
function D3DXGetDriverLevel(pDevice:LPDIRECT3DDEVICE9) return UINT with Import,Convention=>stdcall,external_name=>"D3DXGetDriverLevel";
type ID3DXBuffer;
type LPID3DXBUFFER is access all ID3DXBuffer;
type LPD3DXBUFFER is access all ID3DXBuffer;
IID_ID3DXBuffer:constant win32.rpcdce.GUID:=(16#8ba5fb08#,16#5195#,16#40e2#,(16#ac#,16#58#,16#d#,16#98#,16#9c#,16#3a#,16#1#,16#2#));
type ID3DXBuffer is record
QueryInterface:access procedure(THIS:LPID3DXBuffer;iid:REFIID;ppv:LPLPVOID) with Convention=>Stdcall;
AddRef:access function(THIS:LPID3DXBuffer) return ULONG with Convention=>Stdcall;
Release:access function(THIS:LPID3DXBuffer) return ULONG with Convention=>Stdcall;
GetBufferPointer:access function(THIS:LPID3DXBuffer) return LPVOID with Convention=>Stdcall;
GetBufferSize:access function(THIS:LPID3DXBuffer) return DWORD with Convention=>Stdcall;
end record;
D3DXSPRITE_DONOTSAVESTATE : constant DWORD:= Lsh(1,0);
D3DXSPRITE_DONOTMODIFY_RENDERSTATE : constant DWORD:= Lsh(1,1);
D3DXSPRITE_OBJECTSPACE : constant DWORD:= Lsh(1,2);
D3DXSPRITE_BILLBOARD : constant DWORD:= Lsh(1,3);
D3DXSPRITE_ALPHABLEND : constant DWORD:= Lsh(1,4);
D3DXSPRITE_SORT_TEXTURE : constant DWORD:= Lsh(1,5);
D3DXSPRITE_SORT_DEPTH_FRONTTOBACK : constant DWORD:= Lsh(1,6);
D3DXSPRITE_SORT_DEPTH_BACKTOFRONT : constant DWORD:= Lsh(1,7);
D3DXSPRITE_DO_NOT_ADDREF_TEXTURE : constant DWORD:= Lsh(1,8);
type ID3DXSprite;
type LPID3DXSPRITE is access all ID3DXSprite;
type LPD3DXSPRITE is access all ID3DXSprite;
type LPLPID3DXSPRITE is access all LPID3DXSPRITE;
subtype LPLPD3DXSPRITE is LPLPID3DXSPRITE;
IID_ID3DXSprite:constant win32.rpcdce.GUID:=(16#ba0b762d#,16#7d28#,16#43ec#,(16#b9#,16#dc#,16#2f#,16#84#,16#44#,16#3b#,16#6#,16#14#));
type ID3DXSprite is record
QueryInterface:access procedure(THIS:LPID3DXSprite;iid:REFIID;ppv:LPLPVOID) with Convention=>Stdcall;
AddRef:access function(THIS:LPID3DXSprite) return ULONG with Convention=>Stdcall;
Release:access function(THIS:LPID3DXSprite) return ULONG with Convention=>Stdcall;
GetDevice:access procedure(THIS:LPID3DXSprite;ppDevice:access LPDIRECT3DDEVICE9) with Convention=>Stdcall;
GetTransform:access procedure(THIS:LPID3DXSprite;pTransform:LPD3DMATRIX) with Convention=>Stdcall;
SetTransform:access procedure(THIS:LPID3DXSprite;pTransform:access constant D3DMATRIX) with Convention=>Stdcall;
SetWorldViewRH:access procedure(THIS:LPID3DXSprite;pWorld:access constant D3DMATRIX;pView:access constant D3DMATRIX) with Convention=>Stdcall;
SetWorldViewLH:access procedure(THIS:LPID3DXSprite;pWorld:access constant D3DMATRIX;pView:access constant D3DMATRIX) with Convention=>Stdcall;
Beginn:access procedure(THIS:LPID3DXSprite;Flags:DWORD) with Convention=>Stdcall;
Draw:access procedure(THIS:LPID3DXSprite;pTexture:LPDIRECT3DTEXTURE9;pSrcRect:LPCRECT;pCenter:access constant D3DVECTOR3;pPosition:access constant D3DVECTOR3;Color:D3DCOLOR) with Convention=>Stdcall;
Flush:access procedure(THIS:LPID3DXSprite) with Convention=>Stdcall;
Endd:access procedure(THIS:LPID3DXSprite) with Convention=>Stdcall;
OnLostDevice:access procedure(THIS:LPID3DXSprite) with Convention=>Stdcall;
OnResetDevice:access procedure(THIS:LPID3DXSprite) with Convention=>Stdcall;
end record;
function D3DXCreateSprite(pDevice:LPDIRECT3DDEVICE9;ppSprite:LPLPD3DXSPRITE) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateSprite";
type tagD3DXFONT_DESCA is record
Height:INT;
Width:UINT;
Weight:UINT;
MipLevels:UINT;
Italic:BOOL;
CharSet:BYTE;
OutputPrecision:BYTE;
Quality:BYTE;
PitchAndFamily:BYTE;
FaceName:CHAR_Array(0..LF_FACESIZE-1);
end record;
subtype D3DXFONT_DESCA is tagD3DXFONT_DESCA;
type LPD3DXFONT_DESCA is access all tagD3DXFONT_DESCA;
type tagD3DXFONT_DESCW is record
Height:INT;
Width:UINT;
Weight:UINT;
MipLevels:UINT;
Italic:BOOL;
CharSet:BYTE;
OutputPrecision:BYTE;
Quality:BYTE;
PitchAndFamily:BYTE;
FaceName:WCHAR_Array(0..LF_FACESIZE-1);
end record;
subtype D3DXFONT_DESCW is tagD3DXFONT_DESCW;
type LPD3DXFONT_DESCW is access all tagD3DXFONT_DESCW;
-- subtype D3DXFONT_DESC is D3DXFONT_DESCW;
--
-- subtype LPD3DXFONT_DESC is LPD3DXFONT_DESCW;
--
subtype D3DXFONT_DESC is D3DXFONT_DESCA;
subtype LPD3DXFONT_DESC is LPD3DXFONT_DESCA;
type ID3DXFont;
type LPID3DXFont is access all ID3DXFont;
subtype LPD3DXFONT is LPID3DXFont;
type LPLPD3DXFONT is access all LPD3DXFONT;
IID_ID3DXFont:constant win32.rpcdce.GUID:=(16#d79dbb70#,16#5f21#,16#4d36#,(16#bb#,16#c2#,16#ff#,16#52#,16#5c#,16#21#,16#3c#,16#dc#));
type ID3DXFont is record
QueryInterface:access procedure(THIS:LPID3DXFont;iid:REFIID;ppv:LPLPVOID) with Convention=>Stdcall;
AddRef:access function(THIS:LPID3DXFont) return ULONG with Convention=>Stdcall;
Release:access function(THIS:LPID3DXFont) return ULONG with Convention=>Stdcall;
GetDevice:access procedure(THIS:LPID3DXFont;ppDevice:LPLPIDIRECT3DDEVICE9) with Convention=>Stdcall;
GetDescA:access procedure(THIS:LPID3DXFont;pDesc:LPD3DXFONT_DESCA) with Convention=>Stdcall;
GetDescW:access procedure(THIS:LPID3DXFont;pDesc:LPD3DXFONT_DESCW) with Convention=>Stdcall;
GetTextMetricsA:access function(THIS:LPID3DXFont;pTextMetrics:LPTEXTMETRICA) return BOOL with Convention=>Stdcall;
GetTextMetricsW:access function(THIS:LPID3DXFont;pTextMetrics:LPTEXTMETRICW) return BOOL with Convention=>Stdcall;
GetDC:access function(THIS:LPID3DXFont) return win32.windef.HDC with Convention=>Stdcall;
GetGlyphData:access procedure(THIS:LPID3DXFont;Glyph:UINT;ppTexture:LPLPIDIRECT3DTEXTURE9;pBlackBox:LPRECT;pCellInc:LPPOINT) with Convention=>Stdcall;
PreloadCharacters:access procedure(THIS:LPID3DXFont;First:UINT;Last:UINT) with Convention=>Stdcall;
PreloadGlyphs:access procedure(THIS:LPID3DXFont;First:UINT;Last:UINT) with Convention=>Stdcall;
PreloadTextA:access procedure(THIS:LPID3DXFont;pString:LPCSTR;Count:INT) with Convention=>Stdcall;
PreloadTextW:access procedure(THIS:LPID3DXFont;pString:LPCWSTR;Count:INT) with Convention=>Stdcall;
DrawTextA:access function(THIS:LPID3DXFont;pSprite:LPD3DXSPRITE;pString:LPCSTR;Count:INT;pRect:LPRECT;Format:DWORD;Color:D3DCOLOR) return INT with Convention=>Stdcall;
DrawTextW:access function(THIS:LPID3DXFont;pSprite:LPD3DXSPRITE;pString:LPCWSTR;Count:INT;pRect:LPRECT;Format:DWORD;Color:D3DCOLOR) return INT with Convention=>Stdcall;
OnLostDevice:access procedure(THIS:LPID3DXFont) with Convention=>Stdcall;
OnResetDevice:access procedure(THIS:LPID3DXFont) with Convention=>Stdcall;
end record;
function GetDesc(THIS:LPID3DXFont;pDesc:LPD3DXFONT_DESCA) return HRESULT with Import,convention=>stdcall,External_Name=>"GetDescA";
function PreloadText(pString:LPCSTR; Count:int) return HRESULT with Import,convention=>stdcall,External_Name=>"PreloadText";
function D3DXCreateFontA(pDevice:LPDIRECT3DDEVICE9;Height:INT;Width:UINT;Weight:UINT;MipLevels:UINT;Italic:BOOL;CharSet:DWORD;OutputPrecision:DWORD;Quality:DWORD;PitchAndFamily:DWORD;pFaceName:LPCSTR;ppFont:LPLPD3DXFONT) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateFontA";
function D3DXCreateFont(pDevice:LPDIRECT3DDEVICE9;Height:INT;Width:UINT;Weight:UINT;MipLevels:UINT;Italic:BOOL;CharSet:DWORD;OutputPrecision:DWORD;Quality:DWORD;PitchAndFamily:DWORD;pFaceName:LPCSTR;ppFont:LPLPD3DXFONT) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateFontA";
function D3DXCreateFontW(pDevice:LPDIRECT3DDEVICE9;Height:INT;Width:UINT;Weight:UINT;MipLevels:UINT;Italic:BOOL;CharSet:DWORD;OutputPrecision:DWORD;Quality:DWORD;PitchAndFamily:DWORD;pFaceName:LPCWSTR;ppFont:LPLPD3DXFONT) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateFontW";
function D3DXCreateFontIndirectA(pDevice:LPDIRECT3DDEVICE9;pDesc:access constant D3DXFONT_DESCA;ppFont:LPLPD3DXFONT) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateFontIndirectA";
function D3DXCreateFontIndirect(pDevice:LPDIRECT3DDEVICE9;pDesc:access constant D3DXFONT_DESCA;ppFont:LPLPD3DXFONT) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateFontIndirectA";
function D3DXCreateFontIndirectW(pDevice:LPDIRECT3DDEVICE9;pDesc:access constant D3DXFONT_DESCW;ppFont:LPLPD3DXFONT) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateFontIndirectW";
type tagD3DXRTS_DESC is record
Width:UINT;
Height:UINT;
Format:D3DFORMAT;
DepthStencil:BOOL;
DepthStencilFormat:D3DFORMAT;
end record;
subtype D3DXRTS_DESC is tagD3DXRTS_DESC;
type LPD3DXRTS_DESC is access all tagD3DXRTS_DESC;
type ID3DXRenderToSurface;
type LPID3DXRENDERTOSURFACE is access all ID3DXRenderToSurface;
subtype LPD3DXRENDERTOSURFACE is LPID3DXRENDERTOSURFACE;
TYPE LPLPD3DXRENDERTOSURFACE is access all LPD3DXRENDERTOSURFACE;
IID_ID3DXRenderToSurface:constant win32.rpcdce.GUID:=(16#6985f346#,16#2c3d#,16#43b3#,(16#be#,16#8b#,16#da#,16#ae#,16#8a#,16#3#,16#d8#,16#94#));
type ID3DXRenderToSurface is record
QueryInterface:access procedure(THIS:LPID3DXRenderToSurface;iid:REFIID;ppv:LPLPVOID) with Convention=>Stdcall;
AddRef:access function(THIS:LPID3DXRenderToSurface) return ULONG with Convention=>Stdcall;
Release:access function(THIS:LPID3DXRenderToSurface) return ULONG with Convention=>Stdcall;
GetDevice:access procedure(THIS:LPID3DXRenderToSurface;ppDevice:LPLPIDIRECT3DDEVICE9) with Convention=>Stdcall;
GetDesc:access procedure(THIS:LPID3DXRenderToSurface;pDesc:LPD3DXRTS_DESC) with Convention=>Stdcall;
BeginScene:access procedure(THIS:LPID3DXRenderToSurface;pSurface:LPDIRECT3DSURFACE9;pViewport:ACCESS CONSTANT D3DVIEWPORT9) with Convention=>Stdcall;
EndScene:access procedure(THIS:LPID3DXRenderToSurface;MipFilter:DWORD) with Convention=>Stdcall;
OnLostDevice:access procedure(THIS:LPID3DXRenderToSurface) with Convention=>Stdcall;
OnResetDevice:access procedure(THIS:LPID3DXRenderToSurface) with Convention=>Stdcall;
end record;
function D3DXCreateRenderToSurface(pDevice:LPDIRECT3DDEVICE9;Width:UINT;Height:UINT;Format:D3DFORMAT;DepthStencil:BOOL;DepthStencilFormat:D3DFORMAT;ppRenderToSurface:LPLPD3DXRENDERTOSURFACE) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateRenderToSurface";
type tagD3DXRTE_DESC is record
Size:UINT;
MipLevels:UINT;
Format:D3DFORMAT;
DepthStencil:BOOL;
DepthStencilFormat:D3DFORMAT;
end record;
subtype D3DXRTE_DESC is tagD3DXRTE_DESC;
type LPD3DXRTE_DESC is access all tagD3DXRTE_DESC;
type ID3DXRenderToEnvMap;
type LPID3DXRenderToEnvMap is access all ID3DXRenderToEnvMap;
subtype LPD3DXRenderToEnvMap is LPID3DXRenderToEnvMap;
type LPLPD3DXRenderToEnvMap is access all LPD3DXRenderToEnvMap;
IID_ID3DXRenderToEnvMap:constant win32.rpcdce.GUID:=(16#313f1b4b#,16#c7b0#,16#4fa2#,(16#9d#,16#9d#,16#8d#,16#38#,16#b#,16#64#,16#38#,16#5e#));
type ID3DXRenderToEnvMap is record
QueryInterface:access procedure(THIS:LPID3DXRenderToEnvMap;iid:REFIID;ppv:LPLPVOID) with Convention=>Stdcall;
AddRef:access function(THIS:LPID3DXRenderToEnvMap) return ULONG with Convention=>Stdcall;
Release:access function(THIS:LPID3DXRenderToEnvMap) return ULONG with Convention=>Stdcall;
GetDevice:access procedure(THIS:LPID3DXRenderToEnvMap;ppDevice:LPLPIDIRECT3DDEVICE9) with Convention=>Stdcall;
GetDesc:access procedure(THIS:LPID3DXRenderToEnvMap;pDesc:LPD3DXRTE_DESC) with Convention=>Stdcall;
BeginCube:access procedure(THIS:LPID3DXRenderToEnvMap;pCubeTex:LPDIRECT3DCUBETEXTURE9) with Convention=>Stdcall;
BeginSphere:access procedure(THIS:LPID3DXRenderToEnvMap;pTex:LPDIRECT3DTEXTURE9) with Convention=>Stdcall;
BeginHemisphere:access procedure(THIS:LPID3DXRenderToEnvMap;pTexZPos:LPDIRECT3DTEXTURE9;pTexZNeg:LPDIRECT3DTEXTURE9) with Convention=>Stdcall;
BeginParabolic:access procedure(THIS:LPID3DXRenderToEnvMap;pTexZPos:LPDIRECT3DTEXTURE9;pTexZNeg:LPDIRECT3DTEXTURE9) with Convention=>Stdcall;
Face:access procedure(THIS:LPID3DXRenderToEnvMap;Face:D3DCUBEMAP_FACES;MipFilter:DWORD) with Convention=>Stdcall;
Endd:access procedure(THIS:LPID3DXRenderToEnvMap;MipFilter:DWORD) with Convention=>Stdcall;
OnLostDevice:access procedure(THIS:LPID3DXRenderToEnvMap) with Convention=>Stdcall;
OnResetDevice:access procedure(THIS:LPID3DXRenderToEnvMap) with Convention=>Stdcall;
end record;
function D3DXCreateRenderToEnvMap(pDevice:LPDIRECT3DDEVICE9;Size:UINT;MipLevels:UINT;Format:D3DFORMAT;DepthStencil:BOOL;DepthStencilFormat:D3DFORMAT;ppRenderToEnvMap:LPLPD3DXRenderToEnvMap) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateRenderToEnvMap";
type ID3DXLINE;
type LPID3DXLINE is access all ID3DXLINE;
subtype LPD3DXLINE is LPID3DXLINE;
type LPLPD3DXLINE is access all LPD3DXLINE;
IID_ID3DXLine:constant win32.rpcdce.GUID:=(16#d379ba7f#,16#9042#,16#4ac4#,(16#9f#,16#5e#,16#58#,16#19#,16#2a#,16#4c#,16#6b#,16#d8#));
type ID3DXLine is record
QueryInterface:access procedure(THIS:LPID3DXLine;iid:REFIID;ppv:LPLPVOID) with Convention=>Stdcall;
AddRef:access function(THIS:LPID3DXLine) return ULONG with Convention=>Stdcall;
Release:access function(THIS:LPID3DXLine) return ULONG with Convention=>Stdcall;
GetDevice:access procedure(THIS:LPID3DXLine;ppDevice:LPLPIDIRECT3DDEVICE9) with Convention=>Stdcall;
Beginn:access procedure(THIS:LPID3DXLine) with Convention=>Stdcall;
Draw:access procedure(THIS:LPID3DXLine;pVertexList:access constant D3DVECTOR2;dwVertexListCount:DWORD;Color:D3DCOLOR) with Convention=>Stdcall;
DrawTransform:access procedure(THIS:LPID3DXLine;pVertexList:access constant D3DVECTOR3;dwVertexListCount:DWORD;pTransform:access constant D3DMATRIX;Color:D3DCOLOR) with Convention=>Stdcall;
SetPattern:access procedure(THIS:LPID3DXLine;dwPattern:DWORD) with Convention=>Stdcall;
GetPattern:access function(THIS:LPID3DXLine) return DWORD with Convention=>Stdcall;
SetPatternScale:access procedure(THIS:LPID3DXLine;fPatternScale:FLOAT) with Convention=>Stdcall;
GetPatternScale:access function(THIS:LPID3DXLine) return FLOAT with Convention=>Stdcall;
SetWidth:access procedure(THIS:LPID3DXLine;fWidth:FLOAT) with Convention=>Stdcall;
GetWidth:access function(THIS:LPID3DXLine) return FLOAT with Convention=>Stdcall;
SetAntialias:access procedure(THIS:LPID3DXLine;bAntialias:BOOL) with Convention=>Stdcall;
GetAntialias:access function(THIS:LPID3DXLine) return BOOL with Convention=>Stdcall;
SetGLLines:access procedure(THIS:LPID3DXLine;bGLLines:BOOL) with Convention=>Stdcall;
GetGLLines:access function(THIS:LPID3DXLine) return BOOL with Convention=>Stdcall;
Endd:access procedure(THIS:LPID3DXLine) with Convention=>Stdcall;
OnLostDevice:access procedure(THIS:LPID3DXLine) with Convention=>Stdcall;
OnResetDevice:access procedure(THIS:LPID3DXLine) with Convention=>Stdcall;
end record;
function D3DXCreateLine(pDevice:LPDIRECT3DDEVICE9;ppLine:LPLPD3DXLINE) return HRESULT with Import,Convention=>stdcall,external_name=>"D3DXCreateLine";
end d3dx9core;
Ada计算机图形DirectX之d3dx9core
猜你喜欢
转载自blog.csdn.net/adacore/article/details/83050456
今日推荐
周排行