Changeset View
Changeset View
Standalone View
Standalone View
release/scripts/startup/bl_operators/uvcalc_follow_active.py
| Show First 20 Lines • Show All 46 Lines • ▼ Show 20 Lines | def extend(obj, operator, EXTEND_MODE): | ||||
| elif len(f_act.verts) != 4: | elif len(f_act.verts) != 4: | ||||
| operator.report({'ERROR'}, "Active face must be a quad") | operator.report({'ERROR'}, "Active face must be a quad") | ||||
| return | return | ||||
| faces = [f for f in bm.faces if f.select and len(f.verts) == 4] | faces = [f for f in bm.faces if f.select and len(f.verts) == 4] | ||||
| # our own local walker | # our own local walker | ||||
| def walk_face_init(faces, f_act): | def walk_face_init(faces, f_act): | ||||
| # first tag all faces True (so we dont uvmap them) | # first tag all faces True (so we don't uvmap them) | ||||
| for f in bm.faces: | for f in bm.faces: | ||||
| f.tag = True | f.tag = True | ||||
| # then tag faces arg False | # then tag faces arg False | ||||
| for f in faces: | for f in faces: | ||||
| f.tag = False | f.tag = False | ||||
| # tag the active face True since we begin there | # tag the active face True since we begin there | ||||
| f_act.tag = True | f_act.tag = True | ||||
| ▲ Show 20 Lines • Show All 192 Lines • Show Last 20 Lines | |||||