2.93 - Cycles Volumetrics - GPU and CPU results look inverted (Distance vs Equiangular sampling) #89353

Closed
opened 2021-06-22 10:33:18 +02:00 by Carlo Andreacchio · 20 comments

System Information
Operating system: Ubuntu 20.04
Graphics card: GTX 1080

Blender Version
Broken: baa7a53974

Short description of error
Volumetrics - GPU and CPU results look inverted

Exact steps for others to reproduce the error

  1. Open attached blend file
  2. Set render device to CPU
  3. Render
  4. Change render slots
  5. Change render device to GPU
  6. Render
  7. Toggle back and forth.

I have tried to simplify it as much as possible from our node network, the map range node is specifically to enhance the contrast (it previously was a colour ramp into a multiply node)

volumetricBug_v001.blend
image.png
image.png

**System Information** Operating system: Ubuntu 20.04 Graphics card: GTX 1080 **Blender Version** Broken: baa7a53974 **Short description of error** Volumetrics - GPU and CPU results look inverted **Exact steps for others to reproduce the error** 1. Open attached blend file 2. Set render device to CPU 3. Render 4. Change render slots 5. Change render device to GPU 6. Render 7. Toggle back and forth. I have tried to simplify it as much as possible from our node network, the map range node is specifically to enhance the contrast (it previously was a colour ramp into a multiply node) [volumetricBug_v001.blend](https://archive.blender.org/developer/F10187633/volumetricBug_v001.blend) ![image.png](https://archive.blender.org/developer/F10187634/image.png) ![image.png](https://archive.blender.org/developer/F10187636/image.png)

Added subscriber: @candreacchio

Added subscriber: @candreacchio
Member

Added subscriber: @Alaska

Added subscriber: @Alaska
Member

The rendering differences come from the fact CPUs and GPUs render volumes differently in Cycles. CPUs have access to Multi-importance sampling which dynamically adjusts the sampling method of volumes between Distance sampling and Equiangular Sampling depending on what Cycles believes is best. GPU rendering on the other hand only supports Distance sampling.

However, the only rendering difference should be the noise, not the actual look of the volume, something else might be going on here. Might be related to {#80267}?

The rendering differences come from the fact CPUs and GPUs render volumes differently in Cycles. CPUs have access to `Multi-importance sampling` which dynamically adjusts the sampling method of volumes between `Distance sampling` and `Equiangular Sampling` depending on what Cycles believes is best. GPU rendering on the other hand only supports `Distance sampling`. However, the only rendering difference should be the noise, not the actual look of the volume, something else might be going on here. Might be related to {#80267}?

Added subscriber: @iss

Added subscriber: @iss

I can't reproduce this, because my GPU is not capable of rendering volumes, but when I toggle between multiple importance property I did not see any difference in render, so not sure if this plays any role in this case.

I can't reproduce this, because my GPU is not capable of rendering volumes, but when I toggle between multiple importance property I did not see any difference in render, so not sure if this plays any role in this case.
Member

I'm personally able to reproduce the bug. Will wait for someone else's input before confirming the task or merging it.
2021-06-23 09-07-20.mp4

System Information
Operating system: Linux-5.10.0-7-amd64-x86_64-with-glibc2.31 64 Bits
Graphics card: NVIDIA GeForce RTX 3070/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 465.31

Blender Version: 3.0.0 Alpha, branch: master, commit date: 2021-06-22 08:32, hash: ad9fd47d7b

I'm personally able to reproduce the bug. Will wait for someone else's input before confirming the task or merging it. [2021-06-23 09-07-20.mp4](https://archive.blender.org/developer/F10188507/2021-06-23_09-07-20.mp4) **System Information** Operating system: Linux-5.10.0-7-amd64-x86_64-with-glibc2.31 64 Bits Graphics card: NVIDIA GeForce RTX 3070/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 465.31 **Blender Version:** 3.0.0 Alpha, branch: master, commit date: 2021-06-22 08:32, hash: `ad9fd47d7b`

Glad someone is able to confirm im not going crazy...

I can confirm that changing the Volume Sampling to 'Distance', makes the CPU render like the GPU render.

However, when I was simplifying the scene, I was getting the same results when i was changing the step rate / max steps. As a result, I dont believe it is linked to #80267. I may be wrong though!

Glad someone is able to confirm im not going crazy... I can confirm that changing the Volume Sampling to 'Distance', makes the CPU render like the GPU render. However, when I was simplifying the scene, I was getting the same results when i was changing the step rate / max steps. As a result, I dont believe it is linked to #80267. I may be wrong though!
Member

In #89353#1181097, @candreacchio wrote:
Glad someone is able to confirm im not going crazy...

I can confirm that changing the Volume Sampling to 'Distance', makes the CPU render like the GPU render.

However, when I was simplifying the scene, I was getting the same results when i was changing the step rate / max steps. As a result, I dont believe it is linked to #80267. I may be wrong though!

I was able to reduce the rendering difference by changing the step rate and/or scaling down the object. However, I had to change the step rate to a value lower than the soft limit set by Blender (E.G. 0.01) to reduce the rendering difference without scaling the object. I don't really have much else to add. I'll let someone else decide what to do with this report (confirm it as a bug, merge it with another report, or something else)

Maybe Cycles-X will handle volumes in such a way this issue is resolved? I don't know.

> In #89353#1181097, @candreacchio wrote: > Glad someone is able to confirm im not going crazy... > > I can confirm that changing the Volume Sampling to 'Distance', makes the CPU render like the GPU render. > > However, when I was simplifying the scene, I was getting the same results when i was changing the step rate / max steps. As a result, I dont believe it is linked to #80267. I may be wrong though! I was able to reduce the rendering difference by changing the step rate and/or scaling down the object. However, I had to change the step rate to a value lower than the soft limit set by Blender (E.G. 0.01) to reduce the rendering difference without scaling the object. I don't really have much else to add. I'll let someone else decide what to do with this report (confirm it as a bug, merge it with another report, or something else) Maybe Cycles-X will handle volumes in such a way this issue is resolved? I don't know.
Member

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Member

Changed status from 'Needs Triage' to: 'Needs Developer To Reproduce'

Changed status from 'Needs Triage' to: 'Needs Developer To Reproduce'
Member

Can also confirm the difference.

I think at this point it would be good to have a rendering dev comment on this situation (since I would also expect the sampling method to only affect noise/performance -- and not the final values?)

Can also confirm the difference. I think at this point it would be good to have a rendering dev comment on this situation (since I would also expect the sampling method to only affect noise/performance -- and not the final values?)
Philipp Oeser changed title from 2.93 - Cycles Volumetrics - GPU and CPU results look inverted to 2.93 - Cycles Volumetrics - GPU and CPU results look inverted (Distance vs Equiangular sampling) 2021-08-10 16:48:44 +02:00
Member

Added subscriber: @leesonw

Added subscriber: @leesonw
Member

I could not get the images to differ with the latest cycles-x build from the HEAD commit 58ab616d4c6e5d65d9415bb54845eddb0acf54e7 (origin/cycles-x) Have you tested this recently?

I could not get the images to differ with the latest cycles-x build from the HEAD commit 58ab616d4c6e5d65d9415bb54845eddb0acf54e7 (origin/cycles-x) Have you tested this recently?
Member

In #89353#1220546, @leesonw wrote:
I could not get the images to differ with the latest cycles-x build from the HEAD commit 58ab616d4c6e5d65d9415bb54845eddb0acf54e7 (origin/cycles-x) Have you tested this recently?

Can you repro in master though?

> In #89353#1220546, @leesonw wrote: > I could not get the images to differ with the latest cycles-x build from the HEAD commit 58ab616d4c6e5d65d9415bb54845eddb0acf54e7 (origin/cycles-x) Have you tested this recently? Can you repro in master though?
Member

Yes I can repo this on the master branch.

Yes I can repo this on the master branch.
Member

Changed status from 'Needs Developer To Reproduce' to: 'Confirmed'

Changed status from 'Needs Developer To Reproduce' to: 'Confirmed'
Member

Note this appears to be fixed on the cycles-x branch :-) which will probably be merged on Monday.

Note this appears to be fixed on the cycles-x branch :-) which will probably be merged on Monday.

This issue was referenced by blender/cycles@5db8d93df3

This issue was referenced by blender/cycles@5db8d93df3800ed9e90651ca305611c0612e606d

This issue was referenced by 0803119725

This issue was referenced by 08031197250aeecbaca3803254e6f25b8c7b7b37

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Brecht Van Lommel self-assigned this 2021-09-21 15:00:48 +02:00
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
7 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#89353
No description provided.