Activity › Forums › Adobe After Effects › random numbers turn into specific words???
-
random numbers turn into specific words???
Posted by Doug Nash on August 17, 2008 at 8:57 pmI found one other posting regarding this same topic, but with no resolution. Hopefully, someone with a solution will come across this new post.
I want to use the text tool to animate in a series of random numbers (this I can do). But I want these random numbers to then change into specific letters to form the words I need. I don’t want to do this with overlapping layers, as I need to pull off this gag a huge number of times in this project. I want everything to work from a single text layer, per word graphic.
Please advise.
Thanks!
Danny Romano replied 16 years, 5 months ago 7 Members · 12 Replies -
12 Replies
-
Adriano Moraes
August 17, 2008 at 9:22 pmHi there, if I understood what you want I guess this would do the job.
Create you tex layer then apply this expression to the source text parameter:
if (time < 4) random(1,10) else value;This will get random numbers untill it reaches 4 seconds and then stop at the text you want.
You can off course adjust the values.
If you want them to come one by one to the final value I guess there is a text preset already for that.
I hope I could help.
Cheers.
ninguem.
-
Adriano Moraes
August 17, 2008 at 9:38 pmBy the way the random expression there is also just an example. Would you care to tell me the expression you used to randomize the values.
Well again
Cheers.
ninguem
-
Darby Edelen
August 17, 2008 at 10:04 pmI believe a text animator should handle this nicely. There’s already a preset that gets pretty close. Try searching for ‘Decoder’ in the effects & presets panel.
You may need to tweak it some.
Darby Edelen
NVIDIA
Santa Clara, CA -
Doug Nash
August 17, 2008 at 10:06 pmThanks so much for the speedy help, ninguem. I just tried your expression, but unfortunately, it’s not what I’m trying to do. Using the text tool, I’m animation on my word graphics. However, my goal is to have a series of rapidly changing, random numbers appear in the exact spaces where the letters will then appear.
In essence, I want it to look like the numbers quickly build on, then turn into letters. Make sense?
Thanks.
-
Doug Nash
August 17, 2008 at 10:17 pmThanks Darby. This is the approach I have already been experimenting with. However, there seems to be no way around all the other miscellaneous characters showing up in the random offset. I only want random numbers to appear, then transform in the proper letters.
I have a suspicion this may be a case where I’ll need to combine an expression along with a text tool animation. I just don’t know the first thing about doing that…
-
Adriano Moraes
August 17, 2008 at 10:18 pmYeah I understand it now. And I agree with Darby. The text animator seems to be the best solution.
Good Luck!
Cheers.
ninguem.
-
Darby Edelen
August 17, 2008 at 10:33 pm[doug nash] “Thanks Darby. This is the approach I have already been experimenting with. However, there seems to be no way around all the other miscellaneous characters showing up in the random offset. I only want random numbers to appear, then transform in the proper letters.”
I don’t recall exactly how the animator works, but the solution will be to limit the larger set of returned values to only the set of values that correspond to digits. It may take some expressions.
Believe me though, there is an ‘easy’ way. 🙂
Darby Edelen
NVIDIA
Santa Clara, CA -
Bill Kelly
August 17, 2008 at 11:30 pmYou could check out Text Anarchy 2.0 from digitalanarchy.com.
The “text hacker” tool may do what you want. You can download a free demo and play around with it.
https://digitalanarchy.com/text/hacker.html
-
Mike Clasby
August 18, 2008 at 3:07 amThis seems to do what you want. First with the Text Tool, type in the word you want the random numbers to change into. An expression on Source Text and three markers. Here’s the expression:
n = 0;
if (marker.numKeys > 0){
n = marker.nearestKey(time).index;
if (marker.key(n).time > time){
n–;
}
}switch (n) {
case 1:
“1234”//change this to change the initial word
break;case 2:
numRows = 1;
numChars = 4;
holdFrames = 5;seed = Math.floor(time/(holdFrames*thisComp.frameDuration));
seedRandom(seed,true);s = “”;
j = 0;
while(j < numRows){ k = 0; while (k < numChars){ c = Math.floor(random(48,57)); s += String.fromCharCode(c); k += 1; } s += ""; j += 1; } s break; default: value } So now place a marker on the first frame, say 1234, these are the starting number. If you don't place a marker at the first frame you start with the word you typed in, and not a starting number. Pllace a second marker where you want the starting number to start going random (frame 2, or frame 7 if you want to maintain the 5 frame Hold, see below). Now place a third marker where you want the numbers to change into a word. If you look at the expression on line 11, you can change the starting number to whatever you want, here it's 1234. So it will start at 1234 then go random at the second marker to final stop at whatever four letter word you originally typed in wherever the third marker is. This is a hack of a hack from an earlier, similar but different question, here: https://forums.creativecow.net/thread/202/876695#876698Also note that this works for a four letter word, but if you want a six letter word, change line 17 to:
numChars = 6;
And also, this is set up for the random numbers to hold for 5 frames, change line 18 to whatever number you’d like for hold frames.
Methinks this should do what you want.
-
Doug Nash
August 18, 2008 at 5:34 amYikes, Mike! Extraordinary. Thanks so much for the deep thinking. I’m calling it quits for the day, but I’ll give all this a shot tomorrow.
I really appreciate the considerate help.
Reply to this Discussion! Login or Sign Up