summaryrefslogtreecommitdiffstats
path: root/scene/resources/visual_shader.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2024-08-27 16:54:50 +0200
committerRémi Verschelde <rverschelde@gmail.com>2024-08-27 16:54:50 +0200
commit21bcff00e96dff88f4e57fe3916e3dd760cae6f4 (patch)
treeb3214bba2d2418302e514820f725e8b57e001ca0 /scene/resources/visual_shader.cpp
parent58beed34954a5b80204c0a7473813574023bf625 (diff)
parentdb251a3f99eadbd26a015bb8a9e701f5723df08c (diff)
downloadredot-engine-21bcff00e96dff88f4e57fe3916e3dd760cae6f4.tar.gz
Merge pull request #95126 from Chaosus/shader_cubemap_fix
Allow setting a cubemap as default parameter to shader
Diffstat (limited to 'scene/resources/visual_shader.cpp')
-rw-r--r--scene/resources/visual_shader.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/resources/visual_shader.cpp b/scene/resources/visual_shader.cpp
index c3665a462c..0113b6f835 100644
--- a/scene/resources/visual_shader.cpp
+++ b/scene/resources/visual_shader.cpp
@@ -2953,7 +2953,7 @@ void VisualShader::_update_shader() const {
const_cast<VisualShader *>(this)->set_code(final_code);
for (int i = 0; i < default_tex_params.size(); i++) {
int j = 0;
- for (List<Ref<Texture2D>>::ConstIterator itr = default_tex_params[i].params.begin(); itr != default_tex_params[i].params.end(); ++itr, ++j) {
+ for (List<Ref<Texture>>::ConstIterator itr = default_tex_params[i].params.begin(); itr != default_tex_params[i].params.end(); ++itr, ++j) {
const_cast<VisualShader *>(this)->set_default_texture_parameter(default_tex_params[i].name, *itr, j);
}
}