Giter Site home page Giter Site logo

jukebox's Introduction

Zynga's Jukebox (v1.0)

The Jukebox is a component for playing sounds and music with the usage of sprites with a special focus on performance and cross-device deployment. It is known to run even on Android 1.6+ devices and needs very few resources compared to other solutions on the web.

Features

  • Targets low-end devices and mobile platforms
  • HTML5 Audio
  • Flash Audio as fallback (support for Android 1.6)
  • Sound-Spritemap Entries for easier playback
  • Multiple Jukeboxes for parallel playback

Jukebox Manager adds the following features:

  • Codec Detection
  • Feature Detection
  • Automatic Work Delegation for busy Jukeboxes
  • Automatic Stream Correction (useful for slow implementations)
  • Automatic Looping for Sound-Spritemap entries
  • Playback of Background Music

Using Jukebox without Jukebox Manager:

It is not recommended to use Jukebox without the Jukebox Manager, but it's still possible. The Jukebox Manager offers Codec and Feature detection - to determine which kind of audio codecs will playback properly in your environment. If you want to still use Jukebox without Jukebox Manager, you will have to set resources to an Array containing only one resource.

Upcoming Features

  • Dynamic balancing of free clones at runtime

Documentation

There's a huge documentation of Jukebox available at github pages. You are invited to read it, there are also many try-it-yourself demos.

The documentation is also attached in the /doc folder if you clone the git repository.

Known Issues (iOS)

iOS has a huge delay when using an encoded format for playback. That's because of their iTunes-using implementation. You can fix these delays using an AIFF container with IMA4 encoding. These are called Core Audio Files then.

Also, the music spritemap will continue playback if the display is turned off and the JavaScript runtime was stopped. This is a known issue and is reported to the iOS developers. Additionally, iOS' security model prevents a website from playing sounds without prior user interaction.

Further there is only the capability of playing back one sound in parallel on iOS.

Please take a look at both the iOS demo and the iOS AIFF demo to see the difference in playback latencies and to find out how you can solve all these issues with sound on iOS.

jukebox's People

Contributors

pbakaus avatar tonistiigi avatar

Watchers

Bob avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.