godot/scene/resources
Tom Coxon 9e9bac1549 Prevent shaders from generating code before the constructor finishes.
Fixes #43733: "creating SpatialMaterial in a separate thread creates invalid
shaders (temporarily)."

The bug occurred because various setters called in materials' constructors add
materials to queues that are processed on the main thread. This means that
when the materials are created in another thread, they can be processed on the
main thread before the constructor has finished.

The fix adds a flag to affected materials that prevents them from being added
to the queue until their constructors have finished initialising all the
members.
2021-09-21 11:47:51 +01:00
..
default_theme Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
animation.cpp Add animation reset track feature 2021-05-09 09:40:16 +02:00
animation.h Add animation reset track feature 2021-05-09 09:40:16 +02:00
audio_stream_sample.cpp Remove duplicate WARN_PRINTS macro 2021-06-18 12:57:59 +01:00
audio_stream_sample.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
bit_map.cpp BitMask::create Don't request more memory than needed when size is a multiply of 8 2021-05-18 11:58:09 +02:00
bit_map.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
box_shape.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
box_shape.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
capsule_shape.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
capsule_shape.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
capsule_shape_2d.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
capsule_shape_2d.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
circle_shape_2d.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
circle_shape_2d.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
concave_polygon_shape.cpp Fix crash on debug shapes update if CollisionObject is not in tree 2021-05-22 17:33:51 +02:00
concave_polygon_shape.h Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
concave_polygon_shape_2d.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
concave_polygon_shape_2d.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
convex_polygon_shape.cpp Replace QuickHull with Bullet's convex hull computer. 2021-05-22 08:16:43 +02:00
convex_polygon_shape.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
convex_polygon_shape_2d.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
convex_polygon_shape_2d.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
curve.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
curve.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
cylinder_shape.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
cylinder_shape.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
dynamic_font.cpp Allow using WOFF fonts in DynamicFont 2021-08-25 08:09:23 +02:00
dynamic_font.h [3.x] Fix building with the FreeType module disabled 2021-07-29 21:47:40 -05:00
environment.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
environment.h Style: Remove redundant void argument lists 2021-05-04 16:40:33 +02:00
font.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
font.h Style: Replaces uses of 0/NULL by nullptr (C++11) 2021-05-04 16:30:23 +02:00
gradient.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
gradient.h Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
height_map_shape.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
height_map_shape.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
line_shape_2d.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
line_shape_2d.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
material.cpp Prevent shaders from generating code before the constructor finishes. 2021-09-21 11:47:51 +01:00
material.h Prevent shaders from generating code before the constructor finishes. 2021-09-21 11:47:51 +01:00
mesh.cpp Octahedral Normal/Tangent Compression 2021-07-30 10:29:09 -04:00
mesh.h Octahedral Normal/Tangent Compression 2021-07-30 10:29:09 -04:00
mesh_data_tool.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
mesh_data_tool.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
mesh_library.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
mesh_library.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
multimesh.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
multimesh.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
occluder_shape.cpp Sphere occluders (portals and general use) 2021-08-17 09:02:06 +01:00
occluder_shape.h Sphere occluders (portals and general use) 2021-08-17 09:02:06 +01:00
packed_scene.cpp Remove side effects of scene save 2021-06-29 13:13:06 +02:00
packed_scene.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
particles_material.cpp Prevent shaders from generating code before the constructor finishes. 2021-09-21 11:47:51 +01:00
particles_material.h Prevent shaders from generating code before the constructor finishes. 2021-09-21 11:47:51 +01:00
physics_material.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
physics_material.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
plane_shape.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
plane_shape.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
polygon_path_finder.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
polygon_path_finder.h Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
primitive_meshes.cpp Merge pull request #48763 from QbieShay/plane-offset 2021-07-12 10:32:19 +02:00
primitive_meshes.h added offset for plane mesh and quad mesh 2021-05-17 22:07:16 +02:00
ray_shape.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
ray_shape.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
rectangle_shape_2d.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
rectangle_shape_2d.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
resource_format_text.cpp VariantParser: Fix uninitialized ResourceParser funcs 2021-08-03 09:33:25 +02:00
resource_format_text.h Fix external resource cache regression 2021-06-16 16:07:04 -07:00
SCsub SCons: Add explicit dependencies on thirdparty code in cloned env 2021-04-29 16:57:00 +02:00
segment_shape_2d.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
segment_shape_2d.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
shader.cpp [3.x] Allow reading shaders from .gdshader files 2021-07-19 23:34:23 -04:00
shader.h Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
shape.cpp Merge pull request #48316 from nekomatata/expose-physics-debug-shape-3.x 2021-05-05 15:17:48 +02:00
shape.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
shape_2d.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
shape_2d.h Added option in project settings to draw Shape2D outlines 2021-02-25 07:48:33 -07:00
skin.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
skin.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
sky.cpp Remove high radiance sizes from the editor due to issues on specific GPUs 2021-05-20 23:54:12 +02:00
sky.h CPU lightmapper environment energy fixes. 2021-04-22 16:26:04 +02:00
sphere_shape.cpp Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
sphere_shape.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
style_box.cpp StyleBox fake AA improvements (aa_size float property) 2021-08-12 22:21:34 +02:00
style_box.h StyleBox fake AA improvements (aa_size float property) 2021-08-12 22:21:34 +02:00
surface_tool.cpp Check input mesh is valid in SurfaceTool methods 2021-05-09 00:38:17 +02:00
surface_tool.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
text_file.cpp Make all file access 64-bit (uint64_t) 2021-05-16 17:52:31 +02:00
text_file.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
texture.cpp Merge pull request #51402 from tinmanjuggernaut/texture_array_anisotropic 2021-08-13 08:46:22 +02:00
texture.h Add Anisotropic Filtering option for TextureArrays 2021-08-12 23:56:03 +08:00
theme.cpp Add support for partial custom editor themes 2021-08-14 02:11:54 +03:00
theme.h Add support for partial custom editor themes 2021-08-14 02:11:54 +03:00
tile_set.cpp Fix selection of spaced atlas tile when using priority 2021-07-26 20:05:59 +08:00
tile_set.h Style: Replaces uses of 0/NULL by nullptr (C++11) 2021-05-04 16:30:23 +02:00
video_stream.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
visual_shader.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
visual_shader.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00
visual_shader_nodes.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
visual_shader_nodes.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
world.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
world.h Update copyright statements to 2021 2021-01-13 16:17:06 +01:00
world_2d.cpp Style: Enforce braces around if blocks and loops 2021-05-05 15:02:01 +02:00
world_2d.h Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks 2021-05-04 14:45:16 +02:00