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

Side by Side Diff: content/renderer/media/android/webmediaplayer_android.cc

Issue 200763011: Add explicit flush after copyTextureCHROMIUM to make the change visible accross contexts. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove the unnecessary flush() Created 6 years, 9 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 unified diff | Download patch
« no previous file with comments | « no previous file | content/renderer/media/webmediaplayer_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/media/android/webmediaplayer_android.h" 5 #include "content/renderer/media/android/webmediaplayer_android.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback_helpers.h" 10 #include "base/callback_helpers.h"
(...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after
465 web_graphics_context->pixelStorei(GL_UNPACK_FLIP_Y_CHROMIUM, flip_y); 465 web_graphics_context->pixelStorei(GL_UNPACK_FLIP_Y_CHROMIUM, flip_y);
466 web_graphics_context->copyTextureCHROMIUM(GL_TEXTURE_2D, source_texture, 466 web_graphics_context->copyTextureCHROMIUM(GL_TEXTURE_2D, source_texture,
467 texture, level, internal_format, 467 texture, level, internal_format,
468 type); 468 type);
469 web_graphics_context->pixelStorei(GL_UNPACK_FLIP_Y_CHROMIUM, false); 469 web_graphics_context->pixelStorei(GL_UNPACK_FLIP_Y_CHROMIUM, false);
470 web_graphics_context->pixelStorei(GL_UNPACK_PREMULTIPLY_ALPHA_CHROMIUM, 470 web_graphics_context->pixelStorei(GL_UNPACK_PREMULTIPLY_ALPHA_CHROMIUM,
471 false); 471 false);
472 472
473 web_graphics_context->bindTexture(GL_TEXTURE_EXTERNAL_OES, 0); 473 web_graphics_context->bindTexture(GL_TEXTURE_EXTERNAL_OES, 0);
474 web_graphics_context->deleteTexture(source_texture); 474 web_graphics_context->deleteTexture(source_texture);
475 web_graphics_context->flush();
475 return true; 476 return true;
476 } 477 }
477 478
478 bool WebMediaPlayerAndroid::hasSingleSecurityOrigin() const { 479 bool WebMediaPlayerAndroid::hasSingleSecurityOrigin() const {
479 if (info_loader_) 480 if (info_loader_)
480 return info_loader_->HasSingleOrigin(); 481 return info_loader_->HasSingleOrigin();
481 // The info loader may have failed. 482 // The info loader may have failed.
482 if (player_type_ == MEDIA_PLAYER_TYPE_URL) 483 if (player_type_ == MEDIA_PLAYER_TYPE_URL)
483 return false; 484 return false;
484 return true; 485 return true;
(...skipping 954 matching lines...) Expand 10 before | Expand all | Expand 10 after
1439 1440
1440 void WebMediaPlayerAndroid::exitFullscreen() { 1441 void WebMediaPlayerAndroid::exitFullscreen() {
1441 manager_->ExitFullscreen(player_id_); 1442 manager_->ExitFullscreen(player_id_);
1442 } 1443 }
1443 1444
1444 bool WebMediaPlayerAndroid::canEnterFullscreen() const { 1445 bool WebMediaPlayerAndroid::canEnterFullscreen() const {
1445 return manager_->CanEnterFullscreen(frame_); 1446 return manager_->CanEnterFullscreen(frame_);
1446 } 1447 }
1447 1448
1448 } // namespace content 1449 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/renderer/media/webmediaplayer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698