Page MenuHome

Cycles renders volumetrics very differently on CPU vs. GPU
Confirmed, NormalPublicKNOWN ISSUE


I stumbled on this very inconsistency while working on some volumetrics where a notable difference in render results for CPU vs. GPU became visible. This effect appears for both Path Tracing and Branched Path Tracing for all types of lamps, and it gets more prominent on low sample rates. This difference is too strong to be acceptable when using a render farm with a mix of systems.

Following both images have been rendered with exactly the same settings on CPU top and GPU bellow for 1 SPP (so should look the same):

Here with 2 SPP:

Here is the blend file to test:

Tested with latest official build bot release on Win7 64.
Hardware: i7-980X, GTX 480

Event Timeline

Kai Kostack (kaikostack) updated the task description. (Show Details)
Kai Kostack (kaikostack) updated the task description. (Show Details)
Kai Kostack (kaikostack) updated the task description. (Show Details)
Lukas Stockner (lukasstockner97) lowered the priority of this task from 90 to 50.Dec 7 2016, 5:52 PM

Yes, I can reproduce the issue.
The difference is caused by decoupled sampling, which is currently enabled on CPUs and disabled on CUDA. So, there are two ways to fix this problem - either allow the user to disable it on the CPU, or enable in on CUDA.
I'm not sure why it's disabled on CUDA right now, though.

Decoupled Ray Marching for homogeneous volumes should work on GPU (when enabled via ifdefs of course), but when I tested that, it wasn't stable. For heterogenous volumes, the current code uses dynamic mem alloc, which is slow on GPU and was giving me mem errors. That was 1-2 years ago though, situation might have changed.

I can take a look and see if we can enable it.. We shouldn't add an option to disable that on CPU, that's exactly the kind of UI clutter that we should avoid.


Here I mention some other examples where I encounter problems with volumetrics. I am not good with nodes, so I apologize if this is due to my mistakes with configuration.
In the following example there are differences between GPU and CPU render:

In the following example I get flickering when orbit the view in rendered view, but same problem with CPU and GPU:

With GPU, in both cases it seems to be acting as Reflection coordinate to be default when there is nothing connected to Normal in Layer Weight. That is, apparently no problem if for example I connect Generated or Object coordinate.

Layer weight makes no sense for volumes, it requires a normal which is not available there. There may be a bug there but the shader node setup is not a practical one.

Ok, sorry, Perhaps obvious to experienced people, but Layer Weight Node documentation did not clarify anything about not usefull for Volume. Now I have just found the right way to do what I intended to do in cycles:

Thanks for the clarification.

The answer from that link seems correct to me, using the layer weight to control the transparency of the surface, with a fixed volume in the interior.

Yes, that nodes setup from the link makes a lot more sense. I just thought that to do something like that could be as easy as mixing two Emission Nodes connected to Volume, and controlling the weight with Layer Weight. I am very bad with nodes, my mistake.

Brecht Van Lommel (brecht) changed the subtype of this task from "Report" to "Known Issue".Jan 8 2020, 6:17 PM