ホーム › Media.DirectShow › IVMRSurfaceAllocator9
IVMRSurfaceAllocator9
COMメソッド 4
vtbl = vtable インデックス(0始まり)。HSP等からCOMメソッドをインデックス指定で呼ぶ際に使用します。0〜2 は IUnknown。
vtbl 3 HRESULT InitializeDevice(UINT_PTR dwUserID, VMR9AllocationInfo* lpAllocInfo, DWORD* lpNumBuffers)
| dwUserID | UINT_PTR | in | アロケータを一意に識別する呼び出し側定義のユーザーID。AdviseSurfaceAllocatorで渡した値が返る。 |
| lpAllocInfo | VMR9AllocationInfo* | in | 確保すべきサーフェスの形式・サイズ・用途を記述するVMR9AllocationInfo構造体へのポインタ。 |
| lpNumBuffers | DWORD* | inout | 入力で要求バッファ数、出力で実際に確保された数を受け取るDWORDへのポインタ。 |
| dwID | UINT_PTR | in | 破棄対象のデバイスを示すユーザーID。InitializeDeviceで渡したdwUserIDに対応する。 |
vtbl 5 HRESULT GetSurface(UINT_PTR dwUserID, DWORD SurfaceIndex, DWORD SurfaceFlags, IDirect3DSurface9** lplpSurface)
| dwUserID | UINT_PTR | in | 対象アロケータを識別する呼び出し側定義のユーザーID。 |
| SurfaceIndex | DWORD | in | 取得するサーフェスの0起点インデックス。確保したバッファ数未満を指定する。 |
| SurfaceFlags | DWORD | in | サーフェス取得時の動作を指定するフラグ。通常は0を指定する。 |
| lplpSurface | IDirect3DSurface9** | out | 取得したIDirect3DSurface9インターフェイスを受け取る出力ポインタ。呼び出し側が解放する。 |
vtbl 6 HRESULT AdviseNotify(IVMRSurfaceAllocatorNotify9* lpIVMRSurfAllocNotify)
| lpIVMRSurfAllocNotify | IVMRSurfaceAllocatorNotify9* | in | アロケータがVMR9へ通知を返すためのIVMRSurfaceAllocatorNotify9インターフェイスへのポインタ。 |
HSP用 COM定義
#usecom / #comfunc によるHSPのCOM呼び出し定義。数字は vtbl インデックス(0始まり)。クラスIDが無い場合 #usecom の末尾は "{}"、ある場合は "{CLSID}"。
出力引数:
#define global IID_IVMRSurfaceAllocator9 "{8D5148EA-3F5D-46CF-9DF1-D1B896EEDB1F}" #usecom global IVMRSurfaceAllocator9 IID_IVMRSurfaceAllocator9 "{}" #comfunc global IVMRSurfaceAllocator9_InitializeDevice 3 sptr,var,var #comfunc global IVMRSurfaceAllocator9_TerminateDevice 4 sptr #comfunc global IVMRSurfaceAllocator9_GetSurface 5 sptr,int,int,sptr #comfunc global IVMRSurfaceAllocator9_AdviseNotify 6 sptr ; ※数字は vtbl インデックス(0始まり)。0/1/2 は IUnknown(QueryInterface/AddRef/Release)。 ; ※このインターフェースは直接 CoCreateInstance するクラスIDが無いため "{}"(他メソッド/アクティベーションで取得)。 ; ※出力/バッファ引数は var(変数直渡し)。varptr 方式にも切替可。 ; ※ハンドル/void*等の不透明ポインタは IronHSP では intptr 指定が可能。#define global IID_IVMRSurfaceAllocator9 "{8D5148EA-3F5D-46CF-9DF1-D1B896EEDB1F}" #usecom global IVMRSurfaceAllocator9 IID_IVMRSurfaceAllocator9 "{}" #comfunc global IVMRSurfaceAllocator9_InitializeDevice 3 sptr,sptr,sptr #comfunc global IVMRSurfaceAllocator9_TerminateDevice 4 sptr #comfunc global IVMRSurfaceAllocator9_GetSurface 5 sptr,int,int,sptr #comfunc global IVMRSurfaceAllocator9_AdviseNotify 6 sptr ; ※数字は vtbl インデックス(0始まり)。0/1/2 は IUnknown(QueryInterface/AddRef/Release)。 ; ※このインターフェースは直接 CoCreateInstance するクラスIDが無いため "{}"(他メソッド/アクティベーションで取得)。 ; ※出力/バッファ引数はポインタ方式(token=sptr / 呼び出しは varptr(変数))。 ; ※ハンドル/void*等の不透明ポインタは IronHSP では intptr 指定が可能。