Rototracking palette for AE (6.5, 7, CS3)

All things .jsx

Moderator: Paul Tuersley

thehardme
Posts: 9
Joined: September 21st, 2005, 3:47 am

December 18th, 2005, 12:19 am

June 2008: v1.3 script update. Fixes the cause of memory errors when converting track points to a mask. Thanks to Michael Natkin.
Download RotAE1.3.zip

http://usuarios.lycos.es/thehardmenpath ... tAE1.1.jsx

http://usuarios.lycos.es/thehardmenpath ... /RotAE.jsx (old version)

Many people ask if roto tracking is possible at all with AE. It can be done with some plugins, yes but I always wondered if I could do it just with scripting.

Based on an old script Dan Ebberts wrote fast on the COW forums, a friend of mine, Juan Córcoles, and I saw possible to do some things:

1) Set up a tracker where all trackpoints correspond to a max vertex. (not just four, but as many as needed)
2) Make each vertex of a mask follow each trackpoint of a tracker. Not in real time, it's a pity, but once when the tracking has been done.
3) Also, correct some issues of making a mask with multiple independent points, such as a vertex going where it shouldn't go. Half of the script focuses on interpolating vertex and tangents regadless of the keyframes inbetween.

Two things are really missed here: One is to attach the masks to the trackers in real time, but as you know, expressions are not suitable for mask shapes without plugins. The other, that as far as I know, a script can't know which vertices are selected when it's executed.

The script works as well as the built in tracker in AE can be. This means it can make very nice works with objects that don't change much. For many jobs there will be need for manual work, as always happens with rotoscoping. First make a mask around the object you want to track, select it and click on Apply Tracker. It will instantly create the trackpoints. Now it's your choice if you want to handle them all at the same time or not. As you probably know, there's an eye next to the tracker makes them visible or not visible. Invisible trackers do not track when you push the play button in the tracker controls. When you are finished, select the tracker and the mask you made together and click on Apply Mask. It will now be animated.

For those changes in the image of unnacuracy of the trackpoints, use the other half of the palete. When you feel you should alter a tangent or vertex from one point in time to another, insert a layer marker where you want to make the adjustments and one before and one after the places where it's gone wrong. The interpolator script will make a linear movements of either the vertex or the tangents. Only keyframes between markers for a single vertex of its two tangents will altered.

For selecting which vertex to change, use the << < > >> buttons to set the first vertex (the big one) at these places. Do not use the Use first vertex feature of AE, because it will completely change the structure of the mask in a single keyframe and screw up the interpolation.

The script is far from perfect. Juan, the main coder, had to stop working on it some time ago, and I feel I won't have anymore time from now on, so I decided to correct the main issues alone and build the palette, even if there are some little problems, I think it can be helpful. It has already been quite useful for me, even more than what I expected.

I think that's all. As I said, I am afraid I won't have time to improve it, so to anyone who likes the script, feel free to play around with it.

Alejandro Pérez
Last edited by thehardme on August 20th, 2007, 12:35 pm, edited 5 times in total.
User avatar
Disciple
Posts: 137
Joined: June 5th, 2004, 8:05 am
Location: Los Angeles, CA
Contact:

December 19th, 2005, 6:23 am

Amazing you took the time to build this! I think it is probably the first time a mask can be attached to a tracker from within AE!
I'm going to give it a spin asap.

Alex
glennser
Posts: 7
Joined: June 17th, 2004, 1:58 pm

December 21st, 2005, 5:39 pm

I saw your post on Creative Cow a couple of days ago, referring to this, downloaded the script and have to say I was a bit doubtful at the time but I just tried it and it's really blown me away. You are a genius!!!
Glenn Stewart
1k Studios
hype
Posts: 94
Joined: November 27th, 2006, 11:08 pm
Location: Los Angeles, CA
Contact:

November 28th, 2006, 9:45 pm

wow, this script is absolutely astounding, and should be purchased by Adobe and included in AE's future releases!

This kind of functionality is one of the main selling points of Silhouette Roto, and here it is for free!

Thanks a million for this!

sean
if it's not fun, what's the point?
http://www.mackdadd.com
thehardme
Posts: 9
Joined: September 21st, 2005, 3:47 am

November 30th, 2006, 12:04 pm

Wow, thanks for the feedback.
hype
Posts: 94
Joined: November 27th, 2006, 11:08 pm
Location: Los Angeles, CA
Contact:

December 1st, 2006, 1:50 am

an interesting note with this script...

when i first tried it, it worked flawlessly. ever since then, it doesn't seem to want to create the track points when I click on "Apply Tracker". instead I get an error message. It's no big deal, I just quickly set up a tracker with the correct number of track points manually, then use the "Apply Mask" button to apply it to the mask. But just thought I should mention it. This is in AE 7, if that maybe has anything to do with it.

I did a video tutorial and used it in the tutorial.

http://www.simplycg.net/viewtopic.php?t=1853

I'm also really trying to spread the word about this amazing script!
if it's not fun, what's the point?
http://www.mackdadd.com
thehardme
Posts: 9
Joined: September 21st, 2005, 3:47 am

December 14th, 2006, 3:50 am

Hi Hype.

I am watching your video tutorial right now (needless to say I'm flattered). I believe there's a bug that relates to the position of the layer within the timeline. I recomend you to put the layer in the first place before you hit the apply tracker button.
hype
Posts: 94
Joined: November 27th, 2006, 11:08 pm
Location: Los Angeles, CA
Contact:

December 14th, 2006, 10:47 pm

you mean make it layer number 1? interesting... i'll try it!

I've already taken this script to one of the Hollywood FX places I work at sometimes. It's just a little shop, but we've worked on some pretty big movies, like "Meet the Fockers", "Austin Powers", "Benchwarmers", things like that. They love it there. I seriously think this is the best AE script I've ever seen in my life. thanks again for this one! Until AE ships with this feature, I will tell every user I know about it!
if it's not fun, what's the point?
http://www.mackdadd.com
thehardme
Posts: 9
Joined: September 21st, 2005, 3:47 am

December 15th, 2006, 12:10 pm

Yep, that seems to be the bug. Hope I can get time on christmas to debug.

Btw, your post made my day.


Edit: It happened to be a stupid redundant check at the beginning of the button code. Fixed. Please if you use it, tell me about it.
hype
Posts: 94
Joined: November 27th, 2006, 11:08 pm
Location: Los Angeles, CA
Contact:

December 15th, 2006, 9:29 pm

i'm pretty tied up the next few days, but i will definitely give the new version a whirl and see what happens ASAP! thanks for the debugging!
if it's not fun, what's the point?
http://www.mackdadd.com
mutasi13
Posts: 1
Joined: March 15th, 2007, 3:52 am

March 15th, 2007, 1:42 pm

hello guys! I actually never use script in after effect before. I just start using the program 6 months ago and i like it alot. I'm glad to found out this forum and script that i might use alot, since i like doing rotoscoping/tracking. On the other hand, I'm wondering how do I download the script RotAE JSX file. I had paste the script on the notepad and save it as RotAE1.1.jsx , but it doesnt work. I would very be appreciated if anybody can help or send me the script RotAE. Have a good day! :P



note:
sorry about my poor english! :D
hype
Posts: 94
Joined: November 27th, 2006, 11:08 pm
Location: Los Angeles, CA
Contact:

March 15th, 2007, 2:36 pm

all you really have to do is click the link up above in the first post for the RotAE1.1.
your computer should ask you where to save it. Just pick a place, click ok, and now the jsx file will be on your computer. put it in your AE scripts folder, and it will then show up in the scripts menu in AE (you'll have to restart AE after copying it into the scripts folder).

you shouldn't have to open up the script in notepad at all. you shouldn't ever have to look at the script code if you don't want to. :)

hope this helps!
if it's not fun, what's the point?
http://www.mackdadd.com
hype
Posts: 94
Joined: November 27th, 2006, 11:08 pm
Location: Los Angeles, CA
Contact:

July 31st, 2007, 3:08 pm

anyone check this script yet on AE CS3? I just ordered my upgrade, and am really hoping this still works!
if it's not fun, what's the point?
http://www.mackdadd.com
Marvin
Posts: 4
Joined: April 4th, 2007, 4:07 am
Contact:

August 9th, 2007, 4:03 am

hype wrote:anyone check this script yet on AE CS3? I just ordered my upgrade, and am really hoping this still works!
It works fine on CS3.
thehardme
Posts: 9
Joined: September 21st, 2005, 3:47 am

August 20th, 2007, 12:36 pm

Good to know, thanks! Thread title updated.
Post Reply