Playing a sound in IOS

Getting into LiveCode for iOS? Ask your questions here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

maxs
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 421
Joined: Sat Jun 24, 2006 12:02 am

Re: Playing a sound in IOS

Post by maxs »

Ok, I did get a sound to play once in my ios simulator. But after 3 hours of endless variations, I has yet to recreate this feat.

I tried playing the sound "an.aif" from a folder (blendysounds) in the same folder(livecode) as the stack.

on mouseUp
play specialFolderPath("engine") & "/livecode/blendysounds/an.aif"
end mouseUp

I tried

on mouseUp
play specialFolderPath("engine") & "/blendysounds/an.aif"
end mouseUp

I copied blendysounds/an.aif into the copy files section on the App settings tab. Nothing works. (What, what what could I be missing?) Max
jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7423
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Playing a sound in IOS

Post by jacque »

What version of the simulator are you using? Sounds wouldn't work for me in one of the older ones.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com
maxs
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 421
Joined: Sat Jun 24, 2006 12:02 am

Re: Playing a sound in IOS

Post by maxs »

OK I found my mistake.

It appears that I needed to have an exact matching case for the text.

Hurrah!

Max
jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7423
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Playing a sound in IOS

Post by jacque »

I should have thought of that, it's bitten me too. iOS, like unix, is case-sensitive. There's a mention of it in the release notes somewhere. Very glad you're back in business.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com
jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2734
Joined: Sat Dec 22, 2007 5:35 pm
Contact:

Re: Playing a sound in IOS

Post by jmburnod »

Hi All,

Is there a way to play a sound file from a server in IOS ?

play MyUrl work on desktop but not in IOS

Best regards

Jean-Marc
https://alternatic.ch
maxs
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 421
Joined: Sat Jun 24, 2006 12:02 am

Re: Playing a sound in IOS

Post by maxs »

Hi,

I have created a standalone build for minimum version ios 4.2.

When I install the app on any machine that runs ios 5.0 , all the sound files play fine,

When I install the same app on any ipod that runs ios 4.2, none of the sound files play.


Why would the sounds not play on these slightly older machines. THE OTHER APPS produce sounds.

MAX
maxs
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 421
Joined: Sat Jun 24, 2006 12:02 am

Re: Playing a sound in IOS

Post by maxs »

Hi.

Does anyone ever had problems playing sound files in an app on a second generation ipod? I loaded the same program on an ipad and ipod touch 4 and sounds play fine. I use a 4.2 OS build.
maxs
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 421
Joined: Sat Jun 24, 2006 12:02 am

Re: Playing a sound in IOS

Post by maxs »

This seems to be my last hurtle in order to finish my first ios app. My school has only second generation ipods. So I must have sound files that will play in those machines. So here is my last call out to anyone they may have had success with livecode sounds files playing on second generation ipods.
Hi,

I have created a standalone build for minimum version ios 4.2.

When I install the app on any machine that runs ios 5.0 , all the sound files play fine,

When I install the same app on any ipod that runs ios 4.2, none of the sound files play.

MAX

Thank you to all for all previous help.
spencer
Posts: 71
Joined: Mon May 09, 2011 3:01 pm

Re: Playing a sound in IOS

Post by spencer »

We've gotten the best results using caf sound files - Apple Core Audio Format, developing apps in XCode with Objective-C, and delivering on IOS 4.2.
maxs
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 421
Joined: Sat Jun 24, 2006 12:02 am

Re: Playing a sound in IOS

Post by maxs »

OK So I finally figured out why my sound files were not playing in ios. All my sound files were in a folder on the desktop. Once I moved them out into a HD folder, they played.

Only 4 months for me to figure that one out.
.
Max
Post Reply