Why cocoonjs is using .ogg files in IOS even when i remove

0 favourites
  • 9 posts
From the Asset Store
With this template you will learn how to use the GooglePlay Games native plugin
  • I am using cocoonJS since cordova is not properly working for me through intelXDK. The zip file which cocoonJS is making has both m4a and .ogg files, which is making the zip heavier. So i manually have removed the .ogg files since i heard m4a files works fine on all IOS versions than ogg files.

    After this removal my sounds were stop and no audio was playing. So i checked the log of cocoonjs and found this error

    • Audio Load Error: Could not find audio file named "www/xyyz.ogg"

    So i thought maybe somewhere inside construct2 js is forcefully using ogg file. So after few hours of work i have edited the JS part and made the following changes

    useOgg = !!(new Audio().canPlayType('audio/ogg; codecs="vorbis"'));
    useOgg = false;[/code:3j2hr0hq]
    
    I had to make this false because my iPAD had vorbis codec i believe that is why it was running ogg files from the start. 
    
    After this editing my all m4a files started working correctly.
    
    Now my confusion is does ogg files required in any kind of ios instead of m4a files? I need to make my app less heavier to compile through cocoonjs which takes 30mb only...So i am thinking to remove all the ogg files and just allow m4a to run on all version of ios but i am confuse if i am taking a right choice about audio???
  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Are you using Canvas+? If so, it is the expected result .

    In the Webview+ for iOS is when you must use m4a. But in Canvas+, it is required to use .ogg.

    Regards

  • Yes i am using Canvas+ because webview never shows anything on the screen and always displays black-screen. I made a very simple testing app and i am attaching here but if you run this with Webview it will display black screen without any single error.. that is why i was using canvas+, please can you guide me why its black screen i am using simple depreciated export by scirra on cocoonjs..

    https://dl.dropboxusercontent.com/u/104183650/newproject.zip

  • Hello,

    I can't run the file you sent me on the browser nor in the launcher. It seems something is wrong with the project itself.

    Can you please send me a capx and the steps you followed to export it?

    Cheers

  • here is my zip file i again exported using minify JS with depreciated Cocoonjs exporter from Construct2 Release 200.

    Exported Zip : https://www.dropbox.com/s/rrs7sn43yrmks ... t.zip?dl=0

    Capx: https://www.dropbox.com/s/9l88vihesypw5 ... .capx?dl=0

  • ludei are you able to find the problem???

  • Hello,

    No, because you deleted the files. Remember this is not our forum, we are not constantly checking it. In addition, there was a weekend in the middle .

    Cheers

  • ludei extremely sorry , here are the files once again ... I by mistake deleted that.

    CAPX: https://dl.dropboxusercontent.com/u/104 ... oject.capx

    Exported Project ZIP: https://www.dropbox.com/s/rrs7sn43yrmks ... t.zip?dl=0

  • I can run your project perfectly in the launcher. It has sound, it gets the .ogg files as it is supposed to because it is Canvas+. There is not a blank screen by now. I will try compiling the project.

    Edit: It works too once it is compiled.

    Edit2: It works in the new cloud too, apart from the known issue we are currently solving regarding ScreenCanvas and WebGL.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)