Skip to content

Commit 4d7ff23

Browse files
committed
Device.Audio.wav now uses audio/wav as the canPlayType check string, instead of audio/wav; codecs="1", which should allow iOS13 to play wav files again.
1 parent 368ad3b commit 4d7ff23

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

src/device/Audio.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ var Browser = require('./Browser');
1111
* These values are read-only and populated during the boot sequence of the game.
1212
* They are then referenced by internal game systems and are available for you to access
1313
* via `this.sys.game.device.audio` from within any Scene.
14-
*
14+
*
1515
* @typedef {object} Phaser.Device.Audio
1616
* @since 3.0.0
17-
*
17+
*
1818
* @property {boolean} audioData - Can this device play HTML Audio tags?
1919
* @property {boolean} dolby - Can this device play EC-3 Dolby Digital Plus files?
2020
* @property {boolean} m4a - Can this device can play m4a files.
@@ -70,8 +70,7 @@ function init ()
7070

7171
// Mimetypes accepted:
7272
// developer.mozilla.org/En/Media_formats_supported_by_the_audio_and_video_elements
73-
// bit.ly/iphoneoscodecs
74-
if (audioElement.canPlayType('audio/wav; codecs="1"').replace(/^no$/, ''))
73+
if (audioElement.canPlayType('audio/wav').replace(/^no$/, ''))
7574
{
7675
Audio.wav = true;
7776
}

0 commit comments

Comments
 (0)