user: How do I use Bpy.Ops.Mesh in Blender? Include parameters, examples, warnings and best practices.

assistant: .0, 0.0) , axis = (0.0, 0.0, 0.0) ) ¶ Extrude selected vertices in screw-shaped rotation around the cursor in indicated viewport Parameters : steps ( int in [ 1 , 100000 ] , ( optional ) ) – Steps, Steps turns ( int in [ 1 , 100000 ] , ( optional ) ) – Turns, Turns center ( mathutils.Vector of 3 items in [-inf, inf], (optional)) – Center, Center in global view space axis ( mathutils.Vector of 3 items in [-1, 1], (optional)) – Axis, Axis in global view space bpy.ops.mesh. select_all ( * , action = 'TOGGLE' ) ¶ (De)select all vertices, edges or faces Parameters : action (enum in [ 'TOGGLE' , 'SELECT' , 'DESELECT' , 'INVERT' ], (optional)) – Action, Selection action to execute TOGGLE Toggle – Toggle selection for all elements. SELECT Select – Select all elements. DESELECT Deselect – Deselect all elements. INVERT Invert – Invert selection of all elements. bpy.ops.mesh. select_axis ( * , orientation = 'LOCAL' , sign = 'POS' , axis = 'X' , threshold = 0.0001 ) ¶ Select all data in the mesh on a single axis Parameters : orientation (enum in Transform Orientation Items , (optional)) – Axis Mode, Axis orientation sign (enum in [ 'POS' , 'NEG' , 'ALIGN' ], (optional)) – Axis Sign, Side to select axis (enum in Axis Xyz Items , (optional)) – Axis, Select the axis to compare each vertex on threshold ( float in [ 1e-06 , 50 ] , ( optional ) ) – Threshold bpy.ops.mesh. select_by_attribute ( ) ¶ Select elements based on the active boolean attribute bpy.ops.mesh. select_by_pole_count ( * , pole_count = 4 , type = 'NOTEQUAL' , extend = False , exclude_nonmanifold = True ) ¶ Select vertices at poles by the number of connected edges. In edge and face mode the geometry connected to the vertices is selected Parameters : pole_count ( int in [ 0 , inf ] , ( optional ) ) – Pole Count type (enum in [ 'LESS' , 'EQUAL' , 'GREATER' , 'NOTEQUAL' ], (optional)) – Type, Type of comparison to make extend ( boolean , ( optional ) ) – Extend, Extend the selection exclude_nonmanifold ( boolean , ( optional ) ) – Exclude Non Manifold, Exclude non-manifold poles bpy.ops.mesh. select_face_by_sides ( * , number = 4 , type = 'EQUAL' , extend = True ) ¶ Select vertices or faces by the number of face sides Parameters : number ( int in [ 3 , inf ] , ( optional ) ) – Number of Vertices type (enum in [ 'LESS' , 'EQUAL' , 'GREATER' , 'NOTEQUAL' ], (optional)) – Type, Type of comparison to make extend ( boolean , ( optional ) ) – Extend, Extend the selection bpy.ops.mesh. select_interior_faces ( ) ¶ Select faces where all edges have more than 2 face users bpy.ops.mesh. select_less ( * , use_face_step = True ) ¶ Deselect vertices, edges or faces at the boundary of each selection region Parameters : use_face_step ( boolean , ( optional ) ) – Face Step, Connected faces (instead of edges) bpy.ops.mesh. select_linked ( * , delimit = {'SEAM'} ) ¶ Select all vertices connected to the current selection Parameters : delimit (enum set in Mesh Delimit Mode Items , (optional)) – Delimit, Delimit selected region bpy.ops.mesh. select_linked_pick ( * , deselect = False , delimit = {'SEAM'} , object_index = -1 , index = -1 ) ¶ (De)select all vertices linked to the edge under the mouse cursor Parameters : deselect ( boolean , ( optional ) ) – Deselect delimit (enum set in Mesh Delimit Mode Items , (optional)) – Delimit, Delimit selected region bpy.ops.mesh. select_loose ( * , extend = False ) ¶ Select loose geometry based on the selection mode Parameters : extend ( boolean , ( optional ) ) – Extend, Extend the selection bpy.ops.mesh. select_mirror ( * , axis = {'X'} , extend = False ) ¶ Select mesh items at mirrored locations Parameters : axis (enum set in Axis Flag Xyz Items , (optional)) – Axis extend ( boolean , ( optional ) ) – Extend, Extend the existing selection bpy.ops.mesh. select_mode ( * , use_extend = False , use_expand = False , type = 'VERT' , action = 'TOGGLE' ) ¶ Change selection mode Parameters : use_extend ( boolean , ( optional ) ) – Extend use_expand ( boolean , ( optional ) ) – Expand type (enum in Mesh Select Mode Items , (optional)) – Type action (enum in [ 'DISABLE' , 'ENABLE' , 'TOGGLE' ], (optional)) – Action, Selection action to execute DISABLE Disable – Disable selected markers. ENABLE Enable – Enable selected markers. TOGGLE Toggle – Toggle disabled flag for selected markers. bpy.ops.mesh. select_more ( * , use_face_step = True ) ¶ Select more vertices, edges or faces connected to initial selection Parameters : use_face_step ( boolean , ( optional ) ) – Face Step, Connected faces (instead of edges) bpy.ops.mesh. select_next_item ( ) ¶ Select the next element (using selection order) File : startup/bl_operators/mesh.py:18 bpy.ops.mesh. select_non_manifold ( * , extend = True , use_wire = True , use_boundary = True , use_multi_face = True , use_non_contiguous = True , use_verts = True ) ¶ Select all non-manifold vertices or edges Parameters : extend ( boolean , ( optional ) ) – Extend, Extend the selection use_wire ( boolean , ( optional ) ) – Wire, Wire edges use_boundary ( boolean , ( optional ) ) – Boundaries, Boundary edges use_multi_face ( boolean , ( optional ) ) – Multiple Faces, Edges shared by more than two faces use_non_contiguous ( boolean , ( optional ) ) – Non Contiguous, Edges between faces pointing in alternate directions use_verts ( boolean , ( optional ) ) – Vertices, Vertices connecting multiple face regions bpy.ops.mesh. select_nth ( * , skip = 1 , nth = 1 , offset = 0 ) ¶ Deselect every Nth element starting from the active vertex, edge or face Parameters : skip ( int in [ 1 , inf ] , ( optional ) ) – Deselected, Number of deselected elements in the repetitive sequence nth ( int in [ 1 , inf ] , ( optional ) ) – Selected, Number of selected elements in the repetitive sequence offset ( int in [ -inf , inf ] , ( optional ) ) – Offset, Offset from the starting point bpy.ops.mesh. select_prev_item ( ) ¶ Select the previous element (using selection order) File : startup/bl_operators/mesh.py:43 bpy.ops.mesh. select_random ( * , ratio = 0.5 , seed = 0 , action = 'SELECT' ) ¶ Randomly select vertices Parameters : ratio ( float in [ 0 , 1 ] , ( optional ) ) – Ratio, Portion of items to select randomly seed ( int in [ 0 , inf ] , ( optional ) ) – Random Seed, Seed for the random number generator action (enum in [ 'SELECT' , 'DESELECT' ], (optional)) – Action, Selection action to execute SELECT Select – Select all elements. DESELECT Deselect – Deselect all elements. bpy.ops.mesh. select_similar ( * , type = 'VERT_NORMAL' , compare = 'EQUAL' , threshold = 0.0 ) ¶ Select similar vertices, edges or faces by property types Parameters : type (enum in [ 'VERT_NORMAL' , 'VERT_FACES' , 'VERT_GROUPS' , 'VERT_EDGES' , 'VERT_CREASE' , 'EDGE_LENGTH' , 'EDGE_DIR' , 'EDGE_FACES' , 'EDGE_FACE_ANGLE' , 'EDGE_CREASE' , 'EDGE_BEVEL' , 'EDGE_SEAM' , 'EDGE_SHARP' , 'EDGE_FREESTYLE' , 'FACE_MATERIAL' , 'FACE_AREA' , 'FACE_SIDES' , 'FACE_PERIMETER' , 'FACE_NORMAL' , 'FACE_COPLANAR' , 'FACE_SMOOTH' , 'FACE_FREESTYLE' ], (optional)) – Type compare (enum in [ 'EQUAL' , 'GREATER' , 'LESS' ], (optional)) – Compare threshold ( float in [ 0 , 100000 ] , ( optional ) ) – Threshold bpy.ops.mesh. select_similar_region ( ) ¶ Select similar face regions to the current selection bpy.ops.mesh. select_ungrouped ( * , extend = False ) ¶ Select vertices without a group Parameters : extend ( boolean , ( optional ) ) – Extend, Extend the selection bpy.ops.mesh. separate ( * , type = 'SELECTED' ) ¶ Separate selected geometry into a new mesh Parameters : type (enum in [ 'SELECTED' , 'MATERIAL' , 'LOOSE' ], (optional)) – Type bpy.ops.mesh. set_normals_from_faces ( * , keep_sharp = False ) ¶ Set the custom normals from the selected faces ones Parameters : keep_sharp ( boolean , ( optional ) ) – Keep Sharp Edges, Do not set sharp edges to face bpy.ops.mesh. set_sharpness_by_angle ( * , angle = 0.523599 , extend = False ) ¶ Set edge sharpness based on the angle between neighboring faces Parameters : angle ( float in [ 0.000174533 , 3.14159 ] , ( optional ) ) – Angle extend ( boolean , ( optional ) ) – Extend, Add new sharp edges without clearing existing sharp edges bpy.ops.mesh. shape_propagate_to_all ( ) ¶ Apply selected vertex locations to all other shape keys bpy.ops.mesh. shortest_path_pick ( * , edge_mode = 'SELECT' , use_face_step = False , use_topology_distance = False , use_fill = False , skip = 0 , nth = 1 , offset = 0 , index = -1 ) ¶ Select shortest path between two selections Parameters : edge_mode (enum in [ 'SELECT' , 'SEAM' , 'SHARP' , 'CREASE' , 'BEVEL' , 'FREESTYLE' ], (optional)) – Edge Tag, The edge flag to tag when selecting the shortest path use_face_step ( boolean , ( optional ) ) – Face Stepping, Traverse connected faces (includes diagonals and edge-rings) use_topology_distance ( boolean , ( optional ) ) – Topology Distance, Find the minimum number of steps, ignoring spatial distance use_fill ( boolean , ( optional ) ) – Fill Region, Select all paths between the source/destination elements skip ( int in [ 0 , inf ] , ( optional ) ) – Deselected, Number of deselected elements in the repetitive sequence nth ( int in [ 1 , inf ] , ( optional ) ) – Selected, Number of selected elements in the repetitive sequence offset ( int in [ -inf , inf ] , ( optional ) ) – Offset, Offset from the starting point bpy.ops.mesh. shortest_path_select ( * , edge_mode = 'SELECT' , use_face_step = False , use_topology_distance = False , use_fill = False , skip = 0 , nth = 1 , offset = 0 ) ¶ Selected shortest path between two vertices/edges/faces Parameters : edge_mode (enum in [ 'SELECT' , 'SEAM' , 'SHARP' , 'CREASE' , 'BEVEL' , 'FREESTYLE' ], (optional)) – Edge Tag, The edge flag to tag when selecting the shortest path use_face_step ( boolean , ( optional ) ) – Face Stepping, Traverse connected faces (includes diagonals and edge-rings) use_topology_distance ( boolean , ( optional ) ) – Topology Distance, Find the minimum number of steps, ignoring spatial distance use_fill ( boolean , ( optional ) ) – Fill Region, Select all paths between the source/destination elements skip ( int in [ 0 , inf ] , ( optional ) ) – Deselected, Number of deselected elements in the repetitive sequence nth ( int in [ 1 , inf ] , ( optional ) ) – Selected, Number of selected elements in the repetitive sequence offset ( int in [ -inf , inf ] , ( optional ) ) – Offset, Offset from the starting point bpy.ops.mesh. smooth_normals ( * , factor = 0.5 ) ¶ Smooth custom normals based on adjacent vertex normals Parameters : factor ( float in [ 0 , 1 ] , ( optional ) ) – Factor, Specifies weight of smooth vs original normal bpy.ops.mesh. solidify ( * , thickness = 0.01 ) ¶ Create a solid skin by extruding, compensating for sharp angles Parameters : thickness ( float in [ -10000 , 10000 ] , ( optional ) ) – Thickness bpy.ops.mesh. sort_elements ( * , type = 'VIEW_ZAXIS' , elements = {'VERT'} , reverse = False , seed = 0 ) ¶ The order of selected vertices/edges/faces is modified, based on a given method Parameters : type (enum in [ 'VIEW_ZAXIS' , 'VIEW_XAXIS' , 'CURSOR_DISTANCE' , 'MATERIAL' , 'SELECTED' , 'RANDOMIZE' , 'REVERSE' ], (optional)) – Type, Type of reordering operation to apply VIEW_ZAXIS View Z Axis – Sort selected elements from farthest to nearest one in current view. VIEW_XAXIS View X Axis – Sort selected elements from left to right one in current view. CURSOR_DISTANCE Cursor Distance – Sort selected elements from nearest to farthest from 3D cursor. MATERIAL Material – Sort selected faces from smallest to greatest material index. SELECTED Selected – Move all selected elements in first places, preserving their relative order. Warning: This will affect unselected elements’ indices as well. RANDOMIZE Randomize – Randomize order of selected elements. REVERSE Reverse – Reverse current order of selected elements. elements (enum set in { 'VERT' , 'EDGE' , 'FACE' }, (optional)) – Elements, Which elements to affect (vertices, edges and/or faces) reverse ( boolean , ( optional ) ) – Reverse, Reverse the sorting effect seed ( int in [ 0 , inf ] , ( optional ) ) – Seed, Seed for random-based operations bpy.ops.mesh. spin ( * , steps = 12 , dupli = False , angle = 1.5708 , use_auto_merge = True , use_normal_flip = False , center = (0.0, 0.0, 0.0) , axis = (0.0, 0.0, 0.0) ) ¶ Extrude selected vertices in a circle around the cursor in indicated viewport Parameters : steps ( int in [ 0 , 1000000 ] , ( optional ) ) – Steps, Steps dupli ( boolean , ( optional ) ) – Use Duplicates angle ( float in [ -inf , inf ] , ( optional ) ) – Angle, Rotation for each step use_auto_merge ( boolean , ( optional ) ) – Auto Merge, Merge first/last when the angle is a full revolution use_normal_flip ( boolean , ( optional ) ) – Flip Normals center ( mathutils.Vector of 3 items in [-inf, inf], (optional)) – Center, Center in global view space axis ( mathutils.Vector of 3 items in [-1, 1], (optional)) – Axis, Axis in global view space bpy.ops.mesh. split ( ) ¶ Split off selected geometry from connected unselected geometry bpy.ops.mesh. split_normals ( ) ¶ Split custom normals of selected vertices bpy.ops.mesh. subdivide ( * , number_cuts = 1 , smoothness = 0.0 , ngon = True , quadcorner = 'STRAIGHT_CUT' , fractal = 0.0 , fractal_along_normal = 0.0 , seed = 0 ) ¶ Subdivide selected edges Parameters : number_cuts ( int in [ 1 , 100 ] , ( optional ) ) – Number of Cuts smoothness ( float in [ 0 , 1000 ] , ( optional ) ) – Smoothness, Smoothness factor ngon ( boolean , ( optional ) ) – Create N-Gons, When disabled, newly created faces are limited to 3 and 4 sided faces quadcorner (enum in [ 'INNERVERT' , 'PATH' , 'STRAIGHT_CUT' , 'FAN' ], (optional)) – Quad Corner Type, How to subdivide quad corners (anything other than Straight Cut will prevent n-gons) fractal ( float in [ 0 , 1e+06 ] , ( optional ) ) – Fractal, Fractal randomness factor fractal_along_normal ( float in [ 0 , 1 ] , ( optional ) ) – Along Normal, Apply fractal displacement along normal only seed ( int in [ 0 , inf ] , ( optional ) ) – Random Seed, Seed for the random number generator bpy.ops.mesh. subdivide_edgering ( * , number_cuts = 10 , interpolation = 'PATH' , smoothness = 1.0 , profile_shape_factor = 0.0 , profile_shape = 'SMOOTH' ) ¶ Subdivide perpendicular edges to the selected edge-ring Parameters : number_cuts ( int in [ 0 , 1000 ] , ( optional ) ) – Number of Cuts interpolation (enum in [ 'LINEAR' , 'PATH' , 'SURFACE' ], (optional)) – Interpolation, Interpolation method smoothness ( float in [ 0 , 1000 ] , ( optional ) ) – Smoothness, Smoothness factor profile_shape_factor ( float in [ -1000 , 1000 ] , ( optional ) ) – Profile Factor, How much intermediary new edges are shrunk/expanded profile_shape (enum in Proportional Falloff Curve Only Items , (optional)) – Profile Shape, Shape of the profile bpy.ops.mesh. symmetrize ( * , direction = 'NEGATIVE_X' , threshold = 0.0001 ) ¶ Enforce symmetry (both form and topological) across an axis Parameters : direction (enum in Symmetrize Direction Items , (optional)) – Direction, Which sides to copy from and to threshold ( float in [ 0 , 10 ] , ( optional ) ) – Threshold, Limit for snap middle vertices to the axis center bpy.ops.mesh. symmetry_snap ( * , direction = 'NEGATIVE_X' , threshold = 0.05 , factor = 0.5 , use_center = True ) ¶ Snap vertex pairs to their mirrored locations Parameters : direction (enum in Symmetrize Direction Items , (optional)) – Direction, Which sides to copy from and to threshold ( float in [ 0 , 10 ] , ( optional ) ) – Threshold, Distance within which matching vertices are searched factor ( float in [ 0 , 1 ] , ( optional ) ) – Factor, Mix factor of the locations of the vertices use_center ( boolean , ( optional ) ) – Center, Snap middle vertices to the axis center bpy.ops.mesh. tris_convert_to_quads ( * , face_threshold = 0.698132 , shape_threshold = 0.698132 , topology_influence = 0.0 , uvs = False , vcols = False , seam = False , sharp = False , materials = False , deselect_joined = False ) ¶ Merge triangles into four sided polygons where possible Parameters : face_threshold ( float in [ 0 , 3.14159 ] , ( optional ) ) – Max Face Angle, Face angle limit shape_threshold ( float in [ 0 , 3.14159 ] , ( optional ) ) – Max Shape Angle, Shape angle limit topology_influence ( float in [ 0 , 2 ] , ( optional ) ) – Topology Influence, How much to prioritize regular grids of quads as well as quads that touch existing quads uvs ( boolean , ( optional ) ) – Compare UVs vcols ( boolean , ( optional ) ) – Compare Color Attributes seam ( boolean , ( optional ) ) – Compare Seam sharp ( boolean , ( optional ) ) – Compare Sharp materials ( boolean , ( optional ) ) – Compare Materials deselect_joined ( boolean , ( optional ) ) – Deselect Joined, Only select remaining triangles that were not merged bpy.ops.mesh. unsubdivide ( * , iterations = 2 ) ¶ Un-subdivide selected edges and faces Parameters : iterations ( int in [ 1 , 1000 ] , ( optional ) ) – Iterations, Number of times to un-subdivide bpy.ops.mesh. uv_texture_add ( ) ¶ Add UV map bpy.ops.mesh. uv_texture_remove ( ) ¶ Remove UV map bpy.ops.mesh. uvs_reverse ( ) ¶ Flip direction of UV coordinates inside faces bpy.ops.mesh. uvs_rotate ( * , use_ccw = False ) ¶ Rotate UV coordinates inside faces Parameters : use_ccw ( boolean , ( optional ) ) – Counter Clockwise bpy.ops.mesh. vert_connect ( ) ¶ Connect selected vertices of faces, splitting the face bpy.ops.mesh. vert_connect_concave ( ) ¶ Make all faces convex bpy.ops.mesh. vert_connect_nonplanar ( * , angle_limit = 0.0872665 ) ¶ Split non-planar faces that exceed the angle threshold Parameters : angle_limit ( float in [ 0 , 3.14159 ] , ( optional ) ) – Max Angle, Angle limit bpy.ops.mesh. vert_connect_path ( ) ¶ Connect vertices by their selection order, creating edges, splitting faces bpy.ops.mesh. vertices_smooth ( * , factor = 0.0 , repeat = 1 , xaxis = True , yaxis = True , zaxis = True , wait_for_input = True ) ¶ Flatten angles of selected vertices Param