Playing audio files- some confusion ???

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
planix
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 47
Joined: Tue Mar 10, 2009 12:47 pm

Playing audio files- some confusion ???

Post by planix » Fri Jul 24, 2009 7:55 am

Hi,

I want to play WAV files, on a Windows platform, which are stored as files separate from the Rev file. I am not that interested in embedding the audio files as I want to ensure flexibility and ease of updating these files.

I have been fiddling around trying to get this figured. I have set up to not use QT. This way I can play companion MPG video files that I need for my project. (I converted them to MOV files but the playback was jerky and unsynched, so I would rather stick with MPG video playback if I can).

The player object that I can access (rev 3.5 Enterprise) seems to be only a video format player once I stop using QT. I load it with a WAV file and nothing happens. Yet the way documentation describes it is as an audio or video format player. So, what am I missing? Is it just that I have to use QT if I want to play both video and audio in the one project?

Any thoughts on this would be helpful.

cheers

Planix in Oz

I turned off
****************************************
PLANIX
"Knowing anything is better than knowing nothing. But knowing that nothing ain't anything, why that's just plain nirvana."

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

Post by Klaus » Fri Jul 24, 2009 9:47 am

Hi planix,

what exactly do you mean with "I load it with a WAV file and nothing happens."?
What did you exspect to happen?

A player object is a media player and will play video and audio files with or without QuickTime.


Best

Klaus

planix
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 47
Joined: Tue Mar 10, 2009 12:47 pm

Post by planix » Fri Jul 24, 2009 10:07 am

Hi Klaus,

I expect the WAV file to play. So, I set the Source of the player to the file and then use

Code: Select all

start player "VoiceOver"
and I expect to hear the voice over from the speakers.

In fact the file is not played. The player doesn't seem to know what to do with an audio file. There is no error message and no crash. Just no sound file being played.

I have assumed that it is a multimedia player with or without QT but I don't get expected results following the standard directions. So the question is whether I have done something wrong or misunderstood some concept.

cheers

Planix
****************************************
PLANIX
"Knowing anything is better than knowing nothing. But knowing that nothing ain't anything, why that's just plain nirvana."

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

Post by Klaus » Fri Jul 24, 2009 3:14 pm

Hi Planix,

did you check "the result" right after setting the filename of your player?
Maybe that gives us a hint?


Best

Klaus

P.S.
if you exspect to see a controller, that is a QT only feature ;-)

planix
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 47
Joined: Tue Mar 10, 2009 12:47 pm

Post by planix » Fri Jul 24, 2009 5:53 pm

Hi Klaus,

I am not expecting a controller.

Simply.

I set dontUseQT to true. This is because I am playing MPG video on a Windows system. QT won't play MPG and I don't want to use MOV files.

I also want to use audio in the same application but on a different card (substack really).

On the card where I want to play audio I have put a player object on the card. I set the source of that player to a WAV file located in a folder in the same directory as the rev application.

When I try to play the audio file using

Code: Select all

 start player "VoiceOver" 
nothing happens.

When I check the result the message is
could not open video player
.

It seems to me that when I disable the use of QT the player object stops being able to play audio files. Is this likely?

cheers
****************************************
PLANIX
"Knowing anything is better than knowing nothing. But knowing that nothing ain't anything, why that's just plain nirvana."

planix
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 47
Joined: Tue Mar 10, 2009 12:47 pm

Post by planix » Fri Jul 24, 2009 6:09 pm

Hi,

I think I know what I am doing wrong. I tried using an MP3 audio file in the player and it worked as expected.

I think WAV files are treated differently? Anyway, using MP3 for audios is a better idea anyway so that works for me.

Thanks for thinking about it.

Cheers
****************************************
PLANIX
"Knowing anything is better than knowing nothing. But knowing that nothing ain't anything, why that's just plain nirvana."

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

Post by Klaus » Sat Jul 25, 2009 1:24 pm

Hi planix,

hmm, it SHOULD also play WAV files (actaully everything the WMP can play!), but unfortunately media support without QT is a bit of russian roulette with Rev on windows :-/


Glad you got it working! :-)

Post Reply