incubator-callback-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Becky Gibson (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CB-101) Failed to play audio file located in subfolders in Documents
Date Mon, 05 Dec 2011 22:48:41 GMT

    [ https://issues.apache.org/jira/browse/CB-101?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13163127#comment-13163127
] 

Becky Gibson commented on CB-101:
---------------------------------

There are a couple of problems in sound.m URLForResource. One is that we try to find the file
in the www dir first rather than checking for HTTP and DOCUMENTS scheme first.  Next is how
the URL is created:
else if ([resourcePath hasPrefix:DOCUMENTS_SCHEME_PREFIX]) {
        NSLog(@"Will use resource '%@' from the documents folder.", resourcePath);
        resourceURL = [NSURL URLWithString:resourcePath];
        
        NSString* recordingPath = [NSString stringWithFormat:@"%@/%@", [PhoneGapDelegate applicationDocumentsDirectory],
[resourceURL host]];
        NSLog(@"recordingPath = %@", recordingPath);
        resourceURL = [NSURL fileURLWithPath:recordingPath];

need to debug some more....

                
> Failed to play audio file located in subfolders in Documents
> ------------------------------------------------------------
>
>                 Key: CB-101
>                 URL: https://issues.apache.org/jira/browse/CB-101
>             Project: Apache Callback
>          Issue Type: Bug
>          Components: iOS
>    Affects Versions: 1.2.0
>         Environment: iOS SDK 5.0
>            Reporter: Binh An Tran
>            Assignee: Shazron Abdullah
>              Labels: ios,, local,, media, mp3
>
> i have an audio file test.mp3.
> when the file located in "Documents" folder, and i create my media object like this :media
= new Media('documents://test.mp3'); Everything works fine.
> but when my audio file located in a subfolder in "Documents" folder, say "Documents/data",
and i create my media object like this: media = new Media('documents://data/test.mp3'), i
have this error in console: Failed to initialize AVAudioPlayer: (null) . And error code =
4

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message