Remove unavailable sockets and links #104126

Open
opened 2023-01-24 22:53:41 +01:00 by Iliya Katushenock · 5 comments

Yes. Finally, hiding some interface elements will not have business functionality and a bunch of complications in the code.

More about the problem:
The hide (in interface) and unavailable (for processing) sockets is now used to hide the visible (used) list of sockets.
This has consequences:

  1. All sockets exist all the time.
  2. Links to them still exist.
  3. It is not possible to create new sockets without code complexity (previously, for node groups new sockets are created manually in some code places).
    And this brings a lot of complexity to the code.
    Just examples: D16784, D16772, 2b4cb893e7, ...
    And trubbls for python users: #103395 (Node: Incorrect node socket indexing when connecting with python)

The main task:
At the moment, this problem can be solved in several parts :

  1. Different sockets for different node configurations:
    a. Group nodes create their sockets based on node tree declaration: D16850.
    b. Individual nodes create a statically assigned set of sockets depending on the state of the node: D17081.
    c. Nodes for working with multiple data layers (shaders, compositor): based on scene data or some other data. There may be subtleties here. Example task: #70802.
    d. Physics Nodes: Based on what data should be stored in the simulation.
  2. Support for multiple types on a socket as generic socket type:
    a. Argument list of supported types for socket declaration.
    c. Type of socket declaration, that mean evaluation-time type of socket based on context (similar to template node groups)

Also, since the constant deletion and creation of sockets has its consequences, some behavior needs to be recreated. Now it will have more control, which in theory should improve usability:

  1. Simulating data storage for a temporarily remote socket D17136 :
    a. It is possible to store data of node group sockets.
    b. Value conversions when changing the group socket type.
  2. Handling implicitly deleted links for their possible return to their original place.

Code cleanups:

  1. The result of a complete switching to explicit processing of real sockets may be the complete removal of visibility flags for sockets. Or at least move them to the category of deprecated.
  2. As well as the complete removal of the code that processes them.
Yes. Finally, hiding some interface elements will not have business functionality and a bunch of complications in the code. **More about the problem:** The hide (in interface) and unavailable (for processing) sockets is now used to hide the visible (used) list of sockets. This has consequences: 1. All sockets exist all the time. 2. Links to them still exist. 3. It is not possible to create new sockets without code complexity (previously, for node groups new sockets are created manually in some code places). And this brings a lot of complexity to the code. Just examples: [D16784](https://archive.blender.org/developer/D16784), [D16772](https://archive.blender.org/developer/D16772), 2b4cb893e7, ... And trubbls for python users: #103395 (Node: Incorrect node socket indexing when connecting with python) **The main task:** At the moment, this problem can be solved in several parts : 1. Different sockets for different node configurations: a. Group nodes create their sockets based on node tree declaration: [D16850](https://archive.blender.org/developer/D16850). b. Individual nodes create a statically assigned set of sockets depending on the state of the node: [D17081](https://archive.blender.org/developer/D17081). c. Nodes for working with multiple data layers (shaders, compositor): based on scene data or some other data. There may be subtleties here. Example task: #70802. d. Physics Nodes: Based on what data should be stored in the simulation. 2. Support for multiple types on a socket as generic socket type: a. Argument list of supported types for socket declaration. c. Type of socket declaration, that mean evaluation-time type of socket based on context (similar to template node groups) Also, since the constant deletion and creation of sockets has its consequences, some behavior needs to be recreated. Now it will have more control, which in theory should improve usability: 1. Simulating data storage for a temporarily remote socket [D17136](https://archive.blender.org/developer/D17136) : a. It is possible to store data of node group sockets. b. Value conversions when changing the group socket type. 2. Handling implicitly deleted links for their possible return to their original place. **Code cleanups:** 1. The result of a complete switching to explicit processing of real sockets may be the complete removal of visibility flags for sockets. Or at least move them to the category of deprecated. 2. As well as the complete removal of the code that processes them.
Contributor

As a user, will the "Toggle Hidden Node Sockets" (Ctrl+H) feature be impacted by this in any way?

As a user, will the "Toggle Hidden Node Sockets" (Ctrl+H) feature be impacted by this in any way?
Author
Member

This implies removing the functionality to hide sockets. That is, if the socket can be hidden, it will simply be invisible. But yes, I was a bit inaccurate. Hiding just unused sockets SOCK_HIDDEN and functional hiding SOCK_UNAVAIL can be misleading.

This implies removing the functionality to hide sockets. That is, if the socket can be hidden, it will simply be invisible. But yes, I was a bit inaccurate. Hiding just unused sockets `SOCK_HIDDEN` and functional hiding `SOCK_UNAVAIL` can be misleading.
Iliya Katushenock changed title from Remove hidden sockets and links to Remove unavailable sockets and links 2023-01-25 15:19:46 +01:00
Iliya Katushenock added
Meta
Good First Issue
and removed
Interest
Nodes & Physics
labels 2023-02-08 20:15:08 +01:00
Iliya Katushenock added
Interest
Nodes & Physics
and removed
Meta
Good First Issue
labels 2023-03-02 19:41:54 +01:00
Author
Member

I don't know how it got into good first issues, I seem was confuse something

I don't know how it got into good first issues, I seem was confuse something
Iliya Katushenock removed the
Interest
Geometry Nodes
label 2023-03-15 12:20:06 +01:00
Author
Member

General use of dynamic declarations, implicitly implemented here #108728 too

General use of dynamic declarations, implicitly implemented here https://projects.blender.org/blender/blender/issues/108728 too
Author
Member
[Cleanup: Geometry Node: Move some function nodes to use dynamic declarations](https://archive.blender.org/developer/D17081) [Nodes: Temporary socket value save](https://archive.blender.org/developer/D17136)
Iliya Katushenock added this to the Nodes & Physics project 2023-10-10 14:28:34 +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 Assignees
2 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#104126
No description provided.