Changeset View
Changeset View
Standalone View
Standalone View
source/blender/draw/intern/draw_cache_extract_mesh.c
| Show First 20 Lines • Show All 4,534 Lines • ▼ Show 20 Lines | |||||
| static void extract_task_create(TaskPool *task_pool, | static void extract_task_create(TaskPool *task_pool, | ||||
| const Scene *scene, | const Scene *scene, | ||||
| const MeshRenderData *mr, | const MeshRenderData *mr, | ||||
| const MeshExtract *extract, | const MeshExtract *extract, | ||||
| void *buf, | void *buf, | ||||
| int32_t *task_counter) | int32_t *task_counter) | ||||
| { | { | ||||
| const bool do_hq_normals = (scene->r.perf_flag & SCE_PERF_HQ_NORMALS) != 0; | const bool do_hq_normals = scene ? ((scene->r.perf_flag & SCE_PERF_HQ_NORMALS) != 0) : false; | ||||
| if (do_hq_normals && (extract == &extract_lnor)) { | if (do_hq_normals && (extract == &extract_lnor)) { | ||||
| extract = &extract_lnor_hq; | extract = &extract_lnor_hq; | ||||
| } | } | ||||
| if (do_hq_normals && (extract == &extract_tan)) { | if (do_hq_normals && (extract == &extract_tan)) { | ||||
| extract = &extract_tan_hq; | extract = &extract_tan_hq; | ||||
| } | } | ||||
| /* Divide extraction of the VBO/IBO into sensible chunks of works. */ | /* Divide extraction of the VBO/IBO into sensible chunks of works. */ | ||||
| ▲ Show 20 Lines • Show All 230 Lines • Show Last 20 Lines | |||||