Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(102)

Side by Side Diff: LayoutTests/webaudio/audiochannelmerger-stereo.html

Issue 208943004: Update WebAudio layout tests to use unprefixed AudioContext. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add console.log to compatibility.js Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 2
3 <!-- 3 <!--
4 Tests that that we can merge two mono streams into a stereo stream. 4 Tests that that we can merge two mono streams into a stereo stream.
5 --> 5 -->
6 6
7 <html> 7 <html>
8 <head> 8 <head>
9 <script src="../resources/js-test.js"></script> 9 <script src="../resources/js-test.js"></script>
10 <script src="resources/compatibility.js"></script>
10 <script type="text/javascript" src="resources/audio-testing.js"></script> 11 <script type="text/javascript" src="resources/audio-testing.js"></script>
11 <script type="text/javascript" src="resources/buffer-loader.js"></script> 12 <script type="text/javascript" src="resources/buffer-loader.js"></script>
12 </head> 13 </head>
13 14
14 <body> 15 <body>
15 16
16 <div id="description"></div> 17 <div id="description"></div>
17 <div id="console"></div> 18 <div id="console"></div>
18 19
19 <script> 20 <script>
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 72
72 function runTest() { 73 function runTest() {
73 if (window.testRunner) { 74 if (window.testRunner) {
74 testRunner.dumpAsText(); 75 testRunner.dumpAsText();
75 testRunner.waitUntilDone(); 76 testRunner.waitUntilDone();
76 } 77 }
77 78
78 window.jsTestIsAsync = true; 79 window.jsTestIsAsync = true;
79 80
80 // Create stereo offline audio context. 81 // Create stereo offline audio context.
81 context = new webkitOfflineAudioContext(2, lengthInSampleFrames, sampleRate) ; 82 context = new OfflineAudioContext(2, lengthInSampleFrames, sampleRate);
82 83
83 // Create two mono buffers, one having all -1 values, the other all +1. 84 // Create two mono buffers, one having all -1 values, the other all +1.
84 buffer1 = createBufferWithDCOffset(lengthInSampleFrames, sampleRate, -1); 85 buffer1 = createBufferWithDCOffset(lengthInSampleFrames, sampleRate, -1);
85 buffer2 = createBufferWithDCOffset(lengthInSampleFrames, sampleRate, 1); 86 buffer2 = createBufferWithDCOffset(lengthInSampleFrames, sampleRate, 1);
86 87
87 // Create a buffer source for each of these buffers. 88 // Create a buffer source for each of these buffers.
88 bufferSource1 = context.createBufferSource(); 89 bufferSource1 = context.createBufferSource();
89 bufferSource2 = context.createBufferSource(); 90 bufferSource2 = context.createBufferSource();
90 bufferSource1.buffer = buffer1; 91 bufferSource1.buffer = buffer1;
91 bufferSource2.buffer = buffer2; 92 bufferSource2.buffer = buffer2;
(...skipping 13 matching lines...) Expand all
105 context.oncomplete = checkResult; 106 context.oncomplete = checkResult;
106 context.startRendering(); 107 context.startRendering();
107 } 108 }
108 109
109 runTest(); 110 runTest();
110 111
111 </script> 112 </script>
112 113
113 </body> 114 </body>
114 </html> 115 </html>
OLDNEW
« no previous file with comments | « LayoutTests/webaudio/audiochannelmerger-basic.html ('k') | LayoutTests/webaudio/audiochannelsplitter.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698