I’m setting the inputs of a GeometryNode modifier with python, e.g:
obj.modifiers["GeometryNodes"]["Socket_16"] = 4
The input in question is of type ‘Menu’.
Nothing happens. If I then mouse over the modifier stack, the value of the input updates, but the mesh does not change as it is expected to. If I then click the input and rechose the value that’s already seemingly slelected, the mesh updates.
I did see mention of this before when I was looking into using geometry nodes, and have placed:
bpy.context.view_layer.update()
At the end of my code which was recommended, but it’s not doing anything for me.
I also tried:
obj.modifiers["GeometryNodes"].node_group.nodes["Group Output.001"].update()
How can I force it to update correctly?