Hello, I'm just getting into the Python API. Currently, I have been successful adding a subsurface modifier to an object, but I can't seem to wrap my head around how to set the view level and render level for the modifier, once applied. I have tried the documentation, but can't seem to figure it out.
My code so far:
>>>bpy.ops.mesh.primitive_ico_sphere_add()
{'FINISHED'}
>>>bpy.ops.object.shade_smooth()
{'FINISHED'}
>>>bpy.ops.object.modifier_add(type='SUBSURF')
{'FINISHED'}
Any help is greatly appreciated.
Awesome. Thanks. Exactly what I was looking for.