Skip to main content
Participating Frequently
November 26, 2015
Question

Make clone-stamp relative to tracker

  • November 26, 2015
  • 1 reply
  • 874 views

Hello!

I am not sure that the answer for my question isn't already out there, but I was not able to find the exact solution to my problem. Most tutorials and help-topics focus on copying something from a still frame.

I have a scene where camera-equipment is in the background and definitely has to be replaced.because it is quite obvious. The area around the object is not moving, and since the camera was on a tripod and the object was far away the changing of the perspective can be ignored. Unfortunately, there are light changes in the scene, so clone-stamping from a single frame does not work for this shot. So I want to do the following:

1. Track the position of the object with the AE tracker.

2. Clone-stamp the object away in a single frame.

3. Make the clone-stamp apply for all frames, with all positions (clone-source, clone-path) relative to the tracker (which I applied to a null-object). The clone-source-frame should always be the same as the clone-target-frame so that the light conditions match.

I currently have no clue on how to do the third step. Pickwhipping does not really work, since it has no direct capabilities for relativ positioning. Writing all of this with expressions would be very time-consuming, since I have around 10 clone-stamps. Does any of you can help me with a workflow for this? Is there built-in functionallity for this?

Thanks in advance! Greetings,

Jonathan

This topic has been closed for replies.

1 reply

Mylenium
Legend
November 26, 2015

Writing all of this with expressions would be very time-consuming

Totally not. It's as simple as

value+[offsetX,offsetY]

All you need to figure out is the offset values and even that would be as simple as

offsetX=A.valueAtTime(framesToTime(ReferenceFrame)[0]-B.valueAtTime(framesToTime(ReferenceFrame)[0];

offsetY=A.valueAtTime(framesToTime(ReferenceFrame)[1]-B.valueAtTime(framesToTime(ReferenceFrame)[1];

where A and B are simply the clone source and the actual brush position and the Reference frame is obviously the one where you start the cloning (fill in the proper references). Really just 3 lines of copy&paste code.

Mylenium

Participating Frequently
November 26, 2015

Thank you for your help! Anyway, it was not as easy as this:

After I had setup the expression for the position of the stroke-effect, I also had to setup a similar expression for the stroke-source property. Now it is working. I don't know whether I am confusing something and I could have solved this with just writing the expression for the anchor point, but anyways this is a really inconvenient solution. What if you just want to add one stroke/stamp - you allways have to repeat the process of adding the correct expression.

Isn't there a built-in option for taking the shortcut, something like an "Anchor Clone Stamp to Object" checkbox? I can't imagine this problem to be a rare scenario...

Thank you for helping me with creating the expression!