PDA

View Full Version : Please, "Delete all Subframe Keys From Selected Ojects"


cganimator
04-10-2006, 11:06 PM
Hi..

I baked my TP particles with 1/500 frame sub-sampling.
The result is a huge 700Mb file that I can not handle.

I want to delete all sub-frame keys.

Please somebody make a "Delete all Subframe Keys From Selected Ojects" script.

Thanks.

martinez
04-11-2006, 10:56 PM
This is messy and assumes you have the default max controllers on scale, rotation, and position.

****************************************


for obj in selection do
(
selectkeys obj.scale.controller (interval animationrange.start animationrange.end)
for i = animationrange.start to animationrange.end do deselectKey obj.scale.controller (getKeyIndex obj.scale.controller i)
deleteKeys obj.scale.controller #selection

selectkeys obj.rotation.controller (interval animationrange.start animationrange.end)
for i = animationrange.start to animationrange.end do deselectKey obj.rotation.controller (getKeyIndex obj.rotation.controller[1].controller i)
deleteKeys obj.rotation.controller[1].controller #selection
for i = animationrange.start to animationrange.end do deselectKey obj.rotation.controller[2].controller (getKeyIndex obj.rotation.controller[2].controller i)
deleteKeys obj.rotation.controller[2].controller #selection
for i = animationrange.start to animationrange.end do deselectKey obj.rotation.controller[3].controller (getKeyIndex obj.rotation.controller[3].controller i)
deleteKeys obj.rotation.controller[3].controller #selection

selectkeys obj.pos.controller (interval animationrange.start animationrange.end)
for i = animationrange.start to animationrange.end do deselectKey obj.pos.controller (getKeyIndex obj.pos.controller[1].controller i)
deleteKeys obj.pos.controller[1].controller #selection
for i = animationrange.start to animationrange.end do deselectKey obj.pos.controller[2].controller (getKeyIndex obj.pos.controller[2].controller i)
deleteKeys obj.pos.controller[2].controller #selection
for i = animationrange.start to animationrange.end do deselectKey obj.pos.controller[3].controller (getKeyIndex obj.pos.controller[3].controller i)
deleteKeys obj.pos.controller[3].controller #selection
)

CGTalk Moderation
04-11-2006, 10:56 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.