internal Device() { var flags = d3d.DeviceCreationFlags.VideoSupport | d3d.DeviceCreationFlags.BgraSupport; d3dDevice = new d3d.Device(SharpDX.Direct3D.DriverType.Hardware, flags); d3dDevice1 = d3dDevice.QueryInterface <d3d.Device1>(); dxgiDevice = d3dDevice.QueryInterface <dxgi.Device>(); d2dDevice = new d2.Device(dxgiDevice); ImagingFactory = new wic.ImagingFactory2(); }
internal CDevice() { var flags = d3d.DeviceCreationFlags.BgraSupport; d3dDevice = new d3d.Device(DriverType.Hardware, flags); Device = d3dDevice.QueryInterface <d3d.Device1>(); dxgiDevice = d3dDevice.QueryInterface <dxgi.Device>(); dxgiDevice1 = dxgiDevice.QueryInterface <dxgi.Device1>(); dxgiAdapter = dxgiDevice.Adapter.QueryInterface <dxgi.Adapter>(); dxgiFactory = dxgiAdapter.GetParent <dxgi.Factory>(); CreateResources(); }