Cleanup: Compiler warning in GPU kernel compilation

Silence false positive about function not returning.

Pull Request: https://projects.blender.org/blender/blender/pulls/146178
This commit is contained in:
Brecht Van Lommel
2025-09-20 13:14:35 +02:00
committed by Brecht Van Lommel
parent 21f358a3cb
commit fc8bc41b84

View File

@@ -23,6 +23,12 @@ ccl_device_forceinline VolumeStack volume_stack_read(const IntegratorGenericStat
else {
return integrator_state_read_volume_stack(state, i);
}
# ifdef __KERNEL_GPU__
/* Silence false positive warning with some GPU compilers. */
VolumeStack stack = {};
return stack;
# endif
}
template<const bool shadow, typename IntegratorGenericState>