1. #1
    Sencha User
    Join Date
    Oct 2012
    Posts
    3
    Vote Rating
    0
    tapengine is on a distinguished road

      0  

    Default how to make sound play when scene start?

    how to make sound play when scene start?


    i make some web application using buzz.js. it's work great when use with "on click" action.
    but now I want to play sound when scene start up
    sound played when I open in safari on my mac but nothing in my iPhone app? Why?

    here is my script.

    start>Custom Javascript>soundTitle.play();

  2. #2
    Sencha User arnebech's Avatar
    Join Date
    Jun 2010
    Posts
    498
    Vote Rating
    10
    arnebech will become famous soon enough

      0  

    Default


    Typically on the iOS, sound events have to be started by the user. This is a restriction Apple has put on their devices (probably to restrict autoplay).

  3. #3
    Sencha User
    Join Date
    Oct 2012
    Posts
    3
    Vote Rating
    0
    tapengine is on a distinguished road

      0  

    Default


    Thanks for your reply

  4. #4
    Sencha User
    Join Date
    Oct 2012
    Posts
    3
    Vote Rating
    0
    tapengine is on a distinguished road

      0  

    Default I found solution!!

    I found solution!!


    I found solution to fix this problem.

    just add this property to web-view

    webView.mediaPlaybackRequiresUserAction = NO;


    hope it helpful to you

  5. #5
    Sencha User arnebech's Avatar
    Join Date
    Jun 2010
    Posts
    498
    Vote Rating
    10
    arnebech will become famous soon enough

      0  

    Default


    That is a good point!

    Just to clarify for other readers, if you are embedding your own webview in an iOS application (in xcode) you have more control, and you can enable playback without user interaction.
    mediaPlaybackRequiresUserAction

  6. #6
    Sencha User janmejay.mohapatra's Avatar
    Join Date
    Jul 2012
    Location
    Bhubaneswar
    Posts
    11
    Vote Rating
    0
    janmejay.mohapatra is on a distinguished road

      0  

    Default how do i do it in Android

    how do i do it in Android


    Hi,

    I am also using buzz.js for an android build. My production deployment build is working fine. But when I package it for native the sound is missing. There are no errors.
    Regards
    Janmejay
    about.me/janmejaymohapatra

Thread Participants: 2

Tags for this Thread