Skip to main content
added 44 characters in body
Source Link

I've spent far too long googling for this answer. :)

I have a Cycles shader node group called ProteinVR that I created using the node editor. It has two inputs: enter image description here

This same node group is used by multiple users (i.e., different objects in the scene use the same node group to generate their materials), but with different inputs. So a different object might look like this: enter image description here

I then load the scene from the command line like this:

/my/blender/exec/blender -b /my/blender/file.blend -P /my/blender/script.py

Within the /my/blender/script.py file, I want to be able to determine the input values (color or glossiness) of the node group for each user (object). I've found how to access the node group itself and explore its structure and default values programmatically, but I can't get the specific values being used for each user/object.

Any help you could offer would be most appreciated! First question on stack exchange... hope it goes well. :)

P.S. Blender 2.78, in case it's helpful.

I've spent far too long googling for this answer. :)

I have a Cycles shader node group called ProteinVR that I created using the node editor. It has two inputs: enter image description here

This same node group is used by multiple users (i.e., different objects in the scene use the same node group to generate their materials), but with different inputs. So a different object might look like this: enter image description here

I then load the scene from the command line like this:

/my/blender/exec/blender -b /my/blender/file.blend -P /my/blender/script.py

Within the /my/blender/script.py file, I want to be able to determine the input values (color or glossiness) of the node group for each user (object). I've found how to access the node group itself and explore its structure and default values programmatically, but I can't get the specific values being used for each user/object.

Any help you could offer would be most appreciated! First question on stack exchange... hope it goes well. :)

I've spent far too long googling for this answer. :)

I have a Cycles shader node group called ProteinVR that I created using the node editor. It has two inputs: enter image description here

This same node group is used by multiple users (i.e., different objects in the scene use the same node group to generate their materials), but with different inputs. So a different object might look like this: enter image description here

I then load the scene from the command line like this:

/my/blender/exec/blender -b /my/blender/file.blend -P /my/blender/script.py

Within the /my/blender/script.py file, I want to be able to determine the input values (color or glossiness) of the node group for each user (object). I've found how to access the node group itself and explore its structure and default values programmatically, but I can't get the specific values being used for each user/object.

Any help you could offer would be most appreciated! First question on stack exchange... hope it goes well. :)

P.S. Blender 2.78, in case it's helpful.

Source Link

Getting the actual (not default) input value of a node group for a specific user

I've spent far too long googling for this answer. :)

I have a Cycles shader node group called ProteinVR that I created using the node editor. It has two inputs: enter image description here

This same node group is used by multiple users (i.e., different objects in the scene use the same node group to generate their materials), but with different inputs. So a different object might look like this: enter image description here

I then load the scene from the command line like this:

/my/blender/exec/blender -b /my/blender/file.blend -P /my/blender/script.py

Within the /my/blender/script.py file, I want to be able to determine the input values (color or glossiness) of the node group for each user (object). I've found how to access the node group itself and explore its structure and default values programmatically, but I can't get the specific values being used for each user/object.

Any help you could offer would be most appreciated! First question on stack exchange... hope it goes well. :)