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

Unified Diff: sdk/lib/web_gl/dart2js/web_gl_dart2js.dart

Issue 2975953002: Fixed readPixels not working in Dartium. (Closed)
Patch Set: Updated to latest WebKit (exposed Dart_TypedArray_ArrayBufferView). Created 3 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sdk/lib/js/dartium/js_dartium.dart ('k') | sdk/lib/web_gl/dartium/web_gl_dartium.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/web_gl/dart2js/web_gl_dart2js.dart
diff --git a/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart b/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart
index cf8a7239e9611b3837c3b0add77c8bce3d7e92ec..87f958e064420abd4ba50d7bb481e9ae47aae64f 100644
--- a/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart
+++ b/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart
@@ -3068,9 +3068,10 @@ class RenderingContext extends Interceptor implements CanvasRenderingContext {
@DocsEditable()
void polygonOffset(num factor, num units) native;
+ @JSName('readPixels')
@DomName('WebGLRenderingContext.readPixels')
@DocsEditable()
- void readPixels(int x, int y, int width, int height, int format, int type,
+ void _readPixels(int x, int y, int width, int height, int format, int type,
TypedData pixels) native;
@DomName('WebGLRenderingContext.renderbufferStorage')
@@ -3501,6 +3502,13 @@ class RenderingContext extends Interceptor implements CanvasRenderingContext {
@DocsEditable()
void viewport(int x, int y, int width, int height) native;
+ @DomName('WebGLRenderingContext.readPixels')
+ @DocsEditable()
+ void readPixels(int x, int y, int width, int height, int format, int type,
+ TypedData pixels) {
+ _readPixels(x, y, width, height, format, type, pixels);
+ }
+
/**
* Sets the currently bound texture to [data].
*
@@ -3577,7 +3585,7 @@ class RenderingContext extends Interceptor implements CanvasRenderingContext {
bufferSubData(target, offset, data);
}
}
-// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
+// Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
@@ -6227,10 +6235,11 @@ class RenderingContext2 extends Interceptor
@Experimental() // untriaged
void polygonOffset(num factor, num units) native;
+ @JSName('readPixels')
@DomName('WebGL2RenderingContext.readPixels')
@DocsEditable()
@Experimental() // untriaged
- void readPixels(int x, int y, int width, int height, int format, int type,
+ void _readPixels(int x, int y, int width, int height, int format, int type,
TypedData pixels) native;
@DomName('WebGL2RenderingContext.renderbufferStorage')
@@ -6717,7 +6726,15 @@ class RenderingContext2 extends Interceptor
@DocsEditable()
@Experimental() // untriaged
void viewport(int x, int y, int width, int height) native;
+
+ @DomName('WebGLRenderingContext2.readPixels')
+ @DocsEditable()
+ void readPixels(int x, int y, int width, int height, int format, int type,
+ TypedData pixels) {
+ _readPixels(x, y, width, height, format, type, pixels);
+ }
}
+
// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
« no previous file with comments | « sdk/lib/js/dartium/js_dartium.dart ('k') | sdk/lib/web_gl/dartium/web_gl_dartium.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698