Portfolio / Blog

Hi my name is Joe Bryant and this is the blog section of my portfolio website. This section might seem a little informal, as it's more of a notebook for me; I post scribbles, rants, notes or news, usually for my own future reference.

Tags

  • about (1)
  • animation (2)
  • blender (2)
  • cinema (12)
  • cycle (2)
  • gallery (4)
  • games (6)
  • kittystring (4)
  • links (3)
  • maya (5)
  • notes (3)
  • playblast (3)
  • scribbles (8)
  • scripts (3)
  • showreel (3)
  • suggestions (2)
  • tips (1)

Blogroll

  • Carlos Lin
  • Katy Andrews

Archive

  • ►  2011 (9)
    • July (1)
    • March (6)
    • February (2)
  • ▼  2010 (14)
    • April (1)
    • March (2)
    • February (5)
    • January (6)
  • ►  2009 (11)
    • October (2)
    • June (2)
    • May (1)
    • April (1)
    • January (5)
  • ►  2008 (28)
    • November (3)
    • October (2)
    • September (8)
    • August (5)
    • July (1)
    • June (7)
    • May (2)
  • ►  2007 (1)
    • January (1)
  • ►  2006 (1)
    • January (1)
  • ►  2004 (1)
    • November (1)

March 4, 2010

KeyTangent Script

There are heaps of these kind of scripts around, but usually you want to make your own to suit the way you work. This script sets all keys for selected objects in the current time range to use preset tangent types, and also sets your default key tangent type as well. Lets me quickly bounce between stepped and plataeu modes while sketching out my animation, also good if you are working in a large timeline and don't want to trash your curves in finished sections.


string $inTangentType = "linear";
string $outTangentType = "step";

// Convert all keys for selected in timeline to $outTangentType
int $minTime = `playbackOptions -q -minTime`;
int $maxTime = `playbackOptions -q -maxTime`;
string $minmaxTime = $minTime + ":" + $maxTime;
$sel = `ls -sl`;
keyTangent -inTangentType $inTangentType -outTangentType $outTangentType -time $minmaxTime $sel;

// set default key tangent to $outTangentType
keyTangent -global -ott $outTangentType;
Tags: maya, scripts

0 comments:

Post a Comment

Newer Post Older Post Home
Subscribe to: Post Comments (Atom)

Main | Reel | Folio | Blog
All content © Joe Bryant, unless otherwise specified. Website by Joe Bryant. Feel free to contact me at robomojo@gmail.com