| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <head> | 2 <head> |
| 3 <script type="text/javascript" src="webrtc_test_utilities.js"></script> | 3 <script type="text/javascript" src="webrtc_test_utilities.js"></script> |
| 4 <script type="text/javascript" src="depth_stream_test_utilities.js"></script> | 4 <script type="text/javascript" src="depth_stream_test_utilities.js"></script> |
| 5 <script type="text/javascript"> | 5 <script type="text/javascript"> |
| 6 | 6 |
| 7 function cubemapFaces(gl) { | 7 function cubemapFaces(gl) { |
| 8 return [gl.TEXTURE_CUBE_MAP_POSITIVE_X, | 8 return [gl.TEXTURE_CUBE_MAP_POSITIVE_X, |
| 9 gl.TEXTURE_CUBE_MAP_NEGATIVE_X, | 9 gl.TEXTURE_CUBE_MAP_NEGATIVE_X, |
| 10 gl.TEXTURE_CUBE_MAP_POSITIVE_Y, | 10 gl.TEXTURE_CUBE_MAP_POSITIVE_Y, |
| (...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 440 var color_step = 1.0 / (width + height); | 440 var color_step = 1.0 / (width + height); |
| 441 return verifyPixels(arr, width, height, flip_y, color_step, | 441 return verifyPixels(arr, width, height, flip_y, color_step, |
| 442 1.0 /*wrap_around*/, 1.5/65535 /*tolerance*/, | 442 1.0 /*wrap_around*/, 1.5/65535 /*tolerance*/, |
| 443 test_name); | 443 test_name); |
| 444 } | 444 } |
| 445 | 445 |
| 446 function readAndVerifyR32F(gl, width, height, flip_y, test_name) { | 446 function readAndVerifyR32F(gl, width, height, flip_y, test_name) { |
| 447 var arr = new Float32Array(width * height * 4); | 447 var arr = new Float32Array(width * height * 4); |
| 448 gl.readPixels(0, 0, width, height, gl.RGBA, gl.FLOAT, arr); | 448 gl.readPixels(0, 0, width, height, gl.RGBA, gl.FLOAT, arr); |
| 449 var color_step = 1.0 / (width + height); | 449 var color_step = 1.0 / (width + height); |
| 450 return verifyPixelsRed(arr, width, height, flip_y, color_step, | 450 return verifyPixels(arr, width, height, flip_y, color_step, |
| 451 1.0 /*wrap_around*/, 1.5 / 65535 /*tolerance*/, | 451 1.0 /*wrap_around*/, 1.5 / 65535 /*tolerance*/, |
| 452 » » » » » » test_name); | 452 test_name); |
| 453 } | 453 } |
| 454 | 454 |
| 455 function onLoad() { | 455 function onLoad() { |
| 456 var query = /query=(.*)/.exec(window.location.href); | 456 var query = /query=(.*)/.exec(window.location.href); |
| 457 if (!query) | 457 if (!query) |
| 458 return; | 458 return; |
| 459 if (query[1] == "RGBAUint8") | 459 if (query[1] == "RGBAUint8") |
| 460 depthStreamToRGBAUint8Texture(); | 460 depthStreamToRGBAUint8Texture(); |
| 461 else if (query[1] == "RGBAFloat") | 461 else if (query[1] == "RGBAFloat") |
| 462 depthStreamToRGBAFloatTexture(); | 462 depthStreamToRGBAFloatTexture(); |
| 463 else if (query[1] == "R32Float") | 463 else if (query[1] == "R32Float") |
| 464 depthStreamToR32FloatTexture(); | 464 depthStreamToR32FloatTexture(); |
| 465 } | 465 } |
| 466 </script> | 466 </script> |
| 467 </head> | 467 </head> |
| 468 <body onload="onLoad()"> | 468 <body onload="onLoad()"> |
| 469 <table border="0"> | 469 <table border="0"> |
| 470 <tr> | 470 <tr> |
| 471 <td><video id="local-view-1" width="96" height="96" autoplay | 471 <td><video id="local-view-1" width="96" height="96" autoplay |
| 472 style="display:none"></video></td> | 472 style="display:none"></video></td> |
| 473 <!-- The canvas is used to detect when video starts and stops. --> | 473 <!-- The canvas is used to detect when video starts and stops. --> |
| 474 <td><canvas id="local-view-1-canvas" width="96" height="96" | 474 <td><canvas id="local-view-1-canvas" width="96" height="96" |
| 475 style="display:none"></canvas></td> | 475 style="display:none"></canvas></td> |
| 476 </tr> | 476 </tr> |
| 477 </table> | 477 </table> |
| 478 </body> | 478 </body> |
| 479 </html> | 479 </html> |
| OLD | NEW |