Recent Comments
- Daniel on Rebuilding bad frames using OFlow
- justin.li on Keyframe Reduction script for Nuke
- srikanth on Colour Smear for Nuke (UPDATE v2.0)
- pralhad on Colour Smear for Nuke (UPDATE v2.0)
- Francois Leduc on FrameBlendMerge
Convert “Mocha for AE” tracking data to Shake / Nuke nodes via PHP
February 19, 2012
***UPDATE***
This import script has now been rebuilt in Python so that it will run natively within Nuke. Unless you need to create the Shake node, check out the new version here
***ORIGINAL POST BELOW***
A while ago I worked at a facility where I needed to do a Mocha planar track, then use the tracking data in Shake. They only had the “Mocha for AE” version of the software, so it would only create an After Effects corner pin node (AE was not the ideal environment to comp the shot as its corner pin does not support motion blur).
So I wrote a quick and dirty PHP script that takes the generated tracking data (a .txt file) and spits out a Shake “Stabilize” node. Once I had that, it was only a small tweak to have it to also create a Nuke “Tracker” node (credit to Mat Power for doing a lot of this side of the coding).
This has proved an invaluable tool for me, as Im often working at places that don’t have the full licence for Mocha. So I thought I’d share it here, as Im sure others will find it useful.
Just copy and paste the contents of the .txt file created by Mocha into the text area below, then hit “convert”.
I’ll link to the source code here so that people can run it locally, or if they feel that it could be improved. Its pretty ugly under the bonnet – I crashed the script out in a few hours so feel free to clean it up / extend its functionality. There is a function that parses the incoming text file and strips out the point / frame data, putting it into a master array. There are then 2 different functions to format / output the contents of the array into both Shake and Nuke nodes.
|
|



Leave a comment