From afb4e0ab972776eb17e97ca8f3be02c64e77cf46 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Mon, 11 Oct 2021 16:17:27 +0300 Subject: [PATCH] Clear reflect data before adding shader stages Otherwise it prevents the number of clip distances from being recorded. --- source/core/program.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/core/program.cpp b/source/core/program.cpp index 4707f4c0..1a7ac17b 100644 --- a/source/core/program.cpp +++ b/source/core/program.cpp @@ -17,6 +17,8 @@ void Program::add_stages(const Module &mod, const map &spec_values) if(has_stages()) throw invalid_operation("Program::add_stages"); + reflect_data = ReflectData(); + TransientData transient; switch(mod.get_format()) { @@ -30,8 +32,6 @@ void Program::add_stages(const Module &mod, const map &spec_values) throw invalid_argument("Program::add_stages"); } - reflect_data = ReflectData(); - finalize(mod); if(mod.get_format()==Module::GLSL) -- 2.45.2