Multiple active players

Richard Gaskin ambassador at fourthworld.com
Thu Oct 9 01:35:01 EDT 2003


Dar Scott wrote:

> I've been looking at audio.  I see from the documentation that only one
> audioClip can be playing at a time.
> 
> Do players have this limitation?

No such hard limit.  In the cloister in Brian Thomas' "If Monks Had Macs" CD
we have three audio players running sometimes simultaneously to provide bird
sounds and a waterfall sound.  The waterfall is constant, but the birds are
intermittent, with a semi-random algorithm that keeps them varied while
avoided moments where they might all sound off at once.  And on top of those
is a QT video of a rotating bookcase.

While the limit is not hard and fast, remember that QT is an event loop hog;
the more players running simultaneously the less CPU time is available to
other processes, like the enngine's event loop.

> Will setting the startTime buffer and
> queue the player?

Not sure what you mean by buffer in this context, but it will queue to the
specified point if you have the playSelection set to true.  In HyperRESEARCH
the QT playback is all about letting the user save and pay back specified
selections of time-based media (both audio and video).  Setting the
startTime and EndTime work great on Mac and win both, with only one caveat:
a bug was introduced in Rev 2.1 in which if you select a segment manually by
shift-clicking from right to left, the startTime and endTime reflect the
order of the user action rather than the logical start and end; i.e., they
two values will be reversed.  That's easy enough to work around, and in all
other respects everything I've done with player selection has been working
great since Rev 2.0.


> Is there a way to get the current time of a playing
> player?

  get the currentTime of player 1

-- 
 Richard Gaskin 
 Fourth World Media Corporation
 Developer of WebMerge: Publish any database on any Web site
 ___________________________________________________________
 Ambassador at FourthWorld.com       http://www.FourthWorld.com
 Tel: 323-225-3717                       AIM: FourthWorldInc




More information about the use-livecode mailing list