Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2019-05-30 00:52:37 +0300
committerClément Foucault <foucault.clem@gmail.com>2019-05-30 14:43:33 +0300
commit596492e639f07b6a0a3f705a0f944dc57f94b7e4 (patch)
tree55f3dfa9ee3ad03c90954bec26f7c85157dc2d1b /source/blender/draw/engines/eevee/eevee_lightprobes.c
parent32a2bfddcb4b0dedbea987ae3e335dc6aecdaed8 (diff)
DRW: Refactor to use object pointer for drawcall by default
This cleans up a bit of duplicated code and some confusion about what was culled and what wasn't. Now everything is culled based on the given object pointer. If the object pointer is NULL there is no culling performed.
Diffstat (limited to 'source/blender/draw/engines/eevee/eevee_lightprobes.c')
-rw-r--r--source/blender/draw/engines/eevee/eevee_lightprobes.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/draw/engines/eevee/eevee_lightprobes.c b/source/blender/draw/engines/eevee/eevee_lightprobes.c
index 6253a9d3808..bbad169f363 100644
--- a/source/blender/draw/engines/eevee/eevee_lightprobes.c
+++ b/source/blender/draw/engines/eevee/eevee_lightprobes.c
@@ -398,7 +398,7 @@ void EEVEE_lightprobes_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedat
DRW_shgroup_uniform_block(grp, "planar_block", sldata->planar_ubo);
DRW_shgroup_uniform_block(grp, "grid_block", sldata->grid_ubo);
- DRW_shgroup_call_procedural_triangles(grp, cube_len * 2, NULL);
+ DRW_shgroup_call_procedural_triangles(grp, NULL, cube_len * 2);
}
/* Grid Display */
@@ -424,7 +424,7 @@ void EEVEE_lightprobes_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedat
DRW_shgroup_uniform_block(shgrp, "grid_block", sldata->grid_ubo);
DRW_shgroup_uniform_block(shgrp, "common_block", sldata->common_ubo);
int tri_count = egrid->resolution[0] * egrid->resolution[1] * egrid->resolution[2] * 2;
- DRW_shgroup_call_procedural_triangles(shgrp, tri_count, NULL);
+ DRW_shgroup_call_procedural_triangles(shgrp, NULL, tri_count);
}
}
@@ -787,7 +787,7 @@ void EEVEE_lightprobes_cache_finish(EEVEE_ViewLayerData *sldata, EEVEE_Data *ved
DRW_shgroup_uniform_texture_ref(grp, "source", &txl->planar_pool);
DRW_shgroup_uniform_float(grp, "fireflyFactor", &sldata->common_data.ssr_firefly_fac, 1);
- DRW_shgroup_call_procedural_triangles(grp, pinfo->num_planar, NULL);
+ DRW_shgroup_call_procedural_triangles(grp, NULL, pinfo->num_planar);
}
}