Ada计算机图形DirectX之d3d10misc

----------------------------------------
-- File : d3d10misc.ads               --
-- Translator:Dongfeng.Gu,2018/10/21  --
-- Mail: 515639@qq.com                --
-- Progress:100%                      --
----------------------------------------

with win32;                  use win32;
with win32.rpcdce;           use win32.rpcdce;
with win32.windef;           use win32.windef;
with Win32.objbase;          use win32.objbase;

with DXGI;                   use DXGI;
with d3d10;                  use d3d10;

package d3d10misc is

   type ID3D10BLOB;
   type LPID3D10BLOB is access all ID3D10Blob;
   type LPLPID3D10BLOB is access all LPID3D10BLOB;
   subtype LPD3D10BLOB is LPID3D10Blob;
   subtype LPLPD3D10BLOB is LPLPID3D10BLOB;

   IID_ID3D10Blob: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 ID3D10Blob is record
      QueryInterface:access procedure(THIS:LPID3D10Blob;iid:REFIID;ppv:LPLPVOID) with Convention=>Stdcall;
      AddRef:access function(THIS:LPID3D10Blob) return ULONG with Convention=>Stdcall;
      Release:access function(THIS:LPID3D10Blob) return ULONG with Convention=>Stdcall;
      GetBufferPointer:access function(THIS:LPID3D10Blob) return LPVOID with Convention=>Stdcall;
      GetBufferSize:access function(THIS:LPID3D10Blob) return SIZE_T with Convention=>Stdcall;
   end record;

   type D3D10_DRIVER_TYPE is (D3D10_DRIVER_TYPE_HARDWARE,
                              D3D10_DRIVER_TYPE_REFERENCE,
                              D3D10_DRIVER_TYPE_NULL,
                              D3D10_DRIVER_TYPE_SOFTWARE,
                              D3D10_DRIVER_TYPE_WARP);
   for D3D10_DRIVER_TYPE use (D3D10_DRIVER_TYPE_HARDWARE=>0,
                              D3D10_DRIVER_TYPE_REFERENCE=>1,
                              D3D10_DRIVER_TYPE_NULL=>2,
                              D3D10_DRIVER_TYPE_SOFTWARE=>3,
                              D3D10_DRIVER_TYPE_WARP=>5);

   type LPD3D10_DRIVER_TYPE is access D3D10_DRIVER_TYPE;

   GUID_DeviceType:constant win32.rpcdce.GUID:=(16#d722fb4d#,16#7a68#,16#437a#,(16#b2#,16#0c#,16#58#,16#04#,16#ee#,16#24#,16#94#,16#a6#));
   function D3D10CreateDevice(pAdapter:LPIDXGIAdapter;DriverType:D3D10_DRIVER_TYPE;Software:HMODULE;Flags:UINT;SDKVersion:UINT;ppDevice:LPLPID3D10Device) return HRESULT with Import,Convention=>stdcall,external_name=>"D3D10CreateDevice";

   function D3D10CreateDeviceAndSwapChain(pAdapter:LPIDXGIAdapter;DriverType:D3D10_DRIVER_TYPE;Software:HMODULE;Flags:UINT;SDKVersion:UINT;pSwapChainDesc:LPDXGI_SWAP_CHAIN_DESC;ppSwapChain:LPLPIDXGISwapChain;ppDevice:LPLPID3D10Device) return HRESULT with Import,Convention=>stdcall,external_name=>"D3D10CreateDeviceAndSwapChain";

   function D3D10CreateBlob(NumBytes:SIZE_T;ppBuffer:LPLPD3D10BLOB) return HRESULT with Import,Convention=>stdcall,external_name=>"D3D10CreateBlob";


   --
   -- THE END.
   --



end d3d10misc;

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值