random switching?

Wondering how to accomplish a certain animation task? Ask here.

Moderators: Víctor Paredes, Belgarath, slowtiger

User avatar
cableon
Posts: 155
Joined: Thu Jan 17, 2008 6:44 pm
Contact:

Post by cableon »

Yeah, my example was merely fictional ;) -- just wondering whether I'd have to move every keyframe by hand (imported images basically respect the project frame rate, one image per frame), or if there was a quicker &more efficient way to set a secondary, slower frame-by-frame animation...
kirkmona
Posts: 14
Joined: Wed Jan 23, 2008 11:37 pm

Post by kirkmona »

Hello,

I'm totally new here but it seems to me that if you are using a switch layer for blinking you could set up blinks really easy by watching your complete animation while recording an audio file. You simply make some noise in each spot you want a blink. You could even just say "blink." You can then use this as your switch source. I'm not sure if you just use the wav file if there is a way to not hear it. you may have to bring the wav into papagayo to create a dat file instead.

I've never tried this but it seems like it should work, be real easy and give you blinks exactly where you want them.

Thoughts anyone?

~Kirk
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

That would work!

Use the audio wav form switch thingy in AS. The one that just uses the max volume of the sound and goes through a series of switches to "simulate" lip sync.

In this case a short loud sound or even just an artificial tone generated by a sound editor would do the trick. It would have to be a short sound or the blinks might be too long. I wonder to if there might be a way to script this? If some kind of "click" noise could be created by dumping the same data into a file based on some other value or timing and saving it as a wav... like the pad sound script.

-vern
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

How silly!

To script this you wouldn't need the sound file at all. Just script the location of keys for the blink.

In the meantime of course the sound file trick will work. ;)

-vern
User avatar
cableon
Posts: 155
Joined: Thu Jan 17, 2008 6:44 pm
Contact:

Post by cableon »

heyvern wrote:Currently the only way to do that would be to calculate the position of frames at 12fps that would be 7fps and put keys in the switch.
Once again, I may not think of the fastest and most logical way to proceed -- but does this imply that, say, importing a long slow-motion image sequence to the foreground of an otherwise "normal speed" project would force me to space all keyframes in that image sequence by hand ?

I know ASP wasn't designed for frame-to-frame animation, and I am not familiar to script programming at all, so I sort of expected some hidden, miraculous function would spare us time and let us set the framerate for switch layers without too many efforts... 8)
rplate
Posts: 257
Joined: Fri Oct 13, 2006 3:58 pm
Location: Minnesota USA

Post by rplate »

cableon wrote:
heyvern wrote:Currently the only way to do that would be to calculate the position of frames at 12fps that would be 7fps and put keys in the switch.
Once again, I may not think of the fastest and most logical way to proceed -- but does this imply that, say, importing a long slow-motion image sequence to the foreground of an otherwise "normal speed" project would force me to space all keyframes in that image sequence by hand ?

I know ASP wasn't designed for frame-to-frame animation, and I am not familiar to script programming at all, so I sort of expected some hidden, miraculous function would spare us time and let us set the framerate for switch layers without too many efforts... 8)
I wonder if what fiziwig has done on several layers, moving at different speeds, in his tutorial on walk cycles may be something that might be the solution. Take a look. fiziwig
. Bob P
EDIT:
Click on 7 walk cycle...
User avatar
cableon
Posts: 155
Joined: Thu Jan 17, 2008 6:44 pm
Contact:

Post by cableon »

Thanks rplate!
Lesson 7 does help you deal with keyframes indeed, although not within switch layers -- and the switch layer section itself doesn't seem to refer to a specific framerate... Thanks anyway, those tutorials might be useful, too.

I might be looking for a non-existent function... :cry:
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

Switch layers follow the same "frame rate" as the project. A switch layer is the same as turning visibility on and off on a regular layer. I think the import image sequence script or function is a "one trick pony". That function didn't exist until someone wrote the script.

So yes, if you import an image sequence that is 12 fps into a switch (with 1 image per frame) you would have to change it by hand to change the "frame rate". If you want your image sequence to play back differently then add more frames when creating the images. If you want it slower double each image before importing the sequence.

Or...

Have you tried using the "Scale Key Frames"? Just select the switch layer with keys at every frame and double the scale. This would put the keys at every other frame and slow it down.


-vern
Post Reply