I can’t find the answer to how to select an existing node through the script and apply the already added image without a GUI.
I have a ready-made script that opens a prepared blender file with saved materials, makes an import of the SVG curve and performs manipulations by adding these materials.
In one of the materials I need to change one picture. I found a code that can add a node with a new picture
import bpy bpy.data.images.load("D:/temp/1.png", check_existing=True) mat = bpy.context.view_layer.objects.active.active_material tex = bpy.data.images.get('1.png') image_node = mat.node_tree.nodes.new('ShaderNodeTexImage') image_node.image = tex
This code created a new unconnected node and it needs to be connected to three other nodes. But I need only assign an already linked picture to the already connected node.