Diligent Engine API Reference: D:/GitHub/DiligentEngine/DiligentCore/Graphics/GraphicsEngine/interface/RenderDevice.h Source File

Diligent Engine API Reference

RenderDevice.h
1 /* Copyright 2015-2018 Egor Yusov
2 *
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 *
7 * http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
10 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
11 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF ANY PROPRIETARY RIGHTS.
12 *
13 * In no event and under no legal theory, whether in tort (including negligence),
14 * contract, or otherwise, unless required by applicable law (such as deliberate
15 * and grossly negligent acts) or agreed to in writing, shall any Contributor be
16 * liable for any damages, including any direct, indirect, special, incidental,
17 * or consequential damages of any character arising as a result of this License or
18 * out of the use or inability to use the software (including but not limited to damages
19 * for loss of goodwill, work stoppage, computer failure or malfunction, or any and
20 * all other commercial damages or losses), even if such Contributor has been advised
21 * of the possibility of such damages.
22 */
23
24 #pragma once
25
28
29 #include "GraphicsTypes.h"
30 #include "Object.h"
31 #include "DeviceCaps.h"
32 #include "Constants.h"
33 #include "Buffer.h"
34 #include "InputLayout.h"
35 #include "Shader.h"
36 #include "Texture.h"
37 #include "Sampler.h"
38 #include "ResourceMapping.h"
39 #include "TextureView.h"
40 #include "BufferView.h"
41 #include "PipelineState.h"
42
43 #include "DepthStencilState.h"
44 #include "RasterizerState.h"
45 #include "BlendState.h"
46
47 namespace Diligent
48 {
49
50 // {F0E9B607-AE33-4B2B-B1AF-A8B2C3104022}
51 static constexpr INTERFACE_ID IID_RenderDevice =
52 { 0xf0e9b607, 0xae33, 0x4b2b, { 0xb1, 0xaf, 0xa8, 0xb2, 0xc3, 0x10, 0x40, 0x22 } };
53
55 class IRenderDevice : public IObject
56 {
57 public:
59 virtual void QueryInterface( const INTERFACE_ID &IID, IObject **ppInterface ) = 0;
60
62
77 virtual void CreateBuffer(const BufferDesc& BuffDesc,
78 const BufferData& BuffData,
79 IBuffer **ppBuffer) = 0;
80
82
89 virtual void CreateShader(const ShaderCreationAttribs &CreationAttribs,
90 IShader **ppShader) = 0;
91
93
114 virtual void CreateTexture(const TextureDesc& TexDesc,
115 const TextureData &Data,
116 ITexture **ppTexture) = 0;
117
119
128 virtual void CreateSampler(const SamplerDesc& SamDesc,
129 ISampler **ppSampler) = 0;
130
132
138 virtual void CreateResourceMapping( const ResourceMappingDesc &MappingDesc,
139 IResourceMapping **ppMapping ) = 0;
140
142
148 virtual void CreatePipelineState( const PipelineStateDesc &PipelineDesc,
149 IPipelineState **ppPipelineState ) = 0;
150
151
153 virtual const DeviceCaps& GetDeviceCaps()const = 0;
154
156
161 virtual const TextureFormatInfo &GetTextureFormatInfo( TEXTURE_FORMAT TexFormat ) = 0;
162
163
165
173 virtual const TextureFormatInfoExt &GetTextureFormatInfoExt( TEXTURE_FORMAT TexFormat ) = 0;
174 };
175
176 }
Diligent::TEXTURE_FORMAT
TEXTURE_FORMAT
Texture formats.
Definition: GraphicsTypes.h:244
Diligent::IRenderDevice::GetTextureFormatInfo
virtual const TextureFormatInfo & GetTextureFormatInfo(TEXTURE_FORMAT TexFormat)=0
Returns the basic texture format information.
Diligent::TextureDesc
Texture description.
Definition: Texture.h:82
Diligent::IRenderDevice
Render device interface.
Definition: RenderDevice.h:55
Diligent::IShader
Shader interface.
Definition: Shader.h:288
Diligent::BufferData
Describes the buffer initial data.
Definition: Buffer.h:176
Diligent
Namespace for the OpenGL implementation of the graphics engine.
Definition: BufferD3D11Impl.h:34
Diligent::IRenderDevice::CreateBuffer
virtual void CreateBuffer(const BufferDesc &BuffDesc, const BufferData &BuffData, IBuffer **ppBuffer)=0
Creates a new buffer object.
Diligent::IRenderDevice::CreateShader
virtual void CreateShader(const ShaderCreationAttribs &CreationAttribs, IShader **ppShader)=0
Creates a new shader object.
Diligent::IRenderDevice::CreateResourceMapping
virtual void CreateResourceMapping(const ResourceMappingDesc &MappingDesc, IResourceMapping **ppMapping)=0
Creates a new resource mapping.
Diligent::DeviceCaps
Device capabilities.
Definition: DeviceCaps.h:96
Diligent::IResourceMapping
Resouce mapping.
Definition: ResourceMapping.h:80
Diligent::TextureData
Describes the initial data to store in the texture.
Definition: Texture.h:243
Diligent::SamplerDesc
Sampler description.
Definition: Sampler.h:52
Diligent::IBuffer
Buffer interface.
Definition: Buffer.h:200
Diligent::ResourceMappingDesc
Resource mapping description.
Definition: ResourceMapping.h:60
Diligent::IRenderDevice::CreateTexture
virtual void CreateTexture(const TextureDesc &TexDesc, const TextureData &Data, ITexture **ppTexture)=0
Creates a new texture object.
Diligent::IRenderDevice::CreateSampler
virtual void CreateSampler(const SamplerDesc &SamDesc, ISampler **ppSampler)=0
Creates a new sampler object.
Diligent::BufferDesc
Buffer description.
Definition: Buffer.h:57
Diligent::IRenderDevice::CreatePipelineState
virtual void CreatePipelineState(const PipelineStateDesc &PipelineDesc, IPipelineState **ppPipelineState)=0
Creates a new pipeline state object.
Diligent::IPipelineState
Definition: PipelineState.h:209
Diligent::TextureFormatInfoExt
Extended texture format description.
Definition: GraphicsTypes.h:1115
Diligent::ISampler
Texture sampler interface.
Definition: Sampler.h:180
Diligent::IRenderDevice::QueryInterface
virtual void QueryInterface(const INTERFACE_ID &IID, IObject **ppInterface)=0
Queries the specific interface, see IObject::QueryInterface() for details.
Diligent::IRenderDevice::GetDeviceCaps
virtual const DeviceCaps & GetDeviceCaps() const =0
Gets the device capabilities, see Diligent::DeviceCaps for details.
Diligent::PipelineStateDesc
Pipeline state description.
Definition: PipelineState.h:179
Diligent::ShaderCreationAttribs
Shader creation attributes.
Definition: Shader.h:204
Diligent::ITexture
Texture inteface.
Definition: Texture.h:276
Diligent::TextureFormatInfo
Basic texture format description.
Definition: GraphicsTypes.h:1101
Diligent::IRenderDevice::GetTextureFormatInfoExt
virtual const TextureFormatInfoExt & GetTextureFormatInfoExt(TEXTURE_FORMAT TexFormat)=0
Returns the extended texture format information.