CGTalk > Software > Autodesk Maya > Maya Programming
Login register
Thread Closed share thread « Previous Thread | Next Thread »  
 
Thread Tools Search this Thread Display Modes
Old 10-13-2004, 04:38 AM   #1
mayafx60
New Member
 
Join Date: Oct 2004
Posts: 2
problem to list my selection on vertex

string $sel[] = `ls -sl`;

int $numsel = size($sel);

{

print $sel;

}

print $numsel;

pPlane1.vtx[9:10]

pPlane1.vtx[20:21]

2

i'm selected 4 vertex on my object n the result only show 2.

can anyone tell me what mistake i've made??

thanks!

 
Old 10-13-2004, 05:54 AM   #2
Panupat
Expert
 
Panupat's Avatar
portfolio
Panupat Chong
Thailand
 
Join Date: Feb 2004
Posts: 1,942
to get vertices name, use `ls -sl -flatten`
 
Old 10-13-2004, 04:29 PM   #3
flyaway3d
New Member
senior animator
 
Join Date: Aug 2002
Posts: 10
Send a message via ICQ to flyaway3d Send a message via Yahoo to flyaway3d
hi Panupat... `ls -sl -fl` works. thanks. but now i'm having a new problems. when i list down the vertex i selected. it deosn't follow my selection order. which means, when i select vtx[1], vtx[10] and vtx[5], it will list down vtx[1],vtx[5],vtx[10].

how can i list down the vertex number follow my selection order??
thanks!
 
Old 10-13-2004, 07:21 PM   #4
mhovland
MEL Monkey
 
mhovland's Avatar
portfolio
Mike Hovland
Technical Artist
Robomodo
Chicago, USA
 
Join Date: Feb 2002
Posts: 580
You can't. There have been discussions on ways to do this by monitoring the undo que, and rebuilding the list from that, but it is difficult and hacky, at best.

Look at this thread: http://www.cgtalk.com/showthread.ph...selection+order

There is code in there to return the component selection in the the order you selected them.
__________________
mike hovland
lead technical artist
Robomodo

Life beats down and crushes the soul... art reminds you that you have one. - Stella Adler
 
Old 10-14-2004, 02:40 AM   #5
ush
Frequenter
 
Join Date: Aug 2004
Posts: 146
This thread is what I've been searching for.
I used scriptjob instead of undobuffer, and it did't work well.
Now I got answer for this.

Thank you for your good imformation mhovland
__________________
sorry for my bad English. ush
 
Old 01-19-2006, 01:00 PM   #6
CGTalk Moderation
Lord of the posts
CGTalk Forum Leader
 
Join Date: Sep 2003
Posts: 1,066,481
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.
__________________
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
 
Thread Closed share thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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:38 AM.


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