D3DResourceType 列舉

定義

指定與 D3DImage 類別相容的 Direct3D 介面型別。

C#
public enum D3DResourceType
繼承
D3DResourceType

欄位

名稱 Description
IDirect3DSurface9 0

指定 IDirect3DSurface9 介面。

範例

下列程式碼範例示範如何在呼叫 SetBackBuffer 方法中指定 D3DResourceType 。 如需詳細資訊,請參閱 逐步解說:在 WPF 中裝載 Direct3D9 內容

C#
d3dimg.Lock();
// Repeatedly calling SetBackBuffer with the same IntPtr is 
// a no-op. There is no performance penalty.
d3dimg.SetBackBuffer(D3DResourceType.IDirect3DSurface9, pSurface);
HRESULT.Check(Render());
d3dimg.AddDirtyRect(new Int32Rect(0, 0, d3dimg.PixelWidth, d3dimg.PixelHeight));
d3dimg.Unlock();

備註

D3DResourceType當您在 方法中指派 Direct3D 表面時, D3DImage.SetBackBuffer 請使用 。

適用於

產品 版本
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9, 10

另請參閱