Notifications
Clear all

[Closed] Selecting edge loop not working

Hi all,

Just a quick one, I seem to have got my little script working how I want it. Basically it selects an edge, turns that into an edge loop selection and then applies a noise modifier to that selection. However it seems that the “Select Edge Loop” part of the script is not working, it doesn’t give me any errors though, so I am confused??

Any help appreciated

My code

poly = Edit_Poly()

Select $Sphere
modPanel.addModToSelection poly ui:on
setselectionlevel poly #edge
poly.select #edge #{39}
$Sphere.EditablePoly.SelectEdgeLoop ()
modPanel.addModToSelection (Noisemodifier fractal:On roughness:1 strength:[1,1,1] ) ui:on

2 Replies

If $Sphere is not already an editable poly object, it should and will give you some error. Working with edit poly modifier is slow and not comfortable at all, though, think twice before going that route.

obj = Sphere isSelected:true
poly = Edit_Poly()

addModifier obj poly
poly.SetEPolySelLevel #Edge
poly.SetSelection #Edge #{}
poly.Select #Edge #{39}

poly.SetOperation #SelectEdgeLoop
poly.Commit()

modPanel.addModToSelection (Noisemodifier fractal:On roughness:1 strength:[1,1,1] ) ui:on

Great, that helps! Also will look into other ways if this is slow but its for something small at the moment.

Much appreciated!