From a7c6dc23ceeb68b0a7c4555c8645652d18762350 Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Tue, 9 Sep 2025 16:14:32 +0200 Subject: [PATCH] fixed model transition in shaders --- shaders.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/shaders.cpp b/shaders.cpp index de89c9cf..0d4c4fe7 100644 --- a/shaders.cpp +++ b/shaders.cpp @@ -301,7 +301,7 @@ shared_ptr write_shader(flagtype shader_flags) { coordinator += "t = uPP * t;", vsh += "uniform mediump mat4 uPP;"; coordinator += "t = to_square(t);"; } - else if(pmodel == mdBand && hyperbolic) { + else if(pmodel == mdBand && hyperbolic && pconf.model_transition == 1) { shader_flags |= SF_BAND | SF_ORIENT | SF_BOX | SF_DIRECT | SF_NONSPATIAL; coordinator += "t = uPP * t;", vsh += "uniform mediump mat4 uPP;"; if(dim2) coordinator += "mediump float zlev = zlevel(t); t /= zlev;\n"; @@ -635,6 +635,7 @@ void display_data::set_projection(int ed, ld shift) { if(in_s2xe()) id |= 2; if(WDIM == 2 && GDIM == 3 && hyperbolic && context_fog && cgi.emb->is_same_in_same()) id |= 1; id <<= 1; id |= (spatial_graphics ? 1 : 0); + id <<= 1; id |= (pconf.model_transition == 1) ? 0 : 1; shared_ptr selected; if(matched_programs.count(id)) selected = matched_programs[id];