Activity › Forums › Adobe After Effects Expressions › having an Audio Spectrum that shows text
-
having an Audio Spectrum that shows text
Mike Clasby replied 18 years, 8 months ago 2 Members · 24 Replies
-
Mike Clasby
August 24, 2007 at 7:19 pmMy Bad… maybe.
Do you have the audio in the comp?
Do you have a layer named “Audio Amplitude”?
To do that, take that audio layer and select it, then, Animation>Keyframe Assistant>Convert Audio To Keyframes. That gives you a new layer named “Audio Amplitude” with an Effect named “Both Channels” that has a Slider with keyframes for the audio’s amplitude (loudness of both channels). If you did that and the layer exists in the comp, the expression should work. The error message sounds like the layer is not there or it has a different name.
What I did above was on Dan’s page, just under “Design” that I recommended in my third post above.
https://www.motionscript.com/design-guide/basic-audio.html
Sorry if I inadvertently skipped a step, creating the Audio Amplitude layer?
Is that the problem?
-
Sam Rose
August 24, 2007 at 8:31 pmHi
Ok, it works now but all it does is move the text up and down to the music, if the audio was silent you would still see it. Also my friend wants the text to look like part of the spectrum (just like ‘The SImpsons’ heads were like part of the spectrum in that clip. How do I accomplish those effects aswell? -
Mike Clasby
August 24, 2007 at 11:02 pmForget the Auto Trace on the text. If you want it too all grow out of one line, you need an unbroken (open mask) that outlines all the text.
Add text. On a new Black Solid, moved below the text, add a mask with the Pen Tool (G) by click off to the left of the text even with the bottom of the text, then click at the base of the first letter, then up the letter, tracing the shape of the letter, then over the top of the letter and don to the bottom of the letter, and go right to the next letter, continue so all the letters are connected by the line, so it’s one continuous line (mask) that looks like the letters. When you get to the end go out to the right aways, still even with the bottom, and click. It will kind of look like the skyline of a city. Now connect the mask back at the beginning point, underlining the letters. It won’t look perfect. It will take time.
Now turn off the text eyeball and to the layer with the mask add Render>Stroke, green.
Add the expression to the Scale of the Black Solid layer, the mask will scale appropriately.
Here’s the expression:
minAudio = 0;
maxAudio = 8;
maxStretch = 3.0;
xFac = 2://width factoraudioLev = thisComp.layer(“Audio Amplitude”).effect(“Both Channels”)(“Slider”);
stretch = linear(audioLev, minAudio, maxAudio, 0.1, maxStretch);
x = scale[0]*stretch;
y = scale[1] * stretch;
[x/xFac,y]Notice the 1 in line 6 was change to 0.1 to make the Stroked text shrink to a line. The xFac will control how much it stretches sideways, higher numbers stretch less.
Adjust the minAudio and MaxAudio to match you audio levels by twirling down to see the graph under the slider. Tweak the numbers, they will change the look.Note: Instead of Stroke above, you can try Render Audio Waveform or Audio Spectrum, just tune the Maximum Height down to 15-30 or so, and Audio Layer>Choose you audio layer (it must be in the comp), and Path, choose your mask (mask 1). This will make the line twitch like and audiowave. Play with all the setting to find what you like. The expression will still scale the mask, the audiowaveform will climb on top.
I think you’ll like the audiowaveform instead of the stroke.
You’ll still need a covering audiowave in front of what you’ve just created, Homer and Family hides behind audio waves of the same color. See Aharon’s tut (it has curves lines like Homer’s example) or make another instance of Audio Waveform running in front (no mask here, no expression, just stretch out the Start and End Points to cover.
If this doesn’t do it, I dunno how to.
-
Sam Rose
August 25, 2007 at 10:16 amHi
I have this so far
https://img463.imageshack.us/my.php?image=quakecentralug8.jpgWhat do you think so far, any tips?
I need to make the middle of the Q mask but when I do it and assign the mask to a new spectrum the spectrums disappear.
What can I do to carve out the middles?I will add another spectrum at the bottom when I am done 😀
-
Mike Clasby
August 26, 2007 at 8:33 amI liiiiiike it! What you have so far.
Now about those pesky Carve-Outs. You can add other instances of Audio Spectrum by selecting it in the Effects panel and hitting Ctrl D.
But you’re right in that when you change the Path to Mask 2, it makes the first one disappear… unless… (cue Jeopardy music)…
One the second Audio Spectrum, you click on the little box at the bottom named “Composite On Original”.
Now when you Dup the effect and change the Path to whatever mask you have, that Composite On Original is still checked and all is good. At least that works for me.
It looks like you’ll need 8 copies of Audio Spectrum to cover the text and all the Carve-Outs, just make sure all but the first one have Composite On Original checked.
Stroke does this automatically with one instance, if you check “All Masks”, but then you won’t have those cool audio line on the text.
Note: If you want the black background to be truly black and not transparent, also make that first instance of Audio Spectrum “Composite On Original”, but if it’s unchecked you will have transparency even though the following instances are “Composite On Original”. Hope that makes sense.
-
Mike Clasby
August 26, 2007 at 8:58 amI really like Audio Spectrum and Audio Waveform and if you want to see a kind or trippy use of it, check this out:
https://jumpcut.com/view/?id=94D38AEAF6B811DABD2F1E30947BEEEA
It’s a remix of Scanner Darkly for a contest, long past. I didn’t win nothin”… SAY WHAT?
Anyway, the text “Philip K. Dick” get drawn on with Audio Waveform, just by animating the “Number of samples from zero to about 300. It draws the letters like a laser-thing from the first vertex of the mask it’s applied to. For that one I put it on mask one (the outline of the text), no audio referenced) and then added other instances for the carve out, on separate layers if I remember correctly, then just slid their inpoints down do they appeared as the laser-thing whips out.
You can do the same thing with Audio Spectrum, just animate the “Frequency Bands” from 0 to 300 over time.
It’s the same thing, Number of Samples from 0 to 300 animating in the outline for the fellow sitting below (PKD himself), but there Audio is referenced.
Just thought you like to see the weird stuff you can do with Audio Waveform and Spectrum.
You can also make masks for those carve-outs with Auto Trace.
-
Mike Clasby
August 26, 2007 at 9:13 amOK, I just remembered how I got a mask for the text in that example above. The text, “Philip K. Dick”.
I typed in the text, then added a bar across the bottom with a new solid layer, say 400 pixels wide and 5 pixels high. The bard formed the base of the text. So it looked like this
Layer I – Text
Layer 2 – Bar for base.Now I precomped those, then used Auto Trace on that precomp lsyer (Threshold 1, Tolerance 1) and I got a nice tight Mask surrounding all the text with the bar bottom attached, and many little cutout masks for the insides of the letters.
I feel soooo bad for not remembering how I did it, as it’s a whole lot faster than drawing it out with the Pen Tool. I didn’t remember until just saw the clip again for the first time in a long time, and I wondered how the mask was so tight… 30 minutes later I remembered the method.
I need to save this so I won’t forget again.
Sorry ’bout that.
-
Sam Rose
August 26, 2007 at 10:35 amHi
Thanks for all the replies. I have carved everything out and it looks good.Thanks for all your help
Reply to this Discussion! Login or Sign Up