CGTalk > Software Specific Forums > Autodesk Maya > Maya Programming
Login register
Thread Closed share thread « Previous Thread | Next Thread »  
 
Thread Tools Search this Thread Display Modes
Old 03-19-2013, 09:30 PM   #1
ltethe
Veteran
Ian Mankowski
Freelance Maya Generalist
Marina Del Rey, USA
 
Join Date: Sep 2003
Posts: 53
explicitly name a wrap deformer

How do you explicitly name a wrap deformer, and more importantly the wrap deformer base?

and if you can't, how do you grab the wrap deformer base for manipulation?

Code:
wrap = mel.eval('doWrapArgList "7"{"1","0","1","2","1","0","0"};')


I got this, but not much else.
__________________
He has died a thousand thousand deaths...
And I have yet to fall.
 
Old 03-19-2013, 10:24 PM   #2
Nyro
Lurking
 
Nyro's Avatar
portfolio
A. D.
Vertex Slinger
Munich, Germany
 
Join Date: Dec 2006
Posts: 1,436
It looks like you copied the code you saw in the scriptEditor after manually applying a wrap; specifically, the doWrapArgList command calls another internal script passing along options from the option window.

To find out how to properly apply a wrap deformer, find the MEL script in /Installation Directory/Maya201x/scripts/other/ that performs the wrap (e.g. by running 'whatIs "doWrapArgList"').

I believe there is no built-in command to bind an object by a wrap deformer, but you can always go the hard route and just create the appropriate nodes ('wrap') and connect the right attributes yourself.
 
Old 03-19-2013, 10:43 PM   #3
ltethe
Veteran
Ian Mankowski
Freelance Maya Generalist
Marina Del Rey, USA
 
Join Date: Sep 2003
Posts: 53
create my own wrap huh?

Oi. That was a level higher up then I originally expected, but here goes nothing I suppose.

Allright. Time to dive into the messy mel ness I suppose. I notice that Maya's wrap script was written in 99', have there been any more recent advances to the tech, something more ah... Pythonic I could reference?

*rolls up sleeves.*
__________________
He has died a thousand thousand deaths...
And I have yet to fall.
 
Old 03-20-2013, 12:00 AM   #4
Nyro
Lurking
 
Nyro's Avatar
portfolio
A. D.
Vertex Slinger
Munich, Germany
 
Join Date: Dec 2006
Posts: 1,436
Almost everything you can access via Maya's UI is written in MEL. And MEL can be translated almost verbatim to functional Python.

From what I recall (can't access Maya right now), applying a wrap deformer just involves duplicating (and hiding) an instance of the influence object, connecting that to a wrap node, and connecting the wrap node to the target object.

A quick google tells me you should be looking at a file called CreateWrap.mel (or a file that contains a function with that name).
 
Old 03-20-2013, 12:04 AM   #5
ltethe
Veteran
Ian Mankowski
Freelance Maya Generalist
Marina Del Rey, USA
 
Join Date: Sep 2003
Posts: 53
yup, poking around in that file now.

Mel isn't hard. It's just dirty, and the syntax makes my brain hurt since I've been in python so long.

And CreateWrap.mel was written in 99'. I just was wondering if there were any newer wrap paradigms that have emerged since then.

I certainly have seen a couple in hunting this down, though they're written in C++ which is out of my league currently.
__________________
He has died a thousand thousand deaths...
And I have yet to fall.
 
Old 03-20-2013, 12:07 AM   #6
Nyro
Lurking
 
Nyro's Avatar
portfolio
A. D.
Vertex Slinger
Munich, Germany
 
Join Date: Dec 2006
Posts: 1,436
Well there may certainly be third party plugins that offer similar functionality (deforming based on influence geometry), you'll just have to search.

But if all you're looking to do is include a wrap deformer via Python script, then just copy the essential steps you find in the related MEL files.
 
Old 03-20-2013, 09:44 AM   #7
djx
Where's my pony?
 
djx's Avatar
David Johnson
vfx & creature td
Melbourne, Australia
 
Join Date: Jun 2003
Posts: 3,347
Quote:
Originally Posted by ltethe
wondering if there were any newer wrap paradigms


The SOuP retarget node is possibly of interest to you

http://www.soup-dev.com/examples2_1.htm

Its incorrectly titled as "smooth node", but its the one with the 2 characters wearing the green and yellow shirts with blue pants.

David
__________________
http://www.djx.com.au
 
Old 03-20-2013, 09:44 AM   #8
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 01:57 AM.


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