Cycles material What is the syntax to access texture mapping location?
Let's assume Mapping is the unique name/identifier for the Mapping node in question. To find the unique node name, select the node and view the Side panel (N key).



The code to access the Location vector for Mapping is:

&gt;&gt;&gt; bpy.data.materials['Material'].node_tree.nodes['Mapping'].translation
Vector((0.0, 0.0, 0.0))


or more structured

mat = bpy.data.materials['Material']
nodes = mat.node_tree.nodes
mapping = nodes['Mapping']
mapping.translation = 1.0, 0, 0   # accepts tuple


Hover over the properties and the tooltip will give a hint as to where to find most properties. But for materials, the path is via data.materials and not data.node_groups as the tooltip suggests.