Renderer/RenderPass: Implement RenderPass correctly
This commit is contained in:
@@ -11,6 +11,96 @@
|
||||
|
||||
namespace Nz
|
||||
{
|
||||
enum class AttachmentLoadOp
|
||||
{
|
||||
Clear,
|
||||
Discard,
|
||||
Load
|
||||
};
|
||||
|
||||
enum class AttachmentStoreOp
|
||||
{
|
||||
Discard,
|
||||
Store
|
||||
};
|
||||
|
||||
enum class MemoryAccess
|
||||
{
|
||||
ColorRead,
|
||||
ColorWrite,
|
||||
DepthStencilRead,
|
||||
DepthStencilWrite,
|
||||
IndexBufferRead,
|
||||
IndirectCommandRead,
|
||||
HostRead,
|
||||
HostWrite,
|
||||
MemoryRead,
|
||||
MemoryWrite,
|
||||
ShaderRead,
|
||||
ShaderWrite,
|
||||
TransferRead,
|
||||
TransferWrite,
|
||||
UniformBufferRead,
|
||||
VertexBufferRead,
|
||||
|
||||
Max = VertexBufferRead
|
||||
};
|
||||
|
||||
template<>
|
||||
struct EnumAsFlags<MemoryAccess>
|
||||
{
|
||||
static constexpr MemoryAccess max = MemoryAccess::Max;
|
||||
};
|
||||
|
||||
using MemoryAccessFlags = Flags<MemoryAccess>;
|
||||
|
||||
enum class PipelineStage
|
||||
{
|
||||
TopOfPipe,
|
||||
|
||||
ColorOutput,
|
||||
DrawIndirect,
|
||||
FragmentShader,
|
||||
FragmentTestsEarly,
|
||||
FragmentTestsLate,
|
||||
GeometryShader,
|
||||
TessellationControlShader,
|
||||
TessellationEvaluationShader,
|
||||
Transfer,
|
||||
TransformFeedback,
|
||||
VertexInput,
|
||||
VertexShader,
|
||||
|
||||
BottomOfPipe,
|
||||
|
||||
Max = BottomOfPipe
|
||||
};
|
||||
|
||||
template<>
|
||||
struct EnumAsFlags<PipelineStage>
|
||||
{
|
||||
static constexpr PipelineStage max = PipelineStage::Max;
|
||||
};
|
||||
|
||||
using PipelineStageFlags = Flags<PipelineStage>;
|
||||
|
||||
enum class QueueType
|
||||
{
|
||||
Compute,
|
||||
Graphics,
|
||||
Transfer,
|
||||
|
||||
Max = Transfer
|
||||
};
|
||||
|
||||
template<>
|
||||
struct EnumAsFlags<QueueType>
|
||||
{
|
||||
static constexpr QueueType max = QueueType::Max;
|
||||
};
|
||||
|
||||
using QueueTypeFlags = Flags<QueueType>;
|
||||
|
||||
enum class RenderAPI
|
||||
{
|
||||
Direct3D, ///< Microsoft Render API, only works on MS platforms
|
||||
@@ -53,22 +143,17 @@ namespace Nz
|
||||
SpirV
|
||||
};
|
||||
|
||||
enum class QueueType
|
||||
enum class TextureLayout
|
||||
{
|
||||
Compute,
|
||||
Graphics,
|
||||
Transfer,
|
||||
|
||||
Max = Transfer
|
||||
ColorInput,
|
||||
ColorOutput,
|
||||
DepthStencilInput,
|
||||
DepthStencilOutput,
|
||||
Present,
|
||||
TransferSource,
|
||||
TransferDestination,
|
||||
Undefined
|
||||
};
|
||||
|
||||
template<>
|
||||
struct EnumAsFlags<QueueType>
|
||||
{
|
||||
static constexpr QueueType max = QueueType::Max;
|
||||
};
|
||||
|
||||
using QueueTypeFlags = Flags<QueueType>;
|
||||
}
|
||||
|
||||
#endif // NAZARA_ENUMS_RENDERER_HPP
|
||||
|
||||
Reference in New Issue
Block a user