Hi all,
here are more informations about the below question:
1. The loaded file is a mp3 file (can be understand from code name var)
2. For a waiting time of 6 seconds, the mp3 file is around 5.2 MB,
3. The whole application is frozed while the seconds ellapse...
4. I added a Thread, put the code below in .Run and call Run from the code:
I do not have the application "freeze",
I cannot stop the song playing anymore.
5. This sends me some years in the past when I was always stopped at around 75%
of the application because I didn't know how to continue (I checked all my
options and didn't found work-arounds or different ways of doing the thing); I
have tons of projects on hold somewhere on hard disk or CD-Archive...
Every idea / advice will be taken with extreme care, so thank you for sending
some...
Emile
[EMAIL PROTECTED] wrote:
Subject: Playing mp3 file time latency
From: Emile Schwarz <[EMAIL PROTECTED]>
Date: Thu, 16 Feb 2006 21:10:44 +0100
Hi,
REALbasic 5.5.5 (temporary)
Mac OS X 10.3.9
The following code returns 7 seconds of wasted time (watch the code below); WHY
?
On the other hand, using a MoviePlayer, there is no latency (wasted) time, but
how do I cancel the song (the MoviePlayer is not visible)...
Dim mp3Song As Sound
Dim tickStart As Double
Dim tickEnd As Double
tickStart = Ticks
mp3Song = targetSndFI.OpenAsSound
mp3Song.Play
tickEnd = Ticks
MsgBox "Latency: " + Str((tickEnd - tickStart) \ 60)
While mp3Song.isPlaying
If UserCancelled Then mp3Song.Stop
Wend
Am I right / wrong / beside my shoes ?
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>