ippa / jaws

Jaws - HTML5 canvas javascript 2D Game Framework
https://jawsjs.ippa.se
GNU Lesser General Public License v3.0
364 stars 75 forks source link

Update assets.js: Docs, Fixes #86

Closed videlais closed 11 years ago

videlais commented 11 years ago

Changes:

-- jaws.assets.file_type has support for Audio {wav, mp3, ogg, m4a, weba, aac, mka, flac} and Video {mp4, ogv, mkv, webm}

-- jaws.assets.can_play now populates an object detecting browser support during runtime for all MIME types in jaws.assets.file_type.

-- jaws.assets.load will now (using file_type and can_play) auto-detect and load known audio and video MIME types.

-- All unknown MIME types (those not found in file_type) are now loaded as blob-objects within the jaws.assets.data cache.

-- jaws.assets.load can now handle absolute URLs through detection of a protocol field within the resource path.

-- Every public function now tests its arguments via jaws.isType functions and calls jaws.log before returning if failed.

-- All functions are now documented using the JSDocs format for their descriptions, parameters and return types.