2
$\begingroup$

What is the use of a "Group Input" directly in the Node tree of the material? Note, not within a nodes group

It can be easily added to the material nodes tree, but I don't understand its usefulness.

Is there any particular function? If so, which one?

enter image description here

Note:

I know what a group inputs node in the node group is for. So my question is specific what it is for in a node_tree of the material.

If anyone is 100% sure that the "Group input" node in the material node_tree is useless, please explain why

$\endgroup$
16
  • 2
    $\begingroup$ I don't think that it is useful out of the node group itself, it is useful in the node group, if you want to create another set of inputs or outputs $\endgroup$
    – moonboots
    Sep 10, 2022 at 14:54
  • $\begingroup$ +1 moonboots ... probably they should not be accessible from GUI out of node group or be able to copy-paste out of group at all. $\endgroup$
    – vklidu
    Sep 10, 2022 at 15:55
  • $\begingroup$ I describe your "within a nodes group" use below. Unlike Geometry nodes -- where Group Inputs and Group Outputs appear in the GeometryNodes modifier, there is no such access to defined variables in the top level of a material node. In some ways the shader editor doesn't know that you're inside a group or at a top level. $\endgroup$
    – james_t
    Sep 10, 2022 at 16:44
  • 1
    $\begingroup$ Semantically node group trees and top level node trees are the same. The information is stored in its user's properties, but any node tree can have an indefinite number of users. I think there is no way to know the information "this node tree is top level" without first having to iterate over all nodes of all node trees of all materials in the scene to check if this particular node tree isn't used as a node group. So the answer would be : "none". But it's computationally expensive to check if this node should be available in the context of a node tree. My 2 cents $\endgroup$
    – Gorgious
    Sep 11, 2022 at 19:56
  • 1
    $\begingroup$ @MarkusvonBroady idk exactly when this had changed but it was working around 09/2020 as you can see here: devtalk.blender.org/t/how-useful-could-be-a-material-input-node/… $\endgroup$
    – Secrop
    Sep 19, 2022 at 17:43

2 Answers 2

3
+25
$\begingroup$

The reason is simply that there's a bug with the poll function for the GroupInput and the GroupOutput (perhaps because those are now being yielded by a generator).

As this is something that is not checked in the typical tests, and most developers aren't looking for these kind of defects, it's one of those little strange things that finds its way into the final release.

It's not a priority bug and probably nobody reported it, so no developer has picked it and solved it.

$\endgroup$
1
  • $\begingroup$ Meanwhile, a patch was commited and new versions of Blender should have this fixed. $\endgroup$
    – Secrop
    Sep 21, 2022 at 10:38
1
$\begingroup$

This is super-quirky, but if make a custom group out of a single node, inputs and outputs are automatically connected, but you can control the order of inputs using the Group Input node - for example, if you want the Scale and Detail of Noise Texture to be last:

Notice how the types of sockets don't matter for this.

Same for Group Output:


When you convert multiply nodes to a group, you can use Group Input and Group Output to make the input/output connections even before grouping, which is very helpful, even though you can't modify the types and names of Group Input/Group Output sockets:

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .