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

Unified Diff: cc/gl_renderer.cc

Issue 11442056: Add external surface rendering mode (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add getPersonality() Created 8 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 side-by-side diff with in-line comments
Download patch
Index: cc/gl_renderer.cc
diff --git a/cc/gl_renderer.cc b/cc/gl_renderer.cc
index a40dd3a245b80e384bea0d7cce273d2d441ff6ba..8a4d7061094bdc274a1344e5e1dbd8e2f6cf59d4 100644
--- a/cc/gl_renderer.cc
+++ b/cc/gl_renderer.cc
@@ -936,6 +936,13 @@ void GLRenderer::drawStreamVideoQuad(const DrawingFrame& frame, const StreamVide
const VideoStreamTextureProgram* program = videoStreamTextureProgram();
setUseProgram(program->program());
+ if (quad->texture_id == 0) {
+ // When texture_id == 0, punch a hole instead of rendering.
qinmin 2012/12/17 19:34:06 nit: fix indent
enne (OOO) 2012/12/17 20:38:28 What do you mean by punch a hole? Maybe I'm misund
wonsik2 2013/02/14 14:56:38 It seems that 4 spaces are used throughout the fil
wonsik2 2013/02/14 14:56:38 Skipping a quad will make the background occlude t
+ GLC(m_context, m_context->blendFunc(GL_ZERO, GL_ONE_MINUS_SRC_ALPHA));
+ drawQuadGeometry(frame, quad->quadTransform(), quad->rect, program->vertexShader().matrixLocation());
+ GLC(m_context, m_context->blendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA));
+ return;
+ }
toGLMatrix(&glMatrix[0], quad->matrix);
GLC(context(), context()->uniformMatrix4fv(program->vertexShader().texMatrixLocation(), 1, false, glMatrix));
« no previous file with comments | « no previous file | content/browser/android/content_video_view.h » ('j') | content/browser/android/content_video_view.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698