Need Input on how to handle socket drawing for Multi Input Sockets

Hi, I’m Fabian and I’m currently developing Multi Input Sockets https://developer.blender.org/D10067

This is a new input socket type, that can handle multiple inputs.
It has the shape of a long rectangle which height is depends on the number of links that are connected to it.

Currently Sockets are drawn as GL_POINTS and the same shader that is used to draw the keyframe diamonds, and this is not ideal for drawing long rectangles.
Because of this I use GL_TRIS in my current version and a native node socket shader.

This leads to some discussion.

The current code supports that sockets can be drawn as any other keyframe shape (circle, circle with dot, diamond, diamond with dot, square, square with dot). I have never seen them to be used as node socket shape and I assume that even if we would need other shapes in the future, we don’t want to reuse all the keyframe shapes.

Supporting them would eigher require to make the the node socket shader a lot more crowded or to keep sockets to be drawn in two different ways, which may be more difficult to maintain. And maybe a bit tricky to make them look and behave the same, because GL_POINTS have some quirks.

How should we handle this?

  1. Do we further want to support the other Keyframe shapes for sockets any longer?
  2. If we do. Should we implement them into the new shader or should we keep drawing the socktes in two different ways?
4 Likes

I honestly feel like having other shapes for the inputs is unnecessary. Other than just elongating the circle like this for multiple inputs (I assume it has a cap?), I don’t feel I would want other shapes, the colors already do a good job. Pablo Vasquez seems to be talking about blending between colors if the data type is different between nodes, :
https://ui.pablovazquez.art/
I feel like that is already plenty of visual feedback