Skip to main content

All Questions

47 votes
3 answers
28k views

Control Cycles/Eevee material nodes and material properties using python?

How can I define the different properties of an Cycles/Eevee material? Such things as glossy, glass, diffuse, RGB-color, emissive via python scripting?
binaryBigInt's user avatar
  • 1,047
41 votes
1 answer
51k views

How to assign a new material to an object in the scene from Python?

How can I assign a new material to an object in the scene via Python?
binaryBigInt's user avatar
  • 1,047
15 votes
2 answers
3k views

PyNodes, the bare basics

I know it's a very new thing (post 2.4 era anyways) but there seems to be very little documentation and examples for PyNodes in general, and the little there is doesn't seem to work in latest SVN (...
Greg Zaal's user avatar
  • 10.8k
7 votes
1 answer
4k views

How to set a background using the cycles render engine with the API

I'm just getting started with the Blender API, and I'm trying to set the background texture using the API. In the GUI, I do the following: Choose the Cycles render engine ...
Ajay T's user avatar
  • 115
5 votes
1 answer
787 views

Graph bar with elevation/height values

How can I get a graph legend that automatically gets my maximum and minimum elevation from an object? Basically, I have an object that dinamically paints other with waves. I have a node setup that ...
MCunha's user avatar
  • 1,263
5 votes
2 answers
283 views

Accessing image texture uv channel connected to Cycles material Image Texture

Trying to figure out how to read the uv channel used by an Image Texture input from Python. So, in effect, how to access the "Vector", then grab the attribute name:
Steve Williams's user avatar
4 votes
0 answers
749 views

Copy node tree from one material to another in cycles using python

I have two cycles materials (say source and target). I want to copy the Shader Nodetree from the source material to the target material after clearing any currently present node tree(s) in the target ...
Varun kumar's user avatar
3 votes
3 answers
1k views

Any way of serializing Blender cycles materials data?

I am searching of ways to serialize Blender Cycles materials to files using Python. But as of now I've found no such ways. Maybe by writing the data of the materials to files but how can I do that? ...
Farhan Anam's user avatar
3 votes
1 answer
1k views

Change field of a node in a group

I am trying to make a script that will change the value of a specific node within a specific node group. I have seen from this question how to target a node within a material, but I can't see how to ...
Ascalon's user avatar
  • 6,647
3 votes
1 answer
272 views

Setting all default_values of nodes to 0 does not result in expected black output

What I am trying to accomplish? I am iterating over all nodes of one named material from the output node and going backwards and want to set all inputs.default_value to 0. I use the Code from ...
Kevin Streicher's user avatar
3 votes
1 answer
388 views

copy linked materials nodes to local material

DISCLAIMER: I rewrite my post upon the latest success to not flood my own post with already solved parts so I left only the part that really is still not working... PROBLEM: I need to replace all ...
bublible's user avatar
  • 111
3 votes
0 answers
389 views

Example of creating and setting a Cycles material node with the Python API [duplicate]

I'm trying to set the properties of a Cycles material, which is linked to a Plane object, using the API. So far this is what I'...
Ajay T's user avatar
  • 115
2 votes
2 answers
397 views

Same Video on each face, but with different time delay?

iam looking for a way to - like the title says - i want to put the same video on each face, but with different time delay. In other words, i want to create a kind of videowall. i found THIS: ...
froggyman's user avatar
  • 503
2 votes
1 answer
403 views

Extracting a text string info (character's indices) to use it as a material mask

I think an image can say more than words sometimes... :) The idea is to use a different color from the color ramp for each character in the string. It's related to this question
Bithur's user avatar
  • 8,284
2 votes
2 answers
2k views

Getting the image of a texture node that feeds into a node group

I have a Cycles material node group like this: I can access the user-specified color (red) like this: ...
jdurrant's user avatar

15 30 50 per page