Still stuck on playing a sound with a player

Klaus major-k klaus at major-k.de
Tue Dec 17 06:49:13 EST 2013


Hi Graham,

Am 17.12.2013 um 10:52 schrieb Graham Samuel <livfoss at mac.com>:

> Hi Jacque - thanks for your continued efforts to help. 
> 
> When I do the 'play', I get "no data in AudioClip". This is after I rewrote the code to use a separate invisible stack for the players, as you suggested. The player itself definitely exists.

See below...

> The script of the card I want to be showing while the sound plays just says:
> 
> on openCard
>     set the playrate of player "playPoem" of cd 1 of stack "sounds" to 1 
>     play "playPoem" of cd 1 of stack "Sounds" -- this just carries on until the player gets a 'playstopped' message
>     put the result
> end openCard

some comments:
1. "set the playrate of player XYZ to 1" already STARTS that player!
2. OFFICIAL syntax to start a player object: "start player XYZ"
3. "play" is "reserverd" for playing audio files that are NOT in a player object

Not that this would cause your problems... 8-)

> The player "playPoem" is newly attached to an MP3 file, which I have now moved to be next to the LC app in the 'Applications' folder, just for a change. Actually I get the same result even if I set the filename of each player at runtime.
> I get the feeling I am disobeying some secret rules. Jacque, when you use a separate stack for sounds, how do you initiate the sounds?

Hm, I also use a lot fo mp3 files and never had any problem with any player object (on a Mac!!! ;-)

> TIA and sorry to take up your time.
> 
> Graham

Best

Klaus


--
Klaus Major
http://www.major-k.de
klaus at major-k.de





More information about the use-livecode mailing list