cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shazron Abdullah (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CB-5890) Media won't play local file on iOS
Date Mon, 05 May 2014 21:51:17 GMT

     [ https://issues.apache.org/jira/browse/CB-5890?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Shazron Abdullah updated CB-5890:
---------------------------------

    Environment: iOS  (was: Mac OSX)

> Media won't play local file on iOS
> ----------------------------------
>
>                 Key: CB-5890
>                 URL: https://issues.apache.org/jira/browse/CB-5890
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: Plugin Media
>    Affects Versions: 3.3.0
>         Environment: iOS
>            Reporter: John M. Wargo
>
> I have an application that will play a media file on Android, but not on iOS. When I
try to play the file, the console indicates that it can find the file, but fails on opening
it:
> Failed to initialize AVAudioPlayer
> Here's some console entries:
> 2014-01-24 08:49:51.374 Ex141[386:60b] Entering doPlay
> 2014-01-24 08:49:51.376 Ex141[386:60b] Found resource '/var/mobile/Applications/C557863E-BB8C-4384-8188-9C36B5B603C4/Ex141.app/www/sample.mp3'
in the web folder.
> 2014-01-24 08:49:51.391 Ex141[386:60b] Failed to initialize AVAudioPlayer: The operation
couldn’t be completed. (OSStatus error 1685348671.)
> 2014-01-24 08:49:51.394 Ex141[386:60b] THREAD WARNING: ['Media'] took '18.647949' ms.
Plugin should use a background thread.
> 2014-01-24 08:49:51.396 Ex141[386:60b] Leaving doPlay
> 2014-01-24 08:49:51.397 Ex141[386:60b] ERROR: Entering mediaError
> 2014-01-24 08:49:51.398 Ex141[386:60b] ERROR: {"message":"","code":4}
> Notice that the message string is blank. 
> This is my code:
> theFile = 'sample.mp3';
> theMedia = new Media(theFile, mediaSuccess, mediaError, mediaStatus);
> theMedia.play();



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message