Audio / Music MIME Question

Discussion and feedback on Construct 2

Post » Wed Jan 23, 2013 7:37 pm

or is it AddType audio/mp4 ???
B
5
Posts: 58
Reputation: 916

Post » Wed Jan 23, 2013 7:42 pm

Ok, I found this C2 tutorial, but I don't think it explains very well what to do, or how to do it..

MIME types
In order for your server to send audio files correctly, it must be set up with the following MIME types:

.ogg as audio/ogg
.m4a as audio/mp4

This explanation could offer a little bit more information to be helpful.
B
5
Posts: 58
Reputation: 916

Post » Wed Jan 23, 2013 7:52 pm

@balistrerinick

On my webserver which is apache I have a .htaccess file with the following contents:

AddType video/ogg .ogv
AddType application/ogg .ogg
AddType video/mp4 .mp4
AddType video/webm .webm
AddType audio/aac .aac
AddType audio/mp4 .mp4 .m4a
AddType audio/mpeg .mp1 .mp2 .mp3 .mpg .mpeg
AddType audio/ogg .oga .ogg
AddType audio/wav .wav
AddType audio/webm .webm

This file is located in the games root directory.

.htaccess is just a text file that I created in notepad.rfisher2013-01-23 19:53:32
B
17
S
9
G
7
Posts: 249
Reputation: 6,922

Post » Thu Jan 24, 2013 1:16 am

Thank you rfisher...

Here is a link to my test page..
http://www.brotechentertainment.com/test/index.html

This basically has one button that makes a BOING sound effect
and counts each button click.
It also is touch enabled for cell phones and tablets.

Test Results
Explorer = OK
Chrome = OK
Mozilla = OK
Android = OK (slow button response for some reason)
iPad = No sound still

Any ideas what could be the problem with the iPad ??
B
5
Posts: 58
Reputation: 916

Post » Thu Jan 24, 2013 1:36 am

This link plays the BOING sound just fine directly, however, not when thru my test game.. ???????????????????????????????????????????????

Boing Sound effect
http://www.brotechentertainment.com/test/media/boing_x.m4a

Here is the CAPX
http://www.brotechentertainment.com/test/test1.capx
B
5
Posts: 58
Reputation: 916

Post » Thu Jan 24, 2013 1:41 am

A link to the MIME file discussed earlier
http://www.brotechentertainment.com/test/.htaccess
B
5
Posts: 58
Reputation: 916

Post » Thu Jan 24, 2013 7:14 pm

@Ashley

I was hoping you may know what could be casuing my final hang up regarding no sound just iPad.

I searched the forums and followed all the help I've gotten and I can hear my test sound on Chrome, Explorer, and Mozilla. I can also hear
it on my ANdroid cell phone. My Touch button events work also.

I have updated my test game pattern to count each time the button is touched so I know the Touch button function is executed.

I created a TXT file called ".htaccess" and put it in my root game directory, and also my home directory..

Here is what is in the .htaccess file

AddType video/ogg .ogv
AddType application/ogg .ogg
AddType video/mp4 .mp4
AddType video/webm .webm
AddType audio/aac .aac
AddType audio/mp4 .mp4 .m4a
AddType audio/mpeg .mp1 .mp2 .mp3 .mpg .mpeg
AddType audio/ogg .oga .ogg
AddType audio/wav .wav
AddType audio/webm .webm

When I execute the sound effect URL within the iPad, it works, so I must believe that my server settings should be correct since this sound file is located on my website..

Boing Sound effect
http://www.brotechentertainment.com/test/media/boing_x.m4a

Here is the CAPX
http://www.brotechentertainment.com/test/test1.capx

So, to recap, button touch makes the sound on Android.
Button Touch on iPad counts off, meaning button touch works, but no sounds.

Here is s link to my test game pattern I made to resolve this issue.

HELP !!!!!

I can't move ahead with my actual game until I resolve this...
http://www.brotechentertainment.com/test/index.html
B
5
Posts: 58
Reputation: 916

Post » Fri Jan 25, 2013 1:49 am

It looks like the MIME types are correct now. Try changing the URL. The iPad might have cached an old broken version.
Scirra Founder
B
359
S
214
G
72
Posts: 22,946
Reputation: 178,478

Post » Fri Jan 25, 2013 5:42 pm

Hi Ashley, thank you for the help..
I apologize if I seem like a pain, I just haven't found a good reason or explanation as to what could be the problem.

Here are links to my latest test post, which I date coded on the screen so I could verify that latest version is posted and running when I'm testing.

SInce I can play the sound file link on the iPad iOS 6.0 and it works, I have to assume my server is set up and the iPad can play the "boing_x.m4a" file from my site ok.

So, the problem must be C2 itself, or my code within C2. I have a much larger game that I am also unable to hear on the iPad, which is why I created a simple test game to debug my problem.

I really appreciate any help I can get resolving this problem. I think I have it isolated to the game code, but I am at a loss as to why? Works everywhere else.

Test Game
http://www.brotechentertainment.com/test/index.html
Single File CAPX
http://www.brotechentertainment.com/test/test_single_file.capx
Sound
http://www.brotechentertainment.com/test/media/boing_x.m4a
B
5
Posts: 58
Reputation: 916

Previous

Return to Construct 2 General

Who is online

Users browsing this forum: DankP3, NetOne and 3 guests