CGTalk > Software > Autodesk Maya > Maya Programming
Login register
Thread Closed share thread « Previous Thread | Next Thread »  
Thread Tools Search this Thread Display Modes
Old 07-08-2013, 09:36 PM   #1
Peter Hunt
Join Date: Jan 2013
Posts: 95
Get information on any groups an object is in

Hi, I have one part of a code which goes back a frame, gets the location of the object, then subtracts this from the original location to get the velocity

I just tried grouping the objects, and I realised moving the group didn't affect the actual object. Is there a way where I'd also be able to include the location of the group (eg. object at 10,0,0 and the group moved to -20,0,0 would give a result of -10,0,0), or get the absolute position of the object?

Old 07-10-2013, 02:48 AM   #2
A newbie
zoharl's Avatar
Wellington, New Zealand
Join Date: Mar 2009
Posts: 1,825
Look at the doc, when querying the position there's a flag for relative/object space position and there's a flag for world position.
Old 07-10-2013, 08:24 PM   #3
Dresden, Germany
Join Date: Dec 2010
Posts: 321
If your animated objects are driven by keyframes or expressions there is perhaps a better way to get something like velocity if you use the "getAttr" command and modify it with "-time <value>". Otherwise you could produce weird results if your scene contains uncached particles for example.
Old 07-10-2013, 08:24 PM   #4
CGTalk Moderation
CGTalk Forum Leader
Join Date: Sep 2003
Posts: 1,066,478
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
Society of Digital Artists

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

All times are GMT. The time now is 02:48 PM.

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