Antylum Posted November 19, 2013 Share Posted November 19, 2013 Hi all! Need to test audio playability on different devices, and if it's not good, I will use Web Audio - as it's supported only by ios 6.0 and later, I need to check OS version first. Here is the link: https://dl.dropboxusercontent.com/u/196612177/browserTest/ios_Test1.html or shorten one: http://bit.ly/1dfeIfW For that I use:navigator.appVersion,navigator.userAgent,navigator.platformThe most important is platform. Plz, write what your browser on iOS/Android and other mobile devices has for this values and your iOS/Android version. Second test is audio - it's 99% not loaded, so press on 'Try to load sounds' button and then on 'sound1', 'sound2', 'sound3'. Do the sounds can be played? Quote Link to comment Share on other sites More sharing options...
rich Posted November 20, 2013 Share Posted November 20, 2013 This seems backwards - why not just check to see if Web Audio is available? You only need check for the AudioContext (and webkit prefix version). Then you'll know instantly if you can support it or not. Quote Link to comment Share on other sites More sharing options...
Antylum Posted November 20, 2013 Author Share Posted November 20, 2013 Thanks for tip, Rich! I wanted to make drawback from Web Audio Api to AudioSprites, if iOS version is lower than 6.0. But after testing I see that one audio channel sounds very bad - it's better to have no sound.I found a way to check OS, think it will be helpful for somebody (tested by me only on windows) : var playerOS = 'dont know'; if(navigator.userAgent.match(/iPhone|iPad/gi)) { playerOS = 'iOS'; } else if(navigator.userAgent.match(/Android/gi)) { playerOS = 'Android'; } else if(navigator.userAgent.match(/Windows/gi)) { playerOS = 'Windows'; } else if(navigator.userAgent.match(/Linux/gi)) { playerOS = 'Linux'; } if(navigator.userAgent.match(/OSX/gi)) { playerOS = 'Mac OS'; } alert('Your OS is: '); alert(playerOS); Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.