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

Side by Side Diff: client/html/generated/src/wrapping/_WebGLRenderingContextWrappingImplementation.dart

Issue 8835006: New version of dart:html (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix typos Created 9 years 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 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // WARNING: Do not edit - generated code. 5 // WARNING: Do not edit - generated code.
6 6
7 class WebGLRenderingContextWrappingImplementation extends CanvasRenderingContext WrappingImplementation implements WebGLRenderingContext { 7 class WebGLRenderingContextWrappingImplementation extends CanvasRenderingContext WrappingImplementation implements WebGLRenderingContext {
8 WebGLRenderingContextWrappingImplementation._wrap(ptr) : super._wrap(ptr) {} 8 WebGLRenderingContextWrappingImplementation._wrap(ptr) : super._wrap(ptr) {}
9 9
10 int get drawingBufferHeight() { return _ptr.drawingBufferHeight; } 10 int get drawingBufferHeight() { return _ptr.drawingBufferHeight; }
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 return; 66 return;
67 } 67 }
68 68
69 void blendFuncSeparate(int srcRGB, int dstRGB, int srcAlpha, int dstAlpha) { 69 void blendFuncSeparate(int srcRGB, int dstRGB, int srcAlpha, int dstAlpha) {
70 _ptr.blendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha); 70 _ptr.blendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha);
71 return; 71 return;
72 } 72 }
73 73
74 void bufferData(int target, var data_OR_size, int usage) { 74 void bufferData(int target, var data_OR_size, int usage) {
75 if (data_OR_size is ArrayBuffer) { 75 if (data_OR_size is ArrayBuffer) {
76 _ptr.bufferData(target, LevelDom.unwrap(data_OR_size), usage); 76 _ptr.bufferData(target, LevelDom.unwrapMaybePrimitive(data_OR_size), usage );
77 return; 77 return;
78 } else { 78 } else {
79 if (data_OR_size is ArrayBufferView) { 79 if (data_OR_size is ArrayBufferView) {
80 _ptr.bufferData(target, LevelDom.unwrap(data_OR_size), usage); 80 _ptr.bufferData(target, LevelDom.unwrapMaybePrimitive(data_OR_size), usa ge);
81 return; 81 return;
82 } else { 82 } else {
83 if (data_OR_size is int) { 83 if (data_OR_size is int) {
84 _ptr.bufferData(target, LevelDom.unwrap(data_OR_size), usage); 84 _ptr.bufferData(target, LevelDom.unwrapMaybePrimitive(data_OR_size), u sage);
85 return; 85 return;
86 } 86 }
87 } 87 }
88 } 88 }
89 throw "Incorrect number or type of arguments"; 89 throw "Incorrect number or type of arguments";
90 } 90 }
91 91
92 void bufferSubData(int target, int offset, var data) { 92 void bufferSubData(int target, int offset, var data) {
93 if (data is ArrayBuffer) { 93 if (data is ArrayBuffer) {
94 _ptr.bufferSubData(target, offset, LevelDom.unwrap(data)); 94 _ptr.bufferSubData(target, offset, LevelDom.unwrapMaybePrimitive(data));
95 return; 95 return;
96 } else { 96 } else {
97 if (data is ArrayBufferView) { 97 if (data is ArrayBufferView) {
98 _ptr.bufferSubData(target, offset, LevelDom.unwrap(data)); 98 _ptr.bufferSubData(target, offset, LevelDom.unwrapMaybePrimitive(data));
99 return; 99 return;
100 } 100 }
101 } 101 }
102 throw "Incorrect number or type of arguments"; 102 throw "Incorrect number or type of arguments";
103 } 103 }
104 104
105 int checkFramebufferStatus(int target) { 105 int checkFramebufferStatus(int target) {
106 return _ptr.checkFramebufferStatus(target); 106 return _ptr.checkFramebufferStatus(target);
107 } 107 }
108 108
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
295 295
296 void getAttachedShaders(WebGLProgram program) { 296 void getAttachedShaders(WebGLProgram program) {
297 _ptr.getAttachedShaders(LevelDom.unwrap(program)); 297 _ptr.getAttachedShaders(LevelDom.unwrap(program));
298 return; 298 return;
299 } 299 }
300 300
301 int getAttribLocation(WebGLProgram program, String name) { 301 int getAttribLocation(WebGLProgram program, String name) {
302 return _ptr.getAttribLocation(LevelDom.unwrap(program), name); 302 return _ptr.getAttribLocation(LevelDom.unwrap(program), name);
303 } 303 }
304 304
305 void getBufferParameter() { 305 Object getBufferParameter(int target, int pname) {
306 _ptr.getBufferParameter(); 306 return LevelDom.wrapObject(_ptr.getBufferParameter(target, pname));
307 return;
308 } 307 }
309 308
310 WebGLContextAttributes getContextAttributes() { 309 WebGLContextAttributes getContextAttributes() {
311 return LevelDom.wrapWebGLContextAttributes(_ptr.getContextAttributes()); 310 return LevelDom.wrapWebGLContextAttributes(_ptr.getContextAttributes());
312 } 311 }
313 312
314 int getError() { 313 int getError() {
315 return _ptr.getError(); 314 return _ptr.getError();
316 } 315 }
317 316
318 void getExtension(String name) { 317 Object getExtension(String name) {
319 _ptr.getExtension(name); 318 return LevelDom.wrapObject(_ptr.getExtension(name));
320 return;
321 } 319 }
322 320
323 void getFramebufferAttachmentParameter() { 321 Object getFramebufferAttachmentParameter(int target, int attachment, int pname ) {
324 _ptr.getFramebufferAttachmentParameter(); 322 return LevelDom.wrapObject(_ptr.getFramebufferAttachmentParameter(target, at tachment, pname));
325 return;
326 } 323 }
327 324
328 void getParameter() { 325 Object getParameter(int pname) {
329 _ptr.getParameter(); 326 return LevelDom.wrapObject(_ptr.getParameter(pname));
330 return;
331 } 327 }
332 328
333 String getProgramInfoLog(WebGLProgram program) { 329 String getProgramInfoLog(WebGLProgram program) {
334 return _ptr.getProgramInfoLog(LevelDom.unwrap(program)); 330 return _ptr.getProgramInfoLog(LevelDom.unwrap(program));
335 } 331 }
336 332
337 void getProgramParameter() { 333 Object getProgramParameter(WebGLProgram program, int pname) {
338 _ptr.getProgramParameter(); 334 return LevelDom.wrapObject(_ptr.getProgramParameter(LevelDom.unwrap(program) , pname));
339 return;
340 } 335 }
341 336
342 void getRenderbufferParameter() { 337 Object getRenderbufferParameter(int target, int pname) {
343 _ptr.getRenderbufferParameter(); 338 return LevelDom.wrapObject(_ptr.getRenderbufferParameter(target, pname));
344 return;
345 } 339 }
346 340
347 String getShaderInfoLog(WebGLShader shader) { 341 String getShaderInfoLog(WebGLShader shader) {
348 return _ptr.getShaderInfoLog(LevelDom.unwrap(shader)); 342 return _ptr.getShaderInfoLog(LevelDom.unwrap(shader));
349 } 343 }
350 344
351 void getShaderParameter() { 345 Object getShaderParameter(WebGLShader shader, int pname) {
352 _ptr.getShaderParameter(); 346 return LevelDom.wrapObject(_ptr.getShaderParameter(LevelDom.unwrap(shader), pname));
353 return;
354 } 347 }
355 348
356 String getShaderSource(WebGLShader shader) { 349 String getShaderSource(WebGLShader shader) {
357 return _ptr.getShaderSource(LevelDom.unwrap(shader)); 350 return _ptr.getShaderSource(LevelDom.unwrap(shader));
358 } 351 }
359 352
360 void getSupportedExtensions() { 353 Object getTexParameter(int target, int pname) {
361 _ptr.getSupportedExtensions(); 354 return LevelDom.wrapObject(_ptr.getTexParameter(target, pname));
362 return;
363 } 355 }
364 356
365 void getTexParameter() { 357 Object getUniform(WebGLProgram program, WebGLUniformLocation location) {
366 _ptr.getTexParameter(); 358 return LevelDom.wrapObject(_ptr.getUniform(LevelDom.unwrap(program), LevelDo m.unwrap(location)));
367 return;
368 }
369
370 void getUniform() {
371 _ptr.getUniform();
372 return;
373 } 359 }
374 360
375 WebGLUniformLocation getUniformLocation(WebGLProgram program, String name) { 361 WebGLUniformLocation getUniformLocation(WebGLProgram program, String name) {
376 return LevelDom.wrapWebGLUniformLocation(_ptr.getUniformLocation(LevelDom.un wrap(program), name)); 362 return LevelDom.wrapWebGLUniformLocation(_ptr.getUniformLocation(LevelDom.un wrap(program), name));
377 } 363 }
378 364
379 void getVertexAttrib() { 365 Object getVertexAttrib(int index, int pname) {
380 _ptr.getVertexAttrib(); 366 return LevelDom.wrapObject(_ptr.getVertexAttrib(index, pname));
381 return;
382 } 367 }
383 368
384 int getVertexAttribOffset(int index, int pname) { 369 int getVertexAttribOffset(int index, int pname) {
385 return _ptr.getVertexAttribOffset(index, pname); 370 return _ptr.getVertexAttribOffset(index, pname);
386 } 371 }
387 372
388 void hint(int target, int mode) { 373 void hint(int target, int mode) {
389 _ptr.hint(target, mode); 374 _ptr.hint(target, mode);
390 return; 375 return;
391 } 376 }
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
495 void stencilOp(int fail, int zfail, int zpass) { 480 void stencilOp(int fail, int zfail, int zpass) {
496 _ptr.stencilOp(fail, zfail, zpass); 481 _ptr.stencilOp(fail, zfail, zpass);
497 return; 482 return;
498 } 483 }
499 484
500 void stencilOpSeparate(int face, int fail, int zfail, int zpass) { 485 void stencilOpSeparate(int face, int fail, int zfail, int zpass) {
501 _ptr.stencilOpSeparate(face, fail, zfail, zpass); 486 _ptr.stencilOpSeparate(face, fail, zfail, zpass);
502 return; 487 return;
503 } 488 }
504 489
505 void texImage2D(int target, int level, int internalformat, int format_OR_width , int height_OR_type, var border_OR_canvas_OR_image_OR_pixels, [int format = nul l, int type = null, ArrayBufferView pixels = null]) { 490 void texImage2D(int target, int level, int internalformat, int format_OR_width , int height_OR_type, var border_OR_canvas_OR_image_OR_pixels, [int format, int type, ArrayBufferView pixels]) {
506 if (border_OR_canvas_OR_image_OR_pixels is ImageData) { 491 if (border_OR_canvas_OR_image_OR_pixels is ImageData) {
507 if (format === null) { 492 if (format === null) {
508 if (type === null) { 493 if (type === null) {
509 if (pixels === null) { 494 if (pixels === null) {
510 _ptr.texImage2D(target, level, internalformat, format_OR_width, heig ht_OR_type, LevelDom.unwrap(border_OR_canvas_OR_image_OR_pixels)); 495 _ptr.texImage2D(target, level, internalformat, format_OR_width, heig ht_OR_type, LevelDom.unwrapMaybePrimitive(border_OR_canvas_OR_image_OR_pixels));
511 return; 496 return;
512 } 497 }
513 } 498 }
514 } 499 }
515 } else { 500 } else {
516 if (border_OR_canvas_OR_image_OR_pixels is ImageElement) { 501 if (border_OR_canvas_OR_image_OR_pixels is ImageElement) {
517 if (format === null) { 502 if (format === null) {
518 if (type === null) { 503 if (type === null) {
519 if (pixels === null) { 504 if (pixels === null) {
520 _ptr.texImage2D(target, level, internalformat, format_OR_width, he ight_OR_type, LevelDom.unwrap(border_OR_canvas_OR_image_OR_pixels)); 505 _ptr.texImage2D(target, level, internalformat, format_OR_width, he ight_OR_type, LevelDom.unwrapMaybePrimitive(border_OR_canvas_OR_image_OR_pixels) );
521 return; 506 return;
522 } 507 }
523 } 508 }
524 } 509 }
525 } else { 510 } else {
526 if (border_OR_canvas_OR_image_OR_pixels is CanvasElement) { 511 if (border_OR_canvas_OR_image_OR_pixels is CanvasElement) {
527 if (format === null) { 512 if (format === null) {
528 if (type === null) { 513 if (type === null) {
529 if (pixels === null) { 514 if (pixels === null) {
530 _ptr.texImage2D(target, level, internalformat, format_OR_width, height_OR_type, LevelDom.unwrap(border_OR_canvas_OR_image_OR_pixels)); 515 _ptr.texImage2D(target, level, internalformat, format_OR_width, height_OR_type, LevelDom.unwrapMaybePrimitive(border_OR_canvas_OR_image_OR_pixel s));
531 return; 516 return;
532 } 517 }
533 } 518 }
534 } 519 }
535 } else { 520 } else {
536 if (border_OR_canvas_OR_image_OR_pixels is int) { 521 if (border_OR_canvas_OR_image_OR_pixels is int) {
537 _ptr.texImage2D(target, level, internalformat, format_OR_width, heig ht_OR_type, LevelDom.unwrap(border_OR_canvas_OR_image_OR_pixels), format, type, LevelDom.unwrap(pixels)); 522 _ptr.texImage2D(target, level, internalformat, format_OR_width, heig ht_OR_type, LevelDom.unwrapMaybePrimitive(border_OR_canvas_OR_image_OR_pixels), format, type, LevelDom.unwrap(pixels));
538 return; 523 return;
539 } 524 }
540 } 525 }
541 } 526 }
542 } 527 }
543 throw "Incorrect number or type of arguments"; 528 throw "Incorrect number or type of arguments";
544 } 529 }
545 530
546 void texParameterf(int target, int pname, num param) { 531 void texParameterf(int target, int pname, num param) {
547 _ptr.texParameterf(target, pname, param); 532 _ptr.texParameterf(target, pname, param);
548 return; 533 return;
549 } 534 }
550 535
551 void texParameteri(int target, int pname, int param) { 536 void texParameteri(int target, int pname, int param) {
552 _ptr.texParameteri(target, pname, param); 537 _ptr.texParameteri(target, pname, param);
553 return; 538 return;
554 } 539 }
555 540
556 void texSubImage2D(int target, int level, int xoffset, int yoffset, int format _OR_width, int height_OR_type, var canvas_OR_format_OR_image_OR_pixels, [int typ e = null, ArrayBufferView pixels = null]) { 541 void texSubImage2D(int target, int level, int xoffset, int yoffset, int format _OR_width, int height_OR_type, var canvas_OR_format_OR_image_OR_pixels, [int typ e, ArrayBufferView pixels]) {
557 if (canvas_OR_format_OR_image_OR_pixels is ImageData) { 542 if (canvas_OR_format_OR_image_OR_pixels is ImageData) {
558 if (type === null) { 543 if (type === null) {
559 if (pixels === null) { 544 if (pixels === null) {
560 _ptr.texSubImage2D(target, level, xoffset, yoffset, format_OR_width, h eight_OR_type, LevelDom.unwrap(canvas_OR_format_OR_image_OR_pixels)); 545 _ptr.texSubImage2D(target, level, xoffset, yoffset, format_OR_width, h eight_OR_type, LevelDom.unwrapMaybePrimitive(canvas_OR_format_OR_image_OR_pixels ));
561 return; 546 return;
562 } 547 }
563 } 548 }
564 } else { 549 } else {
565 if (canvas_OR_format_OR_image_OR_pixels is ImageElement) { 550 if (canvas_OR_format_OR_image_OR_pixels is ImageElement) {
566 if (type === null) { 551 if (type === null) {
567 if (pixels === null) { 552 if (pixels === null) {
568 _ptr.texSubImage2D(target, level, xoffset, yoffset, format_OR_width, height_OR_type, LevelDom.unwrap(canvas_OR_format_OR_image_OR_pixels)); 553 _ptr.texSubImage2D(target, level, xoffset, yoffset, format_OR_width, height_OR_type, LevelDom.unwrapMaybePrimitive(canvas_OR_format_OR_image_OR_pixe ls));
569 return; 554 return;
570 } 555 }
571 } 556 }
572 } else { 557 } else {
573 if (canvas_OR_format_OR_image_OR_pixels is CanvasElement) { 558 if (canvas_OR_format_OR_image_OR_pixels is CanvasElement) {
574 if (type === null) { 559 if (type === null) {
575 if (pixels === null) { 560 if (pixels === null) {
576 _ptr.texSubImage2D(target, level, xoffset, yoffset, format_OR_widt h, height_OR_type, LevelDom.unwrap(canvas_OR_format_OR_image_OR_pixels)); 561 _ptr.texSubImage2D(target, level, xoffset, yoffset, format_OR_widt h, height_OR_type, LevelDom.unwrapMaybePrimitive(canvas_OR_format_OR_image_OR_pi xels));
577 return; 562 return;
578 } 563 }
579 } 564 }
580 } else { 565 } else {
581 if (canvas_OR_format_OR_image_OR_pixels is int) { 566 if (canvas_OR_format_OR_image_OR_pixels is int) {
582 _ptr.texSubImage2D(target, level, xoffset, yoffset, format_OR_width, height_OR_type, LevelDom.unwrap(canvas_OR_format_OR_image_OR_pixels), type, Lev elDom.unwrap(pixels)); 567 _ptr.texSubImage2D(target, level, xoffset, yoffset, format_OR_width, height_OR_type, LevelDom.unwrapMaybePrimitive(canvas_OR_format_OR_image_OR_pixe ls), type, LevelDom.unwrap(pixels));
583 return; 568 return;
584 } 569 }
585 } 570 }
586 } 571 }
587 } 572 }
588 throw "Incorrect number or type of arguments"; 573 throw "Incorrect number or type of arguments";
589 } 574 }
590 575
591 void uniform1f(WebGLUniformLocation location, num x) { 576 void uniform1f(WebGLUniformLocation location, num x) {
592 _ptr.uniform1f(LevelDom.unwrap(location), x); 577 _ptr.uniform1f(LevelDom.unwrap(location), x);
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
736 void vertexAttribPointer(int indx, int size, int type, bool normalized, int st ride, int offset) { 721 void vertexAttribPointer(int indx, int size, int type, bool normalized, int st ride, int offset) {
737 _ptr.vertexAttribPointer(indx, size, type, normalized, stride, offset); 722 _ptr.vertexAttribPointer(indx, size, type, normalized, stride, offset);
738 return; 723 return;
739 } 724 }
740 725
741 void viewport(int x, int y, int width, int height) { 726 void viewport(int x, int y, int width, int height) {
742 _ptr.viewport(x, y, width, height); 727 _ptr.viewport(x, y, width, height);
743 return; 728 return;
744 } 729 }
745 } 730 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698