diff options
Diffstat (limited to 'scene/resources')
-rw-r--r-- | scene/resources/environment.h | 1 | ||||
-rw-r--r-- | scene/resources/material.cpp | 4 | ||||
-rw-r--r-- | scene/resources/skeleton_modification_2d_jiggle.cpp | 2 | ||||
-rw-r--r-- | scene/resources/theme.cpp | 1 | ||||
-rw-r--r-- | scene/resources/theme.h | 1 | ||||
-rw-r--r-- | scene/resources/world_2d.h | 2 | ||||
-rw-r--r-- | scene/resources/world_3d.cpp | 2 |
7 files changed, 8 insertions, 5 deletions
diff --git a/scene/resources/environment.h b/scene/resources/environment.h index dd1e664ca6..b71fe8904a 100644 --- a/scene/resources/environment.h +++ b/scene/resources/environment.h @@ -34,7 +34,6 @@ #include "core/io/resource.h" #include "scene/resources/sky.h" #include "scene/resources/texture.h" -#include "servers/rendering_server.h" class Environment : public Resource { GDCLASS(Environment, Resource); diff --git a/scene/resources/material.cpp b/scene/resources/material.cpp index f3e5ece1f9..b74f44c52f 100644 --- a/scene/resources/material.cpp +++ b/scene/resources/material.cpp @@ -2215,7 +2215,9 @@ BaseMaterial3D::EmissionOperator BaseMaterial3D::get_emission_operator() const { RID BaseMaterial3D::get_shader_rid() const { MutexLock lock(material_mutex); - ((BaseMaterial3D *)this)->_update_shader(); + if (element.in_list()) { // _is_shader_dirty() would create anoder mutex lock + ((BaseMaterial3D *)this)->_update_shader(); + } ERR_FAIL_COND_V(!shader_map.has(current_key), RID()); return shader_map[current_key].shader; } diff --git a/scene/resources/skeleton_modification_2d_jiggle.cpp b/scene/resources/skeleton_modification_2d_jiggle.cpp index eee6067dae..0921417656 100644 --- a/scene/resources/skeleton_modification_2d_jiggle.cpp +++ b/scene/resources/skeleton_modification_2d_jiggle.cpp @@ -29,7 +29,9 @@ /*************************************************************************/ #include "skeleton_modification_2d_jiggle.h" + #include "scene/2d/skeleton_2d.h" +#include "scene/resources/world_2d.h" bool SkeletonModification2DJiggle::_set(const StringName &p_path, const Variant &p_value) { String path = p_path; diff --git a/scene/resources/theme.cpp b/scene/resources/theme.cpp index 901ff22252..373fbb94ea 100644 --- a/scene/resources/theme.cpp +++ b/scene/resources/theme.cpp @@ -29,6 +29,7 @@ /*************************************************************************/ #include "theme.h" + #include "core/string/print_string.h" // Universal Theme resources used when no other theme has the item. diff --git a/scene/resources/theme.h b/scene/resources/theme.h index 7a61ccf8af..9afe05007d 100644 --- a/scene/resources/theme.h +++ b/scene/resources/theme.h @@ -32,7 +32,6 @@ #define THEME_H #include "core/io/resource.h" -#include "core/io/resource_loader.h" #include "scene/resources/font.h" #include "scene/resources/style_box.h" #include "scene/resources/texture.h" diff --git a/scene/resources/world_2d.h b/scene/resources/world_2d.h index 91f9a026d3..4a277c3d84 100644 --- a/scene/resources/world_2d.h +++ b/scene/resources/world_2d.h @@ -31,8 +31,8 @@ #ifndef WORLD_2D_H #define WORLD_2D_H -#include "core/config/project_settings.h" #include "core/io/resource.h" +#include "scene/resources/world_2d.h" #include "servers/physics_server_2d.h" class VisibleOnScreenNotifier2D; diff --git a/scene/resources/world_3d.cpp b/scene/resources/world_3d.cpp index c012ab6177..0088236112 100644 --- a/scene/resources/world_3d.cpp +++ b/scene/resources/world_3d.cpp @@ -30,7 +30,7 @@ #include "world_3d.h" -#include "core/math/camera_matrix.h" +#include "core/config/project_settings.h" #include "core/math/octree.h" #include "scene/3d/camera_3d.h" #include "scene/3d/visible_on_screen_notifier_3d.h" |