Advanced Tricks Tutorial

From Aegisub Wiki

Jump to: navigation, search


Contents

[edit] Abusing rotation commands through the \org tag

The \org tag allows for much "abuse" of the rotation tags \frx, \fry and \frz.

Moving the rotation origin absurdly far away from the text to be rotated can make a rotation in effect look not like a rotation, but some other effect instead.

[edit] Moving text

This trick is especially useful in karaoke contexts.

This can be used to create movement in various directions, depending on where exactly you place the rotation origin.

For example, consider a line near the top of the screen. If you add \org(10000,20) to it somewhere, then apply \frz0.01 to some text, you should notice that the text has moved upwards a bit, without actually looking distorted. Adjust the amount of the rotation to "move" the text more or less.

Another example, text centered on a 640x480 video, set \org(320,10000), then apply \frz0.01, the text you "rotated" should have moved a bit to the right, again not looking rotated.

Also experiment with different rotation origins to get other movement directions.

[edit] Skewed text

Using the same "absurd" origins as in the above examples, but instead using \frx and \fry, you can get the text "skewed" or "swayed" in different directions. While this is actually a perspectivic projection, the distortion from it won't be noticeable when the origin is far enough away.

[edit] Effects with layered borders

If you put several copies of the same text on top of each other, but with different border settings, you can get interesting results.

Note that if you want to apply shadows here, you can only apply it to the bottom-most layer, or things will look really bad. You might even want to create the shadow manually, ie. disable the shadow on the original lines, and make additional copies displaced a bit, and made look like a shadow, and placed in a lower layer.

[edit] Double/triple/etc. borders

For example, try in layer 1 to have a 5 pixel wide green border, and in layer 2 to have a 2 pixel wide black border, you will then effectively get a double border, with a 2 pixel black border, that additionally has a 3 pixel green border around it.

This can easily be extended to any number of layers and borders.

[edit] Wide border blurs

While the \be1 tag can give good effects in some cases, sometimes you want a very wide blur on the border.

Just put several layers on top of each other, all having the same (important!) high alpha value, increasing the border size each time.

If you want to have an 8 pixel wide blur, you can pick \3a&Hdf& (border-alpha 223) as alpha value for all the layers, then starting bottommost with a say 10 pixel wide border, in the layer above that put a 9 pixel wide border and so on, all the way to a 3 pixel wide border. The alpha value was picked like this to get the best possible effect, if you call the blur-width you want N, you want an alpha value of 255 - 255/N, rounding the result of the division up, always.

[edit] Motion blur

Another trick with alpha and multiple copies is to set a rather medium alpha value on the entire subtitle line (both border and fill) and making multiple copies of it. You can then displace these in a common direction to get a motion blur effect.

[edit] Simulating accelerated movement with drawings and scaling

The \move tag has always been missing one thing, an acceleration parameter like \t has. Newer renderers like asa fix this by changing \move to mean \t(\pos) but while stuck with VSFilter here's a trick that can somewhat overcome it.

If you make a 100 pixels tall and invisible box, you can scale that one with \t(\fscy) and indeed also use the acceleration parameter there. When scaled, the box will "push down" all lines below it. This way you can simulate a scaled movement along the Y axis. You can also do a similar thing on the X axis.

{\an7\bord0\shad0\1a&HFF&}{\fscy0\t(5.0,\fscy200)\p1}m 0 0 l 1 0 1 100 0 100{\p0\r}\Nfoo?
Personal tools