No sound on iPad.

Get help using Construct 2

Post » Thu Jul 24, 2014 8:19 pm

No sound is playing when I run my C2 HTML5 project on iPad. I've been scouring the forums for help with this issue, and while there are literally dozens of topics about sound issues on iOS, few of them seem to have been resolved.
Here's what I know about the issue:
  • I can hear no sound, but it's behaving as if the sounds are playing; events with the "on audio ended" condition fire at about the times I would expect them to if the sounds were playing correctly.
  • The audio files are between 11KB and 131KB in size (there's a lot of dialogue).
  • I'm testing on an iPad mini, version 7.1.2.
  • It's not muted and sound is working fine on other applications.
  • I've tried it in both Safari and Chrome on the iPad.
  • I've tried hosting it in my public dropbox folder and on our own server (and I had our server guy verify that the MIME types were all correct).
  • All of my sounds have been converted to .m4a and .ogg formats. (Some have suggested removing the ogg files, but I can't do that because I want it to work across multiple browsers.)
  • I've heard of the "first touch" issue; you need to touch the screen to even start my game and while it registers the touch, the sound still does not play.
  • I tried preloading some of the audio, but either it's taking a ridiculously long time to preload (several minutes for a ~20KB file) or it's just not preloading at all. (I made sure to touch the screen.)
  • Someone suggested removing all of the sound entries from the offline.appcache but that didn't make a difference.
  • I don't currently have the resources to use Ejecta.

This topic (which appears in the FAQ) suggests a solution involving "audio sprites": viewtopic.php?t=64226&start=0
However, in another topic Ashley says the technique is now out of date: span-class-posthilit-sound-span-not-playing-on-safari-amp-span-clas_p702067?#p702067

Has anyone else had audio issues on iOS and had success with getting them to work? What other info can I provide that would help pin down exactly what's going on?
B
6
S
1
Posts: 38
Reputation: 683

Post » Thu Jul 24, 2014 8:46 pm

I just tried preloading some audio, but to no avail. It doesn't even seem to be preloading, because I have an event set to trigger when it finishes preloading, and while the event triggers fine on PC, it doesn't on iPad.
B
6
S
1
Posts: 38
Reputation: 683

Post » Fri Jul 25, 2014 4:45 pm

Are there any specific... I dunno, encodings or whatever of audio files that are known to not work? (I'm not an audio expert, so I don't know what their called; I guess I just mean the settings that the audio files are saved with.)
B
6
S
1
Posts: 38
Reputation: 683

Post » Mon Jul 28, 2014 10:59 am

If you are not using ejecta, then with what are you running the project? CocoonJS? Phonegap?

For me, when in CocoonJS, it has played any kind of .ogg

What resources do you need for Ejecta? Why not?
B
38
S
6
G
1
Posts: 306
Reputation: 2,902

Post » Mon Jul 28, 2014 2:17 pm

damjancd wrote:If you are not using ejecta, then with what are you running the project? CocoonJS? Phonegap?

For me, when in CocoonJS, it has played any kind of .ogg

What resources do you need for Ejecta? Why not?


I just want it to play in the browser. And unless I'm mistaken, you need a Mac and an app store developer license to publish via Ejecta, neither of which I have right now. I only brought it up because other topics have mentioned Ejecta as a fix for iOS HTML5 audio issues, but I don't want to publish it as an app; I want it to remain in browser, but nothing I've tried has gotten the sound to work.
B
6
S
1
Posts: 38
Reputation: 683

Post » Mon Jul 28, 2014 6:58 pm

Sorry you are right. I can't think outside my app box since im publishing for appstore :)

Have you tried the new ios 8 beta? Maybe it works there? But again, to legally download that, youd need a mac dev license :(
B
38
S
6
G
1
Posts: 306
Reputation: 2,902

Post » Mon Jul 28, 2014 7:31 pm

Hi inejwstine,

Couple of suggestions that can be tedious, but might as well exhaust them if you are still stuck.

Round 1:
-When you import sounds into Construct try setting your encoding quality to the lowest first: 96kbps (lowest quality, quickest download.

Still no luck?

Round 2:
-Download Audacity. Save some of your native files as .wavs at 44100 bitrate from Audacity. Now try Round 1 again importing your new wavs from audacity.

Still, Still no luck?

Round 3:
-Let's test your Ipad Mini to see if it can play ANY sound exported from Construct2.

Make a new Construct file, import sounds from the free bundle that comes with your license. Make a button, etc. to play a sound you imported. Test to see if you can hear any of those when played on Ipad. If you CAN hear the bundled sounds, then it has got to be something with your source audio files or maybe an event in your actual file. If you CANNOT hear even the bundled sounds then the problem is bigger than just your one source file with that Ipad mini....

Granted, IOS is problematic. I've pulled my hair out a lot over the sound issues for device playback. But it is possible to get sounds to work. I use an ipad mini for testing as well and got sounds to work. However, I am using Cocoon for export, so we are a little different in that regard. Maybe I'll experiment on my mac to play natively without a wrapper.

Good luck and see if any of the above work for you. Keep at it.
B
6
S
1
G
1
Posts: 25
Reputation: 779

Post » Mon Jul 28, 2014 8:10 pm

@inejwstine
I "might" be able to help you ...

1) Load this app in your iPad default browser http://www.littlecomposers.com/apps/learn-note-names/treble-clef/
Let me know if you have sound issues.

I have tested all of my apps on the latest apple iPad and it is working (as well as in IE which was a pain to get going).

If you hear the sounds then you need to tweak your MIME type settings on your server.

Please let me know and I will write up a little tutorial because I too had to search for ever and a day 'till it worked.

Ciao for now,
V :)
Last edited by vancouver on Mon Oct 20, 2014 5:15 am, edited 1 time in total.
B
14
S
4
Posts: 190
Reputation: 1,735

Post » Wed Jul 30, 2014 2:22 pm

Thank you for the suggestions! I'm working on some other stuff at the moment, but when I get the chance I'll give some of those a try and let you know if they work! :-)
B
6
S
1
Posts: 38
Reputation: 683

Post » Sat Oct 18, 2014 4:31 pm

Hi inejwstine,

I have got exactly the same problem you got! I got no sound for my game when I upload to my server and try to play in a browser in my iPad + I thought this was only a situation for Browsers and it was working fine with Intel XDK emulator and not my app is online with no sound. So I was wondering if you have found a solution to this problem.

Kind Regards
Volkan
B
19
S
6
Posts: 179
Reputation: 2,202

Next

Return to How do I....?

Who is online

Users browsing this forum: Felipiwi and 27 guests