diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2020-01-28 18:39:33 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2020-01-28 18:39:37 +0300 |
commit | 3fd4c88e3a2e9d99d45a0856fcc339e013c0a79a (patch) | |
tree | c9349a1f1fc7e80b113ce4110891e27992c12e98 /source/blender/draw/intern/draw_cache.h | |
parent | fd0bc7e002ced8ffd85e9aa3edcae173dbd13392 (diff) |
Fix T72593 Blender crashes when modifier change the material count
Instead of changing the modifiers behavior, we make sure to always use
the data->totcol instead of the ob->totcol. Also we centralize getting
this number to avoid future issues.
Fix T72593 Blender crashes when separating mesh
Fix T72017 Crash on set visibility change
Diffstat (limited to 'source/blender/draw/intern/draw_cache.h')
-rw-r--r-- | source/blender/draw/intern/draw_cache.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/source/blender/draw/intern/draw_cache.h b/source/blender/draw/intern/draw_cache.h index 11564464546..a77a847409b 100644 --- a/source/blender/draw/intern/draw_cache.h +++ b/source/blender/draw/intern/draw_cache.h @@ -59,6 +59,7 @@ struct GPUBatch **DRW_cache_object_surface_material_get(struct Object *ob, int **auto_layer_is_srgb, int *auto_layer_count); struct GPUBatch *DRW_cache_object_face_wireframe_get(struct Object *ob); +int DRW_cache_object_material_count_get(struct Object *ob); /* Empties */ struct GPUBatch *DRW_cache_plain_axes_get(void); @@ -138,8 +139,6 @@ struct GPUBatch *DRW_cache_mesh_surface_weights_get(struct Object *ob); struct GPUBatch *DRW_cache_mesh_surface_mesh_analysis_get(struct Object *ob); struct GPUBatch *DRW_cache_mesh_face_wireframe_get(struct Object *ob); -void DRW_cache_mesh_sculpt_coords_ensure(struct Object *ob); - /* Curve */ struct GPUBatch *DRW_cache_curve_surface_get(struct Object *ob); struct GPUBatch **DRW_cache_curve_surface_shaded_get(struct Object *ob, |