Notifications
Clear all
[Closed] Skin selection of vertices
Aug 18, 2018 8:33 pm
Is it possible to have a selection of vertices inside the skin modifier and save it for later use?
2 Replies
Aug 18, 2018 8:33 pm
fn getSkinVertSelection sk =
(
vsel = #{}
vsel.count = skinOps.GetNumberVertices sk
for k=1 to vsel.count where (skinOps.IsVertexSelected sk k) == 1 do append vsel k
vsel
)
fn setSkinVertSelection sk vsel =
(
case vsel of
(
#all: vsel = #{1..skinOps.GetNumberVertices sk}
#none: vsel = #{}
#invert: vsel = -(getSkinVertSelection sk)
)
skinOps.SelectVertices sk vsel
notifydependents sk partid:#select
vsel
)
-- examples
vsel = getSkinVertSelection $.skin
setSkinVertSelection $.skin #invert
setSkinVertSelection $.skin #none
setSkinVertSelection $.skin vsel
but as any SkinOps method it works just if Skin Modifier is a current Editing Object