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

Unified Diff: sdk/lib/web_gl/dartium/web_gl_dartium.dart

Issue 22458005: Fix texImage2D on Dartium. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 4 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 | « no previous file | tools/dom/templates/html/impl/impl_WebGLRenderingContext.darttemplate » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/web_gl/dartium/web_gl_dartium.dart
diff --git a/sdk/lib/web_gl/dartium/web_gl_dartium.dart b/sdk/lib/web_gl/dartium/web_gl_dartium.dart
index 411dd69337e8ea46249eb2f3cdab4a2c631ce7e2..83879618b1ad18ca244b231d9cbd3dd5d561609b 100644
--- a/sdk/lib/web_gl/dartium/web_gl_dartium.dart
+++ b/sdk/lib/web_gl/dartium/web_gl_dartium.dart
@@ -2793,8 +2793,19 @@ class RenderingContext extends CanvasRenderingContext {
@DomName('WebGLRenderingContext.texImage2D')
void texImage2D(int targetTexture, int levelOfDetail, int internalFormat,
int format, int type, data) {
- _texImage2D(targetTexture, levelOfDetail, internalFormat,
- format, type, data);
+ if (data is ImageElement) {
+ texImage2DImage(targetTexture, levelOfDetail, internalFormat, format,
+ type, data);
+ } else if (data is ImageData) {
+ texImage2DImageData(targetTexture, levelOfDetail, internalFormat, format,
+ type, data);
+ } else if (data is CanvasElement) {
+ texImage2DCanvas(targetTexture, levelOfDetail, internalFormat, format,
+ type, data);
+ } else {
+ texImage2DVideo(targetTexture, levelOfDetail, internalFormat, format,
+ type, data);
+ }
}
/**
« no previous file with comments | « no previous file | tools/dom/templates/html/impl/impl_WebGLRenderingContext.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698