Cycles viewport unneccessary update calls #76970

Open
opened 2020-05-22 13:51:58 +02:00 by Marco · 36 comments
Member

System Information
Operating system: Ubuntu 20.04
Graphics card: Nvidia MX150

Blender Version
Broken: 2.83.17, 8a8c61190b, Beta and 2.90.2, 8f21f867e7, Alpha
Worked: 2.82a official

Short description of error
#76970.blend

  • set scene renderer to Cycles
  • configure two viewports and a shader editor in a single screen
  • set one viewport to cycles preview render
  • set second viewport to workbench texture color
  • add two image texture nodes and load them with different textures
  • by clicking on the texture node both viewports are redrawn.
**System Information** Operating system: Ubuntu 20.04 Graphics card: Nvidia MX150 **Blender Version** Broken: 2.83.17, 8a8c61190b06, Beta and 2.90.2, 8f21f867e715, Alpha Worked: 2.82a official **Short description of error** [#76970.blend](https://archive.blender.org/developer/F8554990/T76970.blend) * set scene renderer to Cycles * configure two viewports and a shader editor in a single screen * set one viewport to cycles preview render * set second viewport to workbench texture color * add two image texture nodes and load them with different textures * by clicking on the texture node both viewports are redrawn.
Author
Member

Added subscriber: @nacioss

Added subscriber: @nacioss

#76992 was marked as duplicate of this issue

#76992 was marked as duplicate of this issue
Member

Added subscriber: @Alaska

Added subscriber: @Alaska
Member

Changed status from 'Needs Triage' to: 'Confirmed'

Changed status from 'Needs Triage' to: 'Confirmed'
Member

Can confirm. It definitely seems like a bug, but I leave the decision of how to tag this task to the developers as I don't know the reason for why this was changed.

Can confirm. It definitely seems like a bug, but I leave the decision of how to tag this task to the developers as I don't know the reason for why this was changed.
Member

Added subscriber: @Jeroen-Bakker

Added subscriber: @Jeroen-Bakker
Member

Introduced by {27e3361eb5399dc1a700d7f05d5b7b329bc4eafd}

Introduced by {27e3361eb5399dc1a700d7f05d5b7b329bc4eafd}

Added subscriber: @bent

Added subscriber: @bent

Added subscribers: @Sergey, @brecht

Added subscribers: @Sergey, @brecht

This is an issue for Eevee as well, selecting nodes will also restart the render there.

I guess we need more fine grained depsgraph updates. Ideally the viewport would only redraw when the active texture changes and workbench with texture color is selected.

This is an issue for Eevee as well, selecting nodes will also restart the render there. I guess we need more fine grained depsgraph updates. Ideally the viewport would only redraw when the active texture changes and workbench with texture color is selected.

Added subscriber: @Nikhil.Net

Added subscriber: @Nikhil.Net

I have a potential patch that prevents the depgraph update when clicking/dragging on the background. Basically if the selected node is null, it doesn't fire the update.

Is it worth putting into a diff or would that be considered too simplistic a fix?

I have a potential patch that prevents the depgraph update when clicking/dragging on the background. Basically if the selected node is null, it doesn't fire the update. Is it worth putting into a diff or would that be considered too simplistic a fix?

I did add a diff for this and also caught the use case for when a node is simply clicked on but not changed.

The Diff is https://developer.blender.org/D7824. Should I set Sergey as the reviewer?

I did add a diff for this and also caught the use case for when a node is simply clicked on but not changed. The Diff is https://developer.blender.org/D7824. Should I set Sergey as the reviewer?

Added subscriber: @Vyach

Added subscriber: @Vyach

Additional info: #76992 (Regression: Viewport render recalculations when nothing changed in scene.)
Problem exist since 2.80.

Additional info: #76992 (Regression: Viewport render recalculations when nothing changed in scene.) Problem exist since 2.80.

Added subscriber: @APEC

Added subscriber: @APEC
Member
Added subscribers: @YegorSmirnov, @MikhailShablin, @TheRedWaxPolice
Jeroen Bakker self-assigned this 2020-05-25 08:27:03 +02:00

This issue was referenced by 77fdd189e4

This issue was referenced by 77fdd189e4b22d2aa2410109a1a514d21f58d865
Member

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Member

Changed status from 'Resolved' to: 'Confirmed'

Changed status from 'Resolved' to: 'Confirmed'
Member

The current workaround isn't the system we would like to have. The target situation would add a mechanism in the depsgraph where viewports can check if they need to be redrawn.

Currently when you have 2 viewports one Cycles rendered mode and the other in workbench texture mode the updates would still happen.

The current workaround isn't the system we would like to have. The target situation would add a mechanism in the depsgraph where viewports can check if they need to be redrawn. Currently when you have 2 viewports one Cycles rendered mode and the other in workbench texture mode the updates would still happen.

@jabakker imo it is better to have workaround, that work in half of cases, than to have nothing.

But yes, it will be great to have «supervisor», who have list of important changes (and rules), and pokes viewport, when it should rerender view.

@jabakker imo it is better to have workaround, that work in half of cases, than to have nothing. But yes, it will be great to have «supervisor», who have list of important changes (and rules), and pokes viewport, when it should rerender view.
Jeroen Bakker removed their assignment 2020-05-26 14:59:21 +02:00

Thanks guys, I noticed progress in this area today.
Now viewport is not recalculating, when I add routes to disconnected part of tree.
But still called if new disconnected node appears.

Thanks guys, I noticed progress in this area today. Now viewport is not recalculating, when I add routes to disconnected part of tree. But still called if new disconnected node appears.
Member

Added subscriber: @ankitm

Added subscriber: @ankitm
Member

(Linking the two reports, so both can be taken care of, when this one is fixed)
#78358 (Crash while modifying shader nodes ): introduced by 77fdd189e4
Edit: it got fixed.

(Linking the two reports, so both can be taken care of, when this one is fixed) #78358 (Crash while modifying shader nodes ): introduced by 77fdd189e4 Edit: it got fixed.

Added subscriber: @jfmatheu

Added subscriber: @jfmatheu

Added subscriber: @dfelinto

Added subscriber: @dfelinto

Without this being in the BF Blender project it doesn't show in most of the tags.

@Jeroen-Bakker FYI instead of removing 2.93 tag you could have just added "BF Blender" tag that would have automatically removed the 2.93 tag AND kept any BF related tag.

Without this being in the BF Blender project it doesn't show in most of the tags. @Jeroen-Bakker FYI instead of removing 2.93 tag you could have just added "BF Blender" tag that would have automatically removed the 2.93 tag AND kept any BF related tag.

Added subscriber: @silex

Added subscriber: @silex

Hello.
Over some time of work I compiled a short list of conditions when potentially unwanted calls are made. Will posting it here be helpful?
I tested the cases inside one editor window on the default cube with basic Principled BSDF shader.

Hello. Over some time of work I compiled a short list of conditions when potentially unwanted calls are made. Will posting it here be helpful? I tested the cases inside one editor window on the default cube with basic Principled BSDF shader.

Sure, you can post it here.

Sure, you can post it here.

System Information
platform: 'Linux-5.10.0-7-rt-amd64-x86_64-with-glibc2.31'
Graphics card: AMD Radeon VII (VEGA20, DRM 3.40.0, 5.10.0-7-rt-amd64, LLVM 11.0.1) version: '4.6 (Core Profile) Mesa 20.3.4'

Blender Version
Broken: 3.0.0 Alpha, branch: master, commit date: 2021-06-22 12:06, hash: e3bdb189a7

Steps to reproduce:

  1. Open Default scene
  2. Enable addons: Node Wrangler, Node Arrange
  3. Change Workspace to Shading
  4. Change render engine to Cycles

Viewport updates:

Node connection independent:

  • Picking node from a list (topbar, Shift+A)
  • Pasting copied node(s) (topbar, RMB menu, Ctrl+V)
  • Using Shift+RMB on empty space (without cutting any links)
  • Dragging an image from a File Browser Editor into a Shader Editor
  • Renaming any object in a scene (Outliner, F2 in 3D viewport)

On unused nodes (unconnected to Material Output):

  • Removing node(s) (Ctrl+X)
  • Linking two nodes (F)
  • Linking two nodes (Shift+F)
  • Linking two nodes (Alt+Shift on key release)
  • Linking two nodes (Alt+Shift after choosing connection options)
  • Changing node values (any)
  • Reseting a node (Backspace)

On both used and unused nodes:

  • Duplicating node(s) (topbar, RMB menu, Shift+D)
  • Adding reroute(s) (Shift+RMB)
  • Removing reroute(s) (Ctrl+X)
  • Grabbing input/output socket and releasing the link on an empty space
  • Changing node Name or Label (F2, RMB menu, N panel) - also happens with node frames
  • Adding color to a node (clicking checkbox in N panel) - also happens with node frames
  • Changing node color (color picker in N panel) - also happens with node frames
  • Grouping/ungrouping nodes (topbar, RMB menu, Ctrl+G, Ctrl+Alt+G)
  • Group inserting nodes (topbar)

Node Wrangler & Node Arrange addons - here pretty much every action either used through N panel or shortcut triggers a viewport update.

**System Information** platform: 'Linux-5.10.0-7-rt-amd64-x86_64-with-glibc2.31' Graphics card: AMD Radeon VII (VEGA20, DRM 3.40.0, 5.10.0-7-rt-amd64, LLVM 11.0.1) version: '4.6 (Core Profile) Mesa 20.3.4' **Blender Version** Broken: 3.0.0 Alpha, branch: master, commit date: 2021-06-22 12:06, hash: e3bdb189a777 **Steps to reproduce:** 1. Open Default scene 2. Enable addons: Node Wrangler, Node Arrange 3. Change Workspace to Shading 4. Change render engine to Cycles **Viewport updates:** Node connection independent: - Picking node from a list (topbar, Shift+A) - Pasting copied node(s) (topbar, RMB menu, Ctrl+V) - Using Shift+RMB on empty space (without cutting any links) - Dragging an image from a File Browser Editor into a Shader Editor - Renaming any object in a scene (Outliner, F2 in 3D viewport) On unused nodes (unconnected to Material Output): - Removing node(s) (Ctrl+X) - Linking two nodes (F) - Linking two nodes (Shift+F) - Linking two nodes (Alt+Shift on key release) - Linking two nodes (Alt+Shift after choosing connection options) - Changing node values (any) - Reseting a node (Backspace) On both used and unused nodes: - Duplicating node(s) (topbar, RMB menu, Shift+D) - Adding reroute(s) (Shift+RMB) - Removing reroute(s) (Ctrl+X) - Grabbing input/output socket and releasing the link on an empty space - Changing node Name or Label (F2, RMB menu, N panel) - also happens with node frames - Adding color to a node (clicking checkbox in N panel) - also happens with node frames - Changing node color (color picker in N panel) - also happens with node frames - Grouping/ungrouping nodes (topbar, RMB menu, Ctrl+G, Ctrl+Alt+G) - Group inserting nodes (topbar) Node Wrangler & Node Arrange addons - here pretty much every action either used through N panel or shortcut triggers a viewport update.

Ok, we make no effort at all currently to detect which type of node changes need a re-render. If nodes are modified in some way it will refresh. So most listed cases are explained by that.

Object name affect Object Info > Random and potentially OSL scripts, so that also requires a refresh.

Ok, we make no effort at all currently to detect which type of node changes need a re-render. If nodes are modified in some way it will refresh. So most listed cases are explained by that. Object name affect Object Info > Random and potentially OSL scripts, so that also requires a refresh.
Philipp Oeser removed the
Interest
Render & Cycles
label 2023-02-09 14:00:45 +01:00
Author
Member

This is kind of fixed I guess, but I noticed the viewport being redrawn when you select the Material Output node.

This is kind of fixed I guess, but I noticed the viewport being redrawn when you select the Material Output node.

There has indeed been some improvement in this area in the context of improving node updates for geometry nodes. There's still various cases that can be improved though, so will leave this open.

There has indeed been some improvement in this area in the context of improving node updates for geometry nodes. There's still various cases that can be improved though, so will leave this open.
Member

Also: #122458

Also: #122458
Sign in to join this conversation.
14 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: blender/blender#76970
No description provided.