Fix crash when constant buffer is unused by shader but still exists
This commit is contained in:
@@ -281,13 +281,7 @@ bool ReflectionsPass::setupResources()
|
||||
if (!_sphereModel->CanBeRendered() || !_preIntegratedGF->IsLoaded() || !_shader->IsLoaded())
|
||||
return true;
|
||||
const auto shader = _shader->GetShader();
|
||||
|
||||
// Validate shader constant buffer size
|
||||
if (shader->GetCB(0)->GetSize() != sizeof(Data))
|
||||
{
|
||||
REPORT_INVALID_SHADER_PASS_CB_SIZE(shader, 0, Data);
|
||||
return true;
|
||||
}
|
||||
CHECK_INVALID_SHADER_PASS_CB_SIZE(shader, 0, Data);
|
||||
|
||||
// Create pipeline stages
|
||||
GPUPipelineState::Description psDesc;
|
||||
|
||||
Reference in New Issue
Block a user