Page MenuHome

Fix T98501: Setting node socket default value is very slow.
ClosedPublic

Authored by Jacques Lucke (JacquesLucke) on May 31 2022, 7:13 PM.

Details

Summary

The issue was that the extend socket (the last empty socket in Input/Output nodes) was repeatedly removed and added again, which caused more updates than necessary. Now, the extend socket is kept if it existed already.

Diff Detail

Repository
rB Blender

Event Timeline

Jacques Lucke (JacquesLucke) requested review of this revision.May 31 2022, 7:13 PM
Jacques Lucke (JacquesLucke) created this revision.

I just added a question to make sure I understand the context of the change. The code makes sense to me, and I think the idea will to once that confusion is resolved.

source/blender/nodes/intern/node_common.cc
494

Why didn't these add duplicate "extend" sockets in the past? It seems like calling nodeAddSocket unconditionally would do that.

This revision is now accepted and ready to land.May 31 2022, 8:04 PM
source/blender/nodes/intern/node_common.cc
494

Those sockets were removed in group_verify_socket_list and then unconditionally added again.