One of the best additions to After Effects CS4 is the inclusion of a stand-alone application called Mocha for AE from Imagineer Systems. This is a powerful planar motion tracker and stabilizer that does an amazing job of tracking all kinds of elements in motion or to stabilize a character or a scene with shaky footage. Many of the example movies you may have seen demonstrating Mocha with After Effects CS4 (including some of my own) have been inserting something into the screen of a portable device or a TV. But what if the object you are tracking goes off the screen? What if you want to track something in motion but want to retain the realism of the hand-held camera shake? Even though Mocha does a remarkable job of stabilizing footage I thought I’d put Mocha to the test with some hand-held footage from a compact DV cam and track the footage, shaking and all!
In this project, I captured a semi truck rolling through town with a small portable DV cam. Windy day. Camera shake. Poor quality camera with lens distortion. You name it… this footage has it. What I wanted to do was replace the side of the truck for an ad for the NAB Conference, but make it look believable, like someone captured this NAB truck rolling through their town with their hand-held camera.
Creating the Insert Image
I started by opening up a single frame of the footage in Photoshop, so I could clean up the side of the truck and incorporate my graphics. Using the Clone Stamp and the Healing Brush tools, I carefully eliminated the existing logo on the side the the truck’s trailer.
I then applied the NAB logo to the side of the truck from another layer and adjusted the transparency and set the Layer Blend Mode to Overlay to produce a more believable effect. Since the file I was working on was created from a single frame of the original footage, I knew the dimensions were correct for resizing the panel on the side of the truck’s trailer. Using the Distort Transform tool, I stretched out the four corners of the trailer’s side panel to fill the entire file dimensions. This is necessary to work correctly with the Corner Pinning produced by Mocha when applied to the layers in After Effects.
Next, I open up After Effects and create a new Comp that I import and place the original footage file, plus the cleaned up and modified trailer side panel image, positioned on top of the footage layer. I keep the Current Time Indicator (CTI) at frame 0 so it’s ready to apply the tracking data from Mocha when I return to After Effects.
Motion Tracking in Mocha for AE
I now launch Mocha for AE and create a new project, selecting the original footage file to obtain the tracking data I need for my composite in After Effects. Most of the default settings are fine so I click Finish. The project opens up and I make sure the proper PAR settings are correct in the Clip panel on the bottom of the screen. I select the Film tab on the bottom right and verify that I’m using the standard HD format. (It’s important to know your video format and preview aspect ratios prior to creating your project in Mocha).
I first scrub down the timeline to a good visible area of the side panel of the trailer to define my starting point. I then select the Spline Tool from the toolbar and start to create an outline outside of the edges of the truck’s trailer side panel. Once you’ve gone around the entire area, I right-click the mouse to close the spline. You can move the spline points around to your satisfaction and this creates the first key frame in the tracking project.
Next, I select the Track Forward button and start the tracking process. In most cases, this goes pretty smoothly (provided you have clean footage from a decent camera) but with the shakiness and poor quality from the cheap camera I used, it has to really think on every frame, so this process takes awhile. But don’t just walk away and let it run unattended - you’ll want to stop the process should it start going awry (as it did in this case).
In the case of this footage, there were a lot of vertical surfaces and objects to confuse the tracker as the trailer moves down the street, such as palm trees, buildings and signs. I had to stop the tracking process and re-align my spline as close to the original position as possible; then resume the Track Forward process.
You must be registered to comment. This is an effort to reduce spam. Please REGISTER HERE.
A tutorial that doesnt allow the reader to follow along and replicate the process is a waste of time in my opinion. Would it be very difficult to allow the reader to download the QT so they can truly participate and learn? Just a pet peeve of mine ...
I really wanted to do this tutorial.
Off topic: I just came by here to brush up on my mocha skills, and couldn’t help but notice these comments:
Lasvideo first said: “A tutorial that doesn’t allow the reader to follow along and replicate the process is a waste of time in my opinion.”
Lasvideo then said “I just thought this tutorial looked so good, I wanted to participate.”
Those two comments are a perfect illustration of the following blog’s thoughts on how to get more people to listen to your opinions:
“http://sethgodin.typepad.com/seths_blog/2010/01/amplifying-complaints.html”
It’s the old vinegar vs. honey discussion, isn’t it? (smile)
Personally, I also prefer follow-along sources and project files (see our books) - but I also know how hard it is to get clearance from people to re-distribute their sources (see our videos). So I agree, but I’m also sympathetic.
Meanwhile, I learned a few useful tidbits from this piece. Thanks, Jeff!
Hi Chris:
This is cool. One of my favorite AE teachers is commenting on my (effective?) communications skills I guess my major in Telecommunications and minor in Speech Communications is showing. Actually stuff like this is reflexive with me…something I wish I had a bit more of when it comes to motion graphics.
Tom Daigon
Avid DS / FCP Editor
Borne Again Cameraman http://www.hdshotsandcuts.com
Hi, love the tutorial. But I’ve run into a snag and I have NO clue as to why its not working. This is the 1st time I’ve used Mocha. Anyway, I shot some footage on my hvx of a building sign, tracked it really well. Exported data into CS5. I want to replace the building sign with another jpeg logo I have but whenever I paste the tracked data to the sign layer it sits miles off the original. I have followed various tuts on this to the degree but this always seems to happen. Any help would be much appreciated. BIG TIME.
Posted by .(JavaScript must be enabled to view this email address) on 06/09 at 11:47 AM
All rights reserved. HD EXPO, High Def EXPO, Createasphere, E-Tech, Entertainment Technology Exposition, 3D Production Workshop, VariCamp, P2 Camp, ColorCamp 101, and Lighting, Filters & Gels for HD are all trademarks of HD Expo, LLC.