PDA

View Full Version : explode objects uniformly


em3
03-29-2012, 04:10 PM
Sorry for the obscure title but I am not quite sure the language to use here. I am trying to write a script that will move a set of objects uniformly away from another object (object2) like a sphere along object2's local normal.

It should work a lot like this


obj = geosphere() --create a GeoSphere
convertToMesh obj --collapse to EditableMesh
--Explode half of the faces regardless the angle
meshop.explodeFaces obj #{1..obj.numfaces/2} 0
--Move the exploded faces (selected by the explodeFaces method)
--along their normals at 10 units without outline:
meshop.bevelFaces obj (getFaceSelection obj) 10 0 dir:#independent
update obj --update the mesh


where each object would move out along the face normal. Not sure how else to explain it. Can someone help me move in the right direction?

Thanks in advance.

Dave

CGTalk Moderation
03-29-2012, 04:10 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.