| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <body> | 3 <body> |
| 4 <script src="../resources/runner.js"></script> | 4 <script src="../resources/runner.js"></script> |
| 5 <script src="resources/canvas_runner.js"></script> | 5 <script src="resources/canvas_runner.js"></script> |
| 6 <script> | 6 <script> |
| 7 | 7 |
| 8 var sourceCanvas3D = document.createElement('canvas'); | 8 var sourceCanvas3D = document.createElement('canvas'); |
| 9 var sourceCtx = sourceCanvas3D.getContext('webgl'); | 9 var sourceCtx = sourceCanvas3D.getContext('webgl'); |
| 10 var destCanvas3D = document.createElement('canvas'); | 10 var destCanvas3D = document.createElement('canvas'); |
| 11 var destCtx = destCanvas3D.getContext('webgl'); | 11 var destCtx = destCanvas3D.getContext('webgl'); |
| 12 if (!sourceCtx || !destCtx) | 12 if (!sourceCtx || !destCtx) |
| 13 CanvasRunner.logFatalError("\nWebGL is not supported or enabled on this plat
form!\n"); | 13 CanvasRunner.logFatalError("WebGL is not supported or enabled on this platfo
rm!"); |
| 14 var tex = null; | 14 var tex = null; |
| 15 | 15 |
| 16 function setSize(width, height) { | 16 function setSize(width, height) { |
| 17 sourceCanvas3D.width = width; | 17 sourceCanvas3D.width = width; |
| 18 sourceCanvas3D.height = height; | 18 sourceCanvas3D.height = height; |
| 19 destCanvas3D.width = width; | 19 destCanvas3D.width = width; |
| 20 destCanvas3D.height = height; | 20 destCanvas3D.height = height; |
| 21 } | 21 } |
| 22 | 22 |
| 23 function rand(range) { | 23 function rand(range) { |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 description: "This benchmark checks the speed on uploading WebGL(1024x10
24) to WebGL Texture(1024x1024).", | 57 description: "This benchmark checks the speed on uploading WebGL(1024x10
24) to WebGL Texture(1024x1024).", |
| 58 preRun: preRun, | 58 preRun: preRun, |
| 59 doRun: doRun, | 59 doRun: doRun, |
| 60 ensureComplete: ensureComplete, | 60 ensureComplete: ensureComplete, |
| 61 postRun: postRun}); | 61 postRun: postRun}); |
| 62 } | 62 } |
| 63 | 63 |
| 64 </script> | 64 </script> |
| 65 </body> | 65 </body> |
| 66 </html> | 66 </html> |
| OLD | NEW |