
Security News
npm Adopts OIDC for Trusted Publishing in CI/CD Workflows
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.
web-audio-api
Advanced tools
This library implements the web audio API specification on node.js.
Why the hell doing that??? I know it sounds crazy, so I guess I'll have to build a case for it, and write some blog posts.
And this is not even alpha. Use this library only if you're the adventurous kind.
Most of the AudioNodes ... Most of many other things ... :(
npm install web-audio-api
Get ready, this is going to blow up your mind :
node test/manual-testing/AudioContext-sound-output.js
AudioContext
just writes PCM data to a node writable stream. The default stream is a stream created with Speaker
, which plays the audio back to your soundcard. But you can use any writable stream, file, or stream the audio to an external process.
I used this to stream audio to an icecast server :
var spawn = require('child_process').spawn
, AudioContext = require('web-audio-api').AudioContext
, context = new AudioContext()
var ices = spawn('ices', ['ices.xml'])
context.outStream = ices.stdin
Cool huh?
Tests are written with mocha. To run them, install mocha with :
npm install -g mocha
And in the root folder run :
mocha
To test the sound output :
node test/manual-testing/AudioContext-sound-output.js
To test AudioParam
against AudioParam
implemented in a browser, open test/manual-testing/AudioParam-browser-plots.html
in that browser.
0.1 initial release
0.1.0
FAQs
Node.js implementation of Web audio API
The npm package web-audio-api receives a total of 3,678 weekly downloads. As such, web-audio-api popularity was classified as popular.
We found that web-audio-api demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.
Research
/Security News
A RubyGems malware campaign used 60 malicious packages posing as automation tools to steal credentials from social media and marketing tool users.
Security News
The CNA Scorecard ranks CVE issuers by data completeness, revealing major gaps in patch info and software identifiers across thousands of vulnerabilities.