WIP: Experiment: Nodes: Add new shader for node sockets #119243

Draft
Leon Schittek wants to merge 15 commits from lone_noel/blender:node-socket-shader into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
Member

Experiment to create a shader specifically for node sockets rather than
using the keyframe shader.

Motivation:

  1. Simplify socket drawing by avoiding special handling of multi-inputs
  2. Support multi-input sockets for all socket types (diamond, square, etc.)

While there currently is no need for (2.) internally, there are a few
obvious use-cases for multi-input field (diamond) sockets like generalized
math nodes with an arbitrary number of inputs (Add, Multiply, Minimum etc.).

Screenshots
The changes for the wide reroute node below are not included in this PR.
It's only there to show how the socket shader can be used.

Round Diamond Square
socket-showcase_round_2.png socket-showcase_diamond_2.png socket-showcase_square_2.png
Experiment to create a shader specifically for node sockets rather than using the keyframe shader. Motivation: 1. Simplify socket drawing by avoiding special handling of multi-inputs 2. Support multi-input sockets for all socket types (diamond, square, etc.) While there currently is no need for (2.) internally, there are a few obvious use-cases for multi-input field (diamond) sockets like generalized math nodes with an arbitrary number of inputs (Add, Multiply, Minimum etc.). **Screenshots** The changes for the wide reroute node below are not included in this PR. It's only there to show how the socket shader can be used. |Round|Diamond|Square| |---|---|---| |![socket-showcase_round_2.png](/attachments/9b7ec0de-c963-4d62-9bc0-d09e6c7e0385)|![socket-showcase_diamond_2.png](/attachments/df4eea2f-83ad-473b-876a-e2d97256ee53)|![socket-showcase_square_2.png](/attachments/f6e23395-f0cc-40ee-9abb-26d6ecec8b8c)|
Leon Schittek added 4 commits 2024-03-09 10:55:52 +01:00
Leon Schittek changed title from WIP: Experiment: Add new shader specifically for node sockets to WIP: Experiment: Nodes: Add new shader for node sockets 2024-03-09 10:56:28 +01:00
Leon Schittek added the
Interest
Nodes & Physics
label 2024-03-09 10:57:05 +01:00
Iliya Katushenock added the
Interest
EEVEE & Viewport
label 2024-03-09 11:07:01 +01:00
Leon Schittek added 2 commits 2024-03-15 14:13:18 +01:00
Leon Schittek added 3 commits 2024-03-29 13:27:29 +01:00
Jacques Lucke added 1 commit 2024-06-04 14:59:27 +02:00
Jacques Lucke added 5 commits 2024-06-04 15:18:18 +02:00
Member

Generally looks like the right direction. Right now I mainly wonder why per-socket properties are passed as uniform parameters instead of as separate buffer which can have arbitrary size. It seems unconventional to have to limit the batch size to e.g. 32 sockets.

Generally looks like the right direction. Right now I mainly wonder why per-socket properties are passed as uniform parameters instead of as separate buffer which can have arbitrary size. It seems unconventional to have to limit the batch size to e.g. 32 sockets.
Jacques Lucke requested review from Jacques Lucke 2024-06-04 15:20:10 +02:00
This pull request has changes conflicting with the target branch.
  • source/blender/editors/space_node/node_draw.cc

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u node-socket-shader:lone_noel-node-socket-shader
git checkout lone_noel-node-socket-shader
Sign in to join this conversation.
No reviewers
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
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
Asset Browser Project
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
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#119243
No description provided.