Class GPUDeviceDX11
Implementation of Graphics Device for DirectX 11 backend.
Inherited Members
Assembly: FlaxEngine.dll
File: Engine/GraphicsDevice/DirectX/DX11/GPUDeviceDX11.h
Syntax
public class GPUDeviceDX11 : public GPUDeviceDX
Constructors
~GPUDeviceDX11()
Declaration
public ~GPUDeviceDX11()
GPUDeviceDX11(IDXGIFactory* dxgiFactory, GPUAdapterDX* adapter)
Declaration
public GPUDeviceDX11(IDXGIFactory* dxgiFactory, GPUAdapterDX* adapter)
Parameters
IDXGIFactory
dxgiFactory
|
GPUAdapterDX
adapter
|
Methods
Create()
CreateBuffer(const StringView& name)
Creates the buffer.
Declaration
public virtual GPUBuffer* CreateBuffer(const StringView& name) override
Parameters
StringView
name
The resource name. |
Returns
GPUBuffer
The buffer. |
Overrides
CreateConstantBuffer(uint32 size, const StringView& name)
Creates the constant buffer.
Declaration
public virtual GPUConstantBuffer* CreateConstantBuffer(uint32 size, const StringView& name) override
Parameters
uint32
size
The buffer size (in bytes). |
StringView
name
The resource name. |
Returns
GPUConstantBuffer
The constant buffer. |
Overrides
CreatePipelineState()
Creates the GPU pipeline state object.
Declaration
public virtual GPUPipelineState* CreatePipelineState() override
Returns
GPUPipelineState
The pipeline state. |
Overrides
CreateSampler()
Creates the texture sampler.
Declaration
public virtual GPUSampler* CreateSampler() override
Returns
GPUSampler
The sampler. |
Overrides
CreateShader(const StringView& name)
Creates the shader.
Declaration
public virtual GPUShader* CreateShader(const StringView& name) override
Parameters
StringView
name
The resource name. |
Returns
GPUShader
The shader. |
Overrides
CreateSwapChain(Window* window)
Creates the native window swap chain.
Declaration
public virtual GPUSwapChain* CreateSwapChain(Window* window) override
Parameters
Window
window
The output window. |
Returns
GPUSwapChain
The native window swap chain. |
Overrides
CreateTexture(const StringView& name)
Creates the texture.
Declaration
public virtual GPUTexture* CreateTexture(const StringView& name) override
Parameters
StringView
name
The resource name. |
Returns
GPUTexture
The texture. |
Overrides
CreateTimerQuery()
Creates the timer query object.
Declaration
public virtual GPUTimerQuery* CreateTimerQuery() override
Returns
GPUTimerQuery
The timer query. |
Overrides
CreateVertexLayout(const VertexElements& elements, bool explicitOffsets)
Declaration
public GPUVertexLayout* CreateVertexLayout(const VertexElements& elements, bool explicitOffsets) override
Parameters
VertexElements
elements
|
bool
explicitOffsets
|
Returns
GPUVertexLayout
|
Dispose()
Clean all allocated data by device
Declaration
public virtual void Dispose() override
Overrides
DrawEnd()
Called during Draw method after rendering. Cannot be used to submit commands to GPU.
Declaration
public virtual void DrawEnd() override
Overrides
GetBlendState(const BlendingMode& blending)
Declaration
public ID3D11BlendState* GetBlendState(const BlendingMode& blending)
Parameters
BlendingMode
blending
|
Returns
ID3D11BlendState
|
GetDepthStencilState(const void* descriptionPtr)
Declaration
public ID3D11DepthStencilState* GetDepthStencilState(const void* descriptionPtr)
Parameters
void
descriptionPtr
|
Returns
ID3D11DepthStencilState
|
GetDevice()
Declaration
public ID3D11Device* GetDevice() const
Returns
ID3D11Device
|
GetDummyVB()
GetDXGIFactory()
Declaration
public IDXGIFactory* GetDXGIFactory() const
Returns
IDXGIFactory
|
GetIM()
Declaration
public ID3D11DeviceContext* GetIM() const
Returns
ID3D11DeviceContext
|
GetMainContext()
Gets the main GPU context.
Declaration
public virtual GPUContext* GetMainContext() override
Returns
GPUContext
|
Overrides
GetMainContextDX11()
GetNativePtr()
Gets the native pointer to the underlying graphics device. It's a low-level platform-specific handle.
Declaration
public virtual void* GetNativePtr() const override
Returns
void
|
Overrides
Init()
Init device resources
Declaration
public virtual bool Init() override
Returns
bool
True if cannot init, otherwise false. |
Overrides
WaitForGPU()
Wait for GPU end doing submitted work
Declaration
public virtual void WaitForGPU() override