Changeset View
Changeset View
Standalone View
Standalone View
source/blender/draw/intern/draw_cache_impl_mesh.c
| Show First 20 Lines • Show All 963 Lines • ▼ Show 20 Lines | void DRW_mesh_batch_cache_free_old(Mesh *me, int ctime) | ||||
| mesh_cd_layers_type_clear(&cache->cd_used_over_time); | mesh_cd_layers_type_clear(&cache->cd_used_over_time); | ||||
| } | } | ||||
| /* Can be called for any surface type. Mesh *me is the final mesh. */ | /* Can be called for any surface type. Mesh *me is the final mesh. */ | ||||
| void DRW_mesh_batch_cache_create_requested( | void DRW_mesh_batch_cache_create_requested( | ||||
| Object *ob, Mesh *me, const Scene *scene, const bool is_paint_mode, const bool use_hide) | Object *ob, Mesh *me, const Scene *scene, const bool is_paint_mode, const bool use_hide) | ||||
| { | { | ||||
| const ToolSettings *ts = scene->toolsettings; | const ToolSettings *ts = NULL; | ||||
| if (scene) { | |||||
| ts = scene->toolsettings; | |||||
| } | |||||
| MeshBatchCache *cache = mesh_batch_cache_get(me); | MeshBatchCache *cache = mesh_batch_cache_get(me); | ||||
| /* Early out */ | /* Early out */ | ||||
| if (cache->batch_requested == 0) { | if (cache->batch_requested == 0) { | ||||
| #ifdef DEBUG | #ifdef DEBUG | ||||
| goto check; | goto check; | ||||
| #endif | #endif | ||||
| return; | return; | ||||
| ▲ Show 20 Lines • Show All 329 Lines • Show Last 20 Lines | |||||