Plasma Engine  2.0
Loading...
Searching...
No Matches
ShaderPermutationBinary.h
1#pragma once
2
3#include <Foundation/IO/DependencyFile.h>
4#include <RendererCore/Declarations.h>
5#include <RendererCore/Shader/ShaderStageBinary.h>
6#include <RendererFoundation/Descriptors/Descriptors.h>
7
8struct PL_RENDERERCORE_DLL plShaderStateResourceDescriptor
9{
13
14 plResult Parse(const char* szSource);
15 void Load(plStreamReader& inout_stream);
16 void Save(plStreamWriter& inout_stream) const;
17
18 plUInt32 CalculateHash() const;
19};
20
22class PL_RENDERERCORE_DLL plShaderPermutationBinary
23{
24public:
26
27 plResult Write(plStreamWriter& inout_stream);
28 plResult Read(plStreamReader& inout_stream, bool& out_bOldVersion);
29
30 // Actual binary will be loaded from the hash via plShaderStageBinary::LoadStageBinary to produce plShaderStageBinary
31 plUInt32 m_uiShaderStageHashes[plGALShaderStage::ENUM_COUNT];
32
33 plDependencyFile m_DependencyFile;
34
35 plShaderStateResourceDescriptor m_StateDescriptor;
36
38};
This class represents a set of files of which one wants to know when any one of them changes.
Definition DependencyFile.h:15
A hybrid array uses in-place storage to handle the first few elements without any allocation....
Definition HybridArray.h:12
Serialized state of a shader permutation used by plShaderPermutationResourceLoader to convert into a ...
Definition ShaderPermutationBinary.h:23
Interface for binary in (read) streams.
Definition Stream.h:22
Interface for binary out (write) streams.
Definition Stream.h:107
Definition Descriptors.h:70
Describes the settings for a new rasterizer state. See plGALDevice::CreateRasterizerState.
Definition Descriptors.h:105
Default enum for returning failure or success, instead of using a bool.
Definition Types.h:54
Definition ShaderPermutationBinary.h:9