Skip to content

Instantly share code, notes, and snippets.

@vitaliy-bobrov
Created June 17, 2019 19:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vitaliy-bobrov/a4ab8f3f548e91ce1bd03ccc88c21c4c to your computer and use it in GitHub Desktop.
Save vitaliy-bobrov/a4ab8f3f548e91ce1bd03ccc88c21c4c to your computer and use it in GitHub Desktop.
const bassNode = new BiquadFilterNode(context, {
type: 'lowshelf',
frequency: 500
});
const midNode = new BiquadFilterNode(context, {
type: 'peaking',
Q: Math.SQRT1_2,
frequency: 1500
});
const trebleNode = new BiquadFilterNode(context, {
type: 'highshelf',
frequency: 3000
});
// Decreasing bass level by 10 dB.
bassNode.gain.value = -10;
// Increasing middle level by 15 dB.
midNode.gain.value = 15;
// No boost.
trebleNode.gain.value = 0;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment