problem with script due to poly count change

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

THREAD CLOSED
 
Thread Tools Search this Thread Display Modes
Old 02 February 2013   #1
problem with script due to poly count change

I'm trying to do a simple script that selects an nGon and then extrudes the faces and merges the extruded verts. The first part is fine but what happens when I try and select the next face is that, since the previous extrusion has created more faces, the face I want to select is no longer named pCylinder15.f[20], for example. Is there some way around this some sort of absolute selection that doesn't use the name like this?
 
Old 02 February 2013   #2
Hmm that is a bit annoying that the face names get 're-issued'.
Not sure how else Maya would do what it needs to do there, but still annoying.

Only time I've seen someone have to deal with similar I think they assigned a temp_unique shader to the faces and use the 'Select objects with Material' to get the faces.
Sounds like the long way round to me.

Would also be interested in alternative methods
 
Old 02 February 2013   #3
You could try adding vertices (or any other component) to a set before performing the extrusion. Sets contain only a reference to their members, i.e. when a member changes it's name or value the reference is kept intact. So after extruding you query the set members and delete the set.
 
Old 02 February 2013   #4
ah - of course, sets. That works great now.
Code:
polyExtrudeFacet; string $compStorey[] = `filterExpand -sm 34 -expand true`; string $createSetResulty[] = {}; for ($n=0 ; $n<size($compStorey) ; $n++) { select -r $compStorey[$n]; $createSetResulty[$n] = `sets -name ("setTemp" + $n)`; } for ($n=0 ; $n<size($compStorey) ; $n++) { select -r $createSetResulty[$n]; ConvertSelectionToFaces; MergeVerts; }

Last edited by cgbeige : 02 February 2013 at 12:22 AM.
 
Old 02 February 2013   #5
Thread automatically closed

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.
 
Thread Closed share thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 05:13 AM.


Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.