July 03, 2011

Deleting a face from a mesh

if you are modifying data of an object, sometimes you want to remove a face
# must be in edit mode.

# first select the face, then delete it.
mplane.data.faces[-1].select = True # won't show in viewport
bpy.ops.mesh.delete(type='ONLY_FACE') # will be acted on.
must be in edit mode for these options, other options for types are found by reading the tooltips in the delete menu.