ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

How to smoothen text path of a tracked shot

COW Forums : Adobe After Effects

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Sascha Engel
How to smoothen text path of a tracked shot
on Jan 30, 2012 at 11:43:48 am

Hi,

following problem: I i have a long pan shot which I tracked with 4 different Motion Trackers on Null Objects, parented to each other.
I parented my text to that Master Null, it's following the path nicely, but to detailed, so the text is a bit wobbly.
How can i smoothen the path of the text out, so it basically follows the tracking, just not in such a detail.
Thanx a lot for help.


Sascha


Return to posts index

Michael Szalapski
Re: How to smoothen text path of a tracked shot
on Jan 30, 2012 at 2:49:56 pm

Try a smooth() expression.

- The Great Szalam
(The 'Great' stands for 'Not So Great, in fact, Extremely Humble')

No trees were harmed in the creation of this message, but several thousand electrons were mildly inconvenienced.


Return to posts index

Sascha Engel
Re: How to smoothen text path of a tracked shot
on Jan 30, 2012 at 2:56:40 pm

Pfff, I admit, I am a mess when it comes to Expressions, even look at that site will take me a while to under stand. Could you be so kind and tell me what expression, I have to insert to what Parameter. Thank you so much.

Sascha


Return to posts index


Michael Szalapski
Re: How to smoothen text path of a tracked shot
on Jan 30, 2012 at 5:03:13 pm

From the page I linked:
smooth(width=.2, samples=5, t=time) Return type: Number or Array. Argument type: width, samples, and t are Numbers.
Smooths the property values over time, converting large, brief deviations in the value to smaller, more evenly distributed deviations. This smoothing is accomplished by applying a box filter to the value of the property at the specified time. The width value is the range of time (in seconds) over which the filter is averaged. The samples value is the number of discrete samples evenly spaced over time; use a larger value for greater smoothness (but decreased performance). Generally, you’ll want samples to be an odd number so that the value at the current time is included in the average. Example: position.smooth(.1, 5)
Note the example at the bottom. Apply that sort of expression to any parameter you need to be smoothed.

- The Great Szalam
(The 'Great' stands for 'Not So Great, in fact, Extremely Humble')

No trees were harmed in the creation of this message, but several thousand electrons were mildly inconvenienced.


Return to posts index

Sascha Engel
Re: How to smoothen text path of a tracked shot
on Jan 30, 2012 at 8:18:22 pm

Now I have to ask really stupid:
In the page they describe three parameters in brackets,
in the example below it's two - how many is it now?
Where do I ad the expression? Any parameter possible that has to be smoothened?


Sascha?


Return to posts index

Sascha Engel
Re: How to smoothen text path of a tracked shot
on Jan 30, 2012 at 8:29:04 pm

got it I think-work! Thanx.
Still don't understand what is the third number in the bracket for.


Sascha


Return to posts index


Sascha Engel
Re: How to smoothen text path of a tracked shot
on Jan 30, 2012 at 8:34:34 pm

How is it possible to only apply the smoothing to the y-value, not the x?
At the moment I just know how to put it to Position, but then it work for x and y.

Sascha


Return to posts index

Sascha Engel
Re: How to smoothen text path of a tracked shot
on Jan 30, 2012 at 8:48:33 pm

I alos think I do not see much of an effect, since I applied it to position, and the position value is not changing.
The text layer is parented to the tracked Null Layer.


Return to posts index

Roland R. Kahlenberg
Re: How to smoothen text path of a tracked shot
on Jan 31, 2012 at 1:19:20 am

Most loose tracks will not benefit from the smooth Expression method as it lacks the desired control that you will require for getting a locked-on track.

I suggest that you re-track AND/OR average the results of multiple tracks. Additionally, if you posted the original clip and the result of your track and let us know what it is that you actually tracked and include the shape(s) that were used in the tracking exercise, we should be able to provide a more concise solution for you.

HTH
RoRK

Intensive AE & Mocha Training in Singapore and Malaysia
Adobe ACE/ACI (version 7) & Imagineer Systems Inc Approved Mocha Trainer


Return to posts index


Sascha Engel
Re: How to smoothen text path of a tracked shot
on Jan 31, 2012 at 5:35:29 am

Hi Roland,

I think the tracking is fine. But yes, maybe I'd should attach the expression to the actual Null Layers that carry the tracking data.
What I did again in a nutshell: I have a Pan shot from left to far, which needs several times new track points. I have have the whole shot split in 4 segments, and parented those 4 Nulls carrying the tracking data together. That worked just fine. But the Pan is of an extremely zoomed shot, so specially in the vertically plane it moves a bit up and down. I have a simple text tool title, that I then attached to the tracking data of the Nulls.
All works well, just the tracking data is too detailed so the text is making also little y axis changes doing the trip, which are unpleasant for the eyes. So, I wanted to smoothen the the y coordinates. Maybe I simply do the smoothening to the tracking data on the Nulls then?

Thanx.

Sascha


Return to posts index

Roland R. Kahlenberg
Re: How to smoothen text path of a tracked shot
on Jan 31, 2012 at 6:31:17 am

You are right Sascha, the smooth Expression method has to be placed on the property with keyframes.

Try this script -
Scalar = smooth(2,20);
(value[0],Scalar)
// End of Script

HTH
RoRK

Intensive AE & Mocha Training in Singapore and Malaysia
Adobe ACE/ACI (version 7) & Imagineer Systems Inc Approved Mocha Trainer


Return to posts index

Sascha Engel
Re: How to smoothen text path of a tracked shot
on Jan 31, 2012 at 12:09:01 pm

Hi Roland,

but how to I restrict the smoothening only to the y coordinates?

Sascha


Return to posts index


Roland R. Kahlenberg
Re: How to smoothen text path of a tracked shot
on Jan 31, 2012 at 1:33:39 pm

Sascha, I've already given you the script, in my previous post, to do just that. It actually helps, more often than not, that you do what we have asked you to do.

HTH
RoRK

Intensive AE & Mocha Training in Singapore and Malaysia
Adobe ACE/ACI (version 7) & Imagineer Systems Inc Approved Mocha Trainer


Return to posts index

Sascha Engel
Re: How to smoothen text path of a tracked shot
on Jan 31, 2012 at 1:44:55 pm

I am sorry Roland, I did not understand, that it was specifically to the y-coordinates.
Would it be too much to ask, what determines exactly what parameter in this script.
I tweeked it with the trial & error method, but would like to understand it.
Just, if it does not make you upset - cause that would really not be my intention.

Thanx a lot.


Sascha


Return to posts index


Roland R. Kahlenberg
Re: How to smoothen text path of a tracked shot
on Jan 31, 2012 at 2:23:43 pm

Hi Sascha, apologies if I sounded upset. I was only wanting you to try the script out - often times, you will discover more by trying things out and such is the case with AE/compositing/VisualFX.

The script I gave you earlier;
//Start Script
Scalar = smooth(2,20);
(value[0],Scalar)
// End of Script

should be applied to the Null's position property. The variable, Scalar, is defined using the smooth Expression method. Hence, after the first line is read by the Expression engine, when the word (variable) Scalar is used again, it would be as though you were writing smooth(2,20).

The second and last line of the script includes two parts; with the first part describing the value for x-position and the second (after the comma) for y-position. As you can see, value[0] references the first parameter of the position property, which is x-position.

Typing value[0] tells the script to take the actual values of x-position without any changes. Hence you will get the original x-position values of the Null layer. The second part, Scalar, references the smooth Expression method. The smooth Expression applies the smooth method to the keyframe values based on the two input values, (2,20).

Hence, the Expression will only affect the y-position values.

The following is a cut/paste routine from AE's online manual -

smooth(width=.2, samples=5, t=time) Return type: Number or Array. Argument type: width, samples, and t are Numbers. Smooths the property values over time, converting large, brief deviations in the value to smaller, more evenly distributed deviations. This smoothing is accomplished by applying a box filter to the value of the property at the specified time. The width value is the range of time (in seconds) over which the filter is averaged. The samples value is the number of discrete samples evenly spaced over time; use a larger value for greater smoothness (but decreased performance). Generally, you’ll want samples to be an odd number so that the value at the current time is included in the average. Example: position.smooth(.1, 5)

HTH
RoRK

Intensive AE & Mocha Training in Singapore and Malaysia
Adobe ACE/ACI (version 7) & Imagineer Systems Inc Approved Mocha Trainer


Return to posts index


Sascha Engel
Re: How to smoothen text path of a tracked shot
on Jan 31, 2012 at 2:37:53 pm

Thanx a lot Roland.
Now it's crystal clear.
I really appreciate your effort to explain that.
Makes expressions look much less scary now - at least this one ;-)


Sascha


Return to posts index

Michael Szalapski
Re: How to smoothen text path of a tracked shot
on Jan 31, 2012 at 4:00:17 pm

Dan Ebberts has a website dedicated to helping people learn about expressions: http://www.motionscript.com/ It may help you to become more familiar with how to use them and continue to make them less scary to use.

- The Great Szalam
(The 'Great' stands for 'Not So Great, in fact, Extremely Humble')

No trees were harmed in the creation of this message, but several thousand electrons were mildly inconvenienced.


Return to posts index

Sascha Engel
Re: How to smoothen text path of a tracked shot
on Feb 1, 2012 at 7:54:22 am

Thanx, I gonna read into that, after project is off my table.


Sascha


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2017 CreativeCOW.net All Rights Reserved
[TOP]