ADOBE AFTER EFFECTS: Forum Expressions Tutorials Podcasts Creative Cloud

animate character offset

COW Forums : Adobe After Effects

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
matthieu Chevallieranimate character offset
by on Mar 17, 2010 at 10:10:20 am


I'm trying to make a text animation,so that the letters change randomly.
but the tricky thing is : I just want them to change into the same 4 letters A,T,C and G (yes I am doing a DNA thing.) So that A become a T then a G...and so on.

When I use the text >animate>character offset>character range : I only have 2 solutions
Preserve case and digit give me the entire alphabet and unicode give the all signs
How can I change that ? is it possible ?

is there any other solutions ?

Thanks a lot


Return to posts index

Dave LaRondeRe: animate character offset
by on Mar 17, 2010 at 3:22:20 pm

Instead of using text animation, you could build one single comp with those four characters in it.
Pick the largest size you would want the characters to be, and you're well on your way to discovering the horizontal and vertical dimensions of the comp. I'd bet it would be surprisingly small.

Make the comp much longer than you think. Simply make each character one or two frames long, and change them in a random pattern.

Nest this comp in your main comp as many times as needed. Since you said nothing about the characters having any depth, you can make the nested comps 3D layers if necessary, and they'll look like a normal 3D text layer.

To stop on a certain character, you can use time remapping. To randomize the random pattern, trim the in point of the precomp... which is why you make it longer than you think.

You can try asking about an expression to do this text animation on the COW's expressions forum. They might be able to come up with something that would be better than this nested comp idea.

Dave LaRonde
Sr. Promotion Producer
KCRG-TV (ABC) Cedar Rapids, IA

Return to posts index

matthieu ChevallierRe: animate character offset
by on Mar 17, 2010 at 3:28:11 pm

Thanks dave.

I'll try that.

Return to posts index

Darby EdelenRe: animate character offset
by on Mar 17, 2010 at 9:44:15 pm

If you only need these 4 characters to appear randomly you can apply this expression to the 'Source Text' property:

c = ['A','C','G','T'];
s = "";
for(x=0; x < value.length; x++){
r = Math.floor(random(0, c.length));
s += c[r];

This will turn every character in text layer into a random selection of As, Cs, Gs and Ts on every frame. If you need more control over the changes of the text then your setup will be more complicated.

Darby Edelen

Return to posts index

Emily ScollonRe: animate character offset
by on Apr 17, 2013 at 6:40:36 pm

is there an expression do this if you needed the letters to stay in specific groups? I'm doing a similar project but the letters need to stay spelling words with spaces.

Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2016 All Rights Reserved