Results 1 to 4 of 4
  1.    #1  
    I've posted a new article on my blog, along with a sample app, to demonstrate the use of HTML5 audio in webOS apps, post 1.4. Any questions about using audio, or the app or source code should be asked here.

    Article: http://bit.ly/jdf-sample-audio
    Source: Source Code JDF-Software.com
    App: http://developer.palm.com/appredirec...e.audio-sample
  2. #2  
    For me the media loop does only work with WAV and not with MP3. Is that a BUG or is my Code wrong? Discuss here: Forums webOS • View topic - Music loop trouble: WAV works, MP3 not (BUG?)

    My code:

    MainAssistant.prototype.mediaSetup = function() {

    this.libs = MojoLoader.require({ name: "mediaextension", version: "1.0"});

    this.myAudio = this.controller.get('audio');
    this.audioExt = this.libs.mediaextension.MediaExtension.getInstance(this.myAudio);
    this.myAudio.src = Mojo.appPath + "audio/song.wav";
    this.myAudio.load();
    this.mediaReplay = this.mediaReplay.bind(this);
    this.myAudio.addEventListener('ended', this.mediaReplay, false);
    this.myAudio.play();

    }

    MainAssistant.prototype.mediaReplay = function() {
    this.myAudio.play();
    }
    Last edited by simsche; 09/07/2010 at 01:31 PM. Reason: Code added
  3. #3  
    hmmm
  4. #4  
    Now it works!
    My BUG...


    I used this code (main-scene.html)...
    <audio id="audio" controls="false" x-palm-media-audio-class="navigation">
    ...for the loop. Only WAV worked, no MP3. Don't ask my why, but if you wanna user MP3 you had to use this code:
    <audio id="audio" controls="false" x-palm-media-audio-class="media">

Tags for this Thread

Posting Permissions