47 const size_t iSizeInBytes = iVariableCount *
sizeof(
variable_type);
49 Error error(std::format(
50 "failed to create shader constants manager with size {} bytes because the maximum "
51 "allowed size is {} bytes",
59 if (iVariableCount == 0) [[unlikely]] {
60 Error error(
"failed to create shader constants manager because the specified size is zero");
79 "the specified push/root constant index {} is out of bounds (max: {})",
std::string getFullErrorMessage() const
Definition: Error.cpp:84
void showError() const
Definition: Error.cpp:102
void error(std::string_view sText, const std::source_location location=std::source_location::current()) const
Definition: Logger.cpp:75
static Logger & get()
Definition: Logger.cpp:41
Definition: PipelineShaderConstantsManager.hpp:14
unsigned int variable_type
Definition: PipelineShaderConstantsManager.hpp:17
static constexpr size_t iMaxShaderConstantsSizeInBytes
Definition: PipelineShaderConstantsManager.hpp:120
void * getData()
Definition: PipelineShaderConstantsManager.hpp:113
static constexpr size_t getMaxConstantsSizeInBytes()
Definition: PipelineShaderConstantsManager.hpp:34
PipelineShaderConstantsManager(size_t iVariableCount)
Definition: PipelineShaderConstantsManager.hpp:45
unsigned int getVariableCount() const
Definition: PipelineShaderConstantsManager.hpp:104
std::vector< variable_type > vConstantsData
Definition: PipelineShaderConstantsManager.hpp:117
unsigned int getTotalSizeInBytes() const
Definition: PipelineShaderConstantsManager.hpp:94
void copyValueToShaderConstant(size_t iShaderConstantIndex, unsigned int iValueToCopy)
Definition: PipelineShaderConstantsManager.hpp:75
Definition: PipelineShaderConstantsManager.hpp:24
static constexpr auto pShadowPassLightInfoIndex
Definition: PipelineShaderConstantsManager.hpp:26