Page 1 of 1

playing sounds

Posted: Tue Mar 01, 2011 10:23 am
by Poupette
Hello,

I want to make a simply player with 3 buttons:

Play , pause ans stop .

in the button play I've write : play "/mysound.wav"

but instead of playing the track there's just a horrible noise :cry:

and I can't find how to stop the playing.

Is there someone to help me , please?

(and I apologize for my English)

Re: playing sounds

Posted: Tue Mar 01, 2011 10:36 am
by Klaus
Bonjour Poupette,

create a little PANIC BUTTON:

Code: Select all

on moueup
  play stop ac
end mouseup
8)

LiveCode is VERY picky, when it comes to play sounds.
When using the "play ac..." command you can only use
UNCOMPRESSED AIF and WAV files and the compressed AU format.

But you can use a "player" object to play all other QuickTime compatible
sounds like MP3 (and video and image formats). This requires QuickTIme
to be installed on the end users machine however.

Then you can use a script to:
start player "Name of player here"
...
stop player "Name of player here"
...
set the filename of player "Name of player here" to "another_sound.WAV"
...

Best

Klaus

Re: playing sounds

Posted: Thu Mar 03, 2011 12:31 pm
by Poupette
thank you very much for your answer.

(I'm triyng to make a simply player. )