Cycles: Add debug pass which shows number of instance pushes during camera ray intersection
TODO: We might want to refactor debug passes into PASS_DEBUG and some debug_type (similar to Blender's side passes) to avoid issue of running out of bits.
This commit is contained in:
@@ -476,6 +476,7 @@ ccl_device float4 kernel_path_integrate(KernelGlobals *kg, RNG *rng, int sample,
|
||||
#ifdef __KERNEL_DEBUG__
|
||||
if(state.flag & PATH_RAY_CAMERA) {
|
||||
debug_data.num_bvh_traversal_steps += isect.num_traversal_steps;
|
||||
debug_data.num_bvh_traversed_instances += isect.num_traversed_instances;
|
||||
}
|
||||
debug_data.num_ray_bounces++;
|
||||
#endif
|
||||
@@ -878,6 +879,7 @@ ccl_device float4 kernel_branched_path_integrate(KernelGlobals *kg, RNG *rng, in
|
||||
#ifdef __KERNEL_DEBUG__
|
||||
if(state.flag & PATH_RAY_CAMERA) {
|
||||
debug_data.num_bvh_traversal_steps += isect.num_traversal_steps;
|
||||
debug_data.num_bvh_traversed_instances += isect.num_traversed_instances;
|
||||
}
|
||||
debug_data.num_ray_bounces++;
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user