PDA

View Full Version : Filter Set Driven Key Curves in the graph editor?


jjburton
10-23-2007, 05:49 PM
Is there a way (or script) to filter a certain set driven key in the graph editor on a selection of objects. For example, if I have the joints of the mouth selected and want only the curve of the set driven key for poseSmile to show up.

Any ideas would be appreciated:)

Tripple-I
10-25-2007, 04:00 AM
Have you tried under the graph editor show >> attributes >> user defined? or show all?
I don't exactly know if thats what ur looking for, and im not at my comp. or id test it myself?
hope it helps

jjburton
10-25-2007, 06:45 AM
Yeah, that's one I tried a while back and couldn't really getting it working for set driven key attributes. I've tried all kinds of combinations of viewing options in the graph editor to no avail. May have to try scripting one when I have some time if I can't find something.

Thanks anyway:)

ChapmanMs
10-25-2007, 10:00 PM
Im not entirely sure what you are looking for.

If you select the curve itself it will load into the Graph Editor. A good way to find the curve is use the hypergraph, select the “Driver” and show input-output connections. A "Set Driven Key" curve is a regular animation curve with another attribute besides time driving its "input" attribute (and use double instead of time as its input unit), this controls where on the curve you are sampling. If you select the object being driven by the curve the curve should show up in the Graph Editor.



If you can find the curve in the GE you should be able to isolate it with the GEs built in functionality. If this does not work scripting it may be the only way. Use “selectionConnection” command to edit the GEs current selection list and remove all items from the list and add the curve you want to work with. You could also create you own selection connection and use the “editor” command to tell the GE to use yours instead.

jjburton
10-25-2007, 10:14 PM
Sorry I wasn't more clear. What I'm wanting is this:

Say I have my smile set driven key pose (which I use with a rig to drive it - as a blendshape in a facial rig). That specific set driven key might affect 8 joints around the lips alone (on a medium res facial rig setup) on 6 channels (tx,ty,tz,rx,ry,rz). Maya set's up a different animation curve for each of the channels from the affected joint to the set driven key "holder". That really adds up even on a relatively low joint count facial rig. Currently I have to manually trapse through the curve editor identifying each and every set driven key curve in the graph editor for each joint that "pose" affects- (see attached file).

In the example counts above, that's 48 individual curves to select in order to edit in the graph editor. I want to simplify this selection process:)

ashishdantu
10-26-2007, 11:13 AM
hi jjburton,

select the driver object which might be driving any number of driven joints and use :


select `listConnections -type animCurveUL`;
GraphEditor;


this should have all the driven object's setDrivenKeys selected in your graph editor.

You can use these lines on the driven objects too.. it will select the SDK nodes driving this object and open grapheditor. :)

jjburton
10-26-2007, 03:38 PM
Great idea man! ALMOST there. It brings the curves in the editor window but with the animation curve names listed and not the set driven key holder attribute as in the example in my previous post.

However, I have a script that intelligently renames animation curves I can use as a crutch to make this work. If there are no other solutions I'll use that till I can script something.

Thanks again!

jjburton
10-26-2007, 06:30 PM
Okay...I've been thinking through this some more.

There doesn't seem to be any actual "object" that equals what is seen as "poseSmile.Smile" in the graph editor. It exists only as a hook with which to make connections to on the object poseSmile (which is nurbs shape).

Would it be possible to map the connections running from a pose and filtering out all curves which don't have poseSmile.Smile as a base?

Off to test...

jjburton
10-26-2007, 09:13 PM
Solved! :)

Select an attribute on an object:
global proc jbGraphAttribute() {
global string $gChannelBoxName;
string $selected[] = `ls -sl`;
string $selAttr[] = `channelBox -q -sma $gChannelBoxName`;
string $fullAttr = $selected[0] + "." + $selAttr[0];
select `listConnections -p true $fullAttr`;
}
jbGraphAttribute;
GraphEditor;


If there's a moderator, this thread would probably be better in MEL. Thanks!

SoulVector
06-03-2008, 06:36 PM
Hey Josh :) Thanks for posting the solution.. very useful.. made my day :)

jjburton
06-03-2008, 09:02 PM
Always a pleasure to be helpful to someone:)

Being something of an icon making geek at work, I made an icon for it if you like that's on my site- http://journal.joshburton.com/2008/01/jbgraphsetdrivenattribute.html

CGTalk Moderation
06-03-2008, 09:02 PM
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.