Playing audio called from a different card

Visuals, audio, animation. Blended, not stirred. If LiveCode is part of your rich media production toolbox, this is the forum for you.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
gyroscope
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 404
Joined: Tue Jan 08, 2008 3:44 pm
Contact:

Playing audio called from a different card

Post by gyroscope » Fri May 16, 2008 10:46 am

Hi, can anyone help please with the following:

play player "This Sound" works fine, but play player "This Sound another" on card 2 -- or next card, brings up a black box containing the name of the audio file (and no sound).

So:

Code: Select all

 play player "This Sound" on card 2 -- doesn't work; 
Anyone know the correct syntax please?

:)

Klaus
Posts: 14177
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Post by Klaus » Fri May 16, 2008 11:12 am

Hi gyroscope,

this is not possible!
You can only "start" a player that is on the current card!

The trick is to group all your players in a stack and place this group on every card where you need them.
OR put all your players on a card in an invisible stack that is always available/open.


Hope that helps.


Best

Klaus

gyroscope
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 404
Joined: Tue Jan 08, 2008 3:44 pm
Contact:

Post by gyroscope » Fri May 16, 2008 2:52 pm

Hi Klaus
this is not possible!
It's just clicked why: no one wants a player playing a video that you can't see! But some people (like me) would want audio which you could hear without seeing the neat nest of audio players on a different card... I wonder if the Rev team would consider that as a possibility at some time?

But in the meantime, I'll hide the stacked players on the card running them as you suggested.

Thank you for your help, Klaus.

:)

Drachen Jager
Posts: 20
Joined: Tue Aug 28, 2007 9:23 pm

Post by Drachen Jager » Wed May 21, 2008 9:57 pm

You could make the player invisible or place it behind something else.

You can also just

Code: Select all

Play "audiofile.wav"
Playing sounds without a player only works for some file formats however.[/code]

gyroscope
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 404
Joined: Tue Jan 08, 2008 3:44 pm
Contact:

Post by gyroscope » Thu May 22, 2008 2:53 pm

Thank you for that info, Drachen.

Yup, I think I'll go with all of my players piled on top of each other and hidden behind an object (or make them all invisible); that should do the trick!

:)

Post Reply