blob: f931438fe2255d5ac68721435514f0b84e09940b [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<script src="resources/audio-testing.js"></script>
<script src="../resources/js-test.js"></script>
<script src="resources/biquad-testing.js"></script>
</head>
<body>
<div id="description"></div>
<div id="console"></div>
<script>
description("Tests Biquad lowpass filter.");
function runTest() {
window.jsTestIsAsync = true;
// Create offline audio context.
var context = new webkitOfflineAudioContext(2, sampleRate * renderLengthSeconds, sampleRate);
// Dummy filter to get filter type constant
var f = context.createBiquadFilter();
// The filters we want to test.
var filterParameters = [{cutoff : 0, q : 1, gain : 1 },
{cutoff : 1, q : 1, gain : 1 },
{cutoff : 0.25, q : 1, gain : 1 },
{cutoff : 0.25, q : 1, gain : 1, detune : 100 },
{cutoff : 0.01, q : 1, gain : 1, detune : -200 },
];
createTestAndRun(context, "lowpass", filterParameters);
}
runTest();
</script>
</body>
</html>