tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

buffer-source-resampling-start-1.html (515B)


      1 <!DOCTYPE html>
      2 <html class="reftest-wait">
      3 <script>
      4 const rate = 44101; // not divisible by 2
      5 var context = new window.OfflineAudioContext(1, 512, rate);
      6 var buffer = context.createBuffer(1, 128, rate);
      7 buffer.getChannelData(0)[0] = 1.0;
      8 var source = context.createBufferSource();
      9 source.buffer = buffer;
     10 source.playbackRate.value = rate / (Math.pow(2, 30) * 1.0000001);
     11 source.start(512 / rate);
     12 context.startRendering().
     13  then(function() {
     14    document.documentElement.removeAttribute("class");
     15  });
     16 </script>