>  > Put Cue points in the QuickTime sound or mov and use those to trigger the
>slides
>
>thanks for the suggestion, but I never use cue points. They are too
>inflexible. I'd rather continue with my frame scripts. (It's easier to
>change a sync value in a frame script than to change the position of a cue
>point).
>
>I just thought there was a more elegant way to do this ...


There is. I'll get to that in a moment, but here's some thoughts on 
other things covered in this thread:

I've never used stepframe, but I suspect it has some of the 
limitations of prepareframe, in that you can't navigate somewhere 
from it, including staying on the frame. Use a go the frame script 
has been suggested, but you say you want to use the frame script for 
other things. Why not have a go the frame as a movie script then? 
That leaves your frame script free for other things. If you want that 
frame to advance and not stay where it is, just don't include a Pass 
in the exitframe that it contains.

The argument about cue points being like hard coded numbers is a 
misleading one. You put those cue points in based on something 
happening in the sound. If you edit some of the sound out, the cue 
points will move, and will still be valid. They're not really hard 
coded by time, only by event, which is what you want.

A few years ago I programmed a CD-ROM called Children's Songbook. One 
of the features in it was that you could follow the music with each 
note of the score highlighting as it was played. You can imagine that 
that is a fairly precise requirement for synching to QuickTime! It's 
not like a slideshow, where if you trigger the visual a second late, 
it's not the end of the world, With highlighting notes you need to be 
accurate to about 1/10th of a second, otherwise the note seems to 
highlight late or early.

I programmed this before there were such things as cue points, but 
the way I did it does take care of some of the concerns you might 
have. One concern, for example, is what happens if you random access 
much later in the presentation? The if sound(1).currentTime < 
pCuePointTime approach would have the drawback that all the 
in-between frames would race by, and if you happened to random access 
to an earlier point, it would fail completely.

The way I did it was to use findPosNear(). This will very quickly 
tell you the entry that follows the value you ask about. Watch this:

times = [-1,1000,3000,6000,8000,the maxinteger]
sort times
put findPosNear(times, 3001)
-- 4

 From then on you can have a single line exitframe script that takes 
your slideshow to the right frame, even if you random access forwards 
or backwards:

global times

on exitframe
    go label("slide show start")-1+findPosNear(times,sound(1).currenttime)
end


There you go, one line elegant!


[To remove yourself from this list, or to change to digest mode, go to 
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email 
[EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for 
learning and helping with programming Lingo.  Thanks!]

Reply via email to