headus 3D tools headus 3D tools / 3D scans
Support Forums
 
 FAQFAQ   SearchSearch    UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
headus 3D scans

Maya Plugin v1

 
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
headus
Site Admin


Posts: 2894
Joined: 24 Mar 2005
Location: Perth, Australia

PostPosted: Tue Aug 22, 2006 1:35 am    Post subject: Maya Plugin v1 Reply with quote

Here's the interface plugin for Maya; it allows you to run UVLayout from within Maya, and selected objects can be sent back and forth with the click of one button or hotkey. Note: This will only work with UVLayout v1.14 or above.

How to install it:

Grab the ZIP file below, extract its contents, then put the two uvlayout MEL scripts into your maya scripts directory, the XPM into prefs/icons, and the shelf MEL into prefs/shelves. Typically these directories are here ...
    Windows: C:/Documents and Settings/<your_username>/My Documents/maya/<maya_version>

    Linux: $HOME/maya/<maya_version>
If installing under Windows, you may need to also edit the uvlayout_home.mel script so it returns the install location of UVLayout. By default its set to "C:/Program Files/headus UVLayout".

You may also want to define a hotkey within Maya that calls the uvlayout_send function; I use Ctrl-U. This saves you from having to click on the Send Selected button in the plugin interface window. In fact you can kill the interface window, once everything is going, if you define a hotkey to send objects to UVLayout.

How to start it up:

Run Maya, open up the UVLayout shelf, then click on the torus icon to open up the plugin interface window (see A below). Next, click on the Start button to run UVlayout itself (see B below). Finally, select the Load Options, specifically if you're going to be sending across polymeshes or subdiv surfaces (see C below).

How to send objects to UVLayout:

Use the usual Maya actions to select one or more poly objects, or a single subdiv object, then click on the interface plugin's "Send Selected" button. The selected object should then load up in UVLayout after a second or two.

How to get objects back from UVLayout:

When you've finished flattening those objects in UVLayout, click on UVLayout's "Send" button. Then back in Maya just tap the 'x' hotkey; Maya should then load the flattened objects, replacing the ones you originally sent to UVLayout.

How to exit nicely:

When you're done flattening objects, click on the interface plugin's "Stop" button. This will not only kill UVLayout, but it also stops the background script jobs.

Suggested improvements for someone better at MEL scripting than me:

1) Currently the selected objects are unparented before being sent to UVLayout. It would be nice if it didnt have to do this, or at least re-inserted the objects back into the tree when received back from UVlayout.

2) Instead of replacing the selected objects with those sent across from UVLayout, just transfer the UVs. This would preserve all shaders, and other scene graph properties that OBJ files don't know about. I looked at polyTransfer, but couldn't get it to work.

3) I'm using "scriptJob -cf busy uvlayout_load" to check for the file sent from UVLayout. Is there a better way to do this that doesnt require the 'x' key tap to wake Maya up?

Phil



startup.jpg
 Description:
Getting it going.
 Filesize:  78.01 KB
 Viewed:  24247 Time(s)

startup.jpg



uvlayout_maya_v1_2.zip
 Description:
The UVLayout - Maya interface plugin v1.2.

Download
 Filename:  uvlayout_maya_v1_2.zip
 Filesize:  6.25 KB
 Downloaded:  4135 Time(s)



Last edited by headus on Sun May 06, 2012 8:49 pm; edited 1 time in total
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Wolfsong



Posts: 8
Joined: 16 Jun 2007
Location: Uppsala, Sweden

PostPosted: Sun Jun 17, 2007 6:04 am    Post subject: Reply with quote

I think I've fixed suggestion #1 and #2 now. Also fixed some other issues I found, like when trying to export only a parent it becomes a shape with all it's children merged.

Don't have a clue on suggestion #3... yet.

I'll keep going at it some more.
Back to top
View user's profile Send private message
headus
Site Admin


Posts: 2894
Joined: 24 Mar 2005
Location: Perth, Australia

PostPosted: Sun Jun 17, 2007 6:42 pm    Post subject: Reply with quote

Thanks!

Phil
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Wolfsong



Posts: 8
Joined: 16 Jun 2007
Location: Uppsala, Sweden

PostPosted: Mon Jun 18, 2007 9:30 pm    Post subject: Reply with quote

Found another problem yesterday, but I'm getting there. A few more days of testing and fixing should do it.

Gonna take a closer look at the subDiv issues as the poly part works fine now even with objects which have parent and/or child objects.
Back to top
View user's profile Send private message
headus
Site Admin


Posts: 2894
Joined: 24 Mar 2005
Location: Perth, Australia

PostPosted: Thu Jun 28, 2007 7:07 pm    Post subject: Reply with quote

For those "watching" this topic, Wolfsong's updated Maya plugin now available here ... http://www.headus.com/phpbb/viewtopic.php?t=394

Phil
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group