Changeset View
Changeset View
Standalone View
Standalone View
intern/cycles/kernel/kernel_path_branched.h
| Show First 20 Lines • Show All 353 Lines • ▼ Show 20 Lines | #ifdef __VOLUME_DECOUPLED__ | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| /* emission and transmittance */ | /* emission and transmittance */ | ||||
| if(volume_segment.closure_flag & SD_EMISSION) | if(volume_segment.closure_flag & SD_EMISSION) | ||||
| path_radiance_accum_emission(&L, throughput, volume_segment.accum_emission, state.bounce); | path_radiance_accum_emission(&L, throughput, volume_segment.accum_emission, state.bounce); | ||||
| throughput *= volume_segment.accum_transmittance; | throughput *= volume_segment.accum_transmittance; | ||||
| /* free cached steps */ | |||||
| kernel_volume_decoupled_free(kg, &volume_segment); | |||||
| #else | #else | ||||
| /* GPU: no decoupled ray marching, scatter probalistically */ | /* GPU: no decoupled ray marching, scatter probalistically */ | ||||
| int num_samples = kernel_data.integrator.volume_samples; | int num_samples = kernel_data.integrator.volume_samples; | ||||
| float num_samples_inv = 1.0f/num_samples; | float num_samples_inv = 1.0f/num_samples; | ||||
| /* todo: we should cache the shader evaluations from stepping | /* todo: we should cache the shader evaluations from stepping | ||||
| * through the volume, for now we redo them multiple times */ | * through the volume, for now we redo them multiple times */ | ||||
| ▲ Show 20 Lines • Show All 230 Lines • Show Last 20 Lines | |||||