Thread: AE Karaoke
View Single Post
Old 2008-10-25, 17:43   Link #48
pichu
Senior Member
*Fansubber
 
Join Date: Jul 2004
Quote:
Originally Posted by Yuudai-kun View Post
First off, thank you pichu for creating that script and sharing it with the rest of us

So, i have tried your script even though i have no scripting expierence at all (except wiggle, heh). You provided a great start with your get started guide and i was able to reproduce the effects on my first try and started developing a karaoke effect myself. However, i can't figure out how to use the position data.
I've tried something like this:

but i don't know how to use the position data in the expression.

It would be great if someone could explain that further.
nice!

to use the positional data, you need the following requirements:

1. make sure you styled your .ass with the right font and weight (bold or regular) and style (italics or not).

2. in your KRK comp, make sure you set the right font size (or else, you can renormalize with your expressions).

setFontSize( "kanji" , 36 )
(the default size is 1px [it's in parts of 1/1000, so it's fairly accurate])

3. type in the config in your KRK text layer (and you have it correct)
4. Use slider control or point control. Slider is 1d, point is 2 or 3D, but it will dump out 2D positions there.

5. if you're using slider control: write this in your KRK text layer:

.p( "effect('Slider Control')" , {syl:true, pos:true} ) or something

6. Add keyframes to your slider control. 0 means beginning of the syllable, 100 means end of the syllable. Align them the same way as you did before.

7. use expressions in your slider control. If you're using center text: use this--
Code:
var o={w:200,h:200}
640 - o.w/2 + value
if 640 is the center of your text. Note, this part is very restrictive-- i'm thinking of making it a bit easier... var o will get replaced with the right stuff. w means the width of the text, and h is the height (as if it's vertical text--but don't count on h just yet)

8. In your particular's emitter, position XY: use the following expressions:

[ effect("Slider Control")(1) , value[1] ]

adjust the particular emitter's vertical pos to match where you want to go.

9. I think that should be it, but make sure you tweak the values ... you can tweak it after you generated the layer. Make sure you use SOLO option to see only your template layers.

Thanks for trying this out.

Last edited by pichu; 2008-10-28 at 03:06.
pichu is offline   Reply With Quote