I'd like to replicate copying (CTRL+C) and pasting (CTRL+V) an object using Python, i.e. the copy should be identical, yet completely independent of the original (i.e., if I change something about the original, the copy should not be affected). While this is easy to achieve for some properties, by copying the object data or calling bpy.ops.object.make_single_user(type='SELECTED_OBJECTS', object=True, obdata=True, material=True, animation=True, obdata_animation=True)
, I did not find a way yet to do this for modifiers, such as geometry nodes. Is there an easy way to achieve this?
Thanks.
bpy.ops.node.copy_geometry_node_group_assign()
$\endgroup$bpy.ops.node.copy_geometry_node_group_assign
is a little sparse, as of now. $\endgroup$