Skip to content

v2.15

Compare
Choose a tag to compare
@quinton-ashley quinton-ashley released this 17 Jan 16:02
· 12 commits to main since this release

2.15.4

Added sound.pause() capability, which pauses all instances of sound playback. If sound.play() is called while sound.paused is true, then all instances of sound playback are resumed.

Also added getters for the sound's properties.

Documentation for q5-sound is now available:
https://q5js.org/learn/#sound-section

2.15.3

Q5.Sound objects, created in loadSound, are now fully backed by the WebAudio API, which has low latency and that's better for interactive art. Also if a sound is playing and the play function is called again, layered playback will occur over any previous playback of the sound.

The tradeoff is that q5 sounds have to load completely to be considered loaded. Use loadAudio for quicker preloading of long audio files, since it marks the audio file as loaded after the canplaythrough event triggers. Also note that q5 sounds can not be played on mobile with silent mode on (aka ringer off) but Audio elements can.

Fixed issues where errors or the audio context being in an interrupted state (when silence mode is on), caused audio to fail to load and not decrement the preloadCount, causing q5 to be stuck in the preloading state.

2.15.0

The default renderer of q5.js, based on CanvasRenderingContext2D (aka Canvas2D), will now be consistently referred to as the c2d renderer instead of q2d. Source files for this renderer were renamed, the "2d" prefix was replaced with "c2d". This is to avoid confusion because the webgpu renderer is also 2D.