OLD | NEW |
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 518 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
529 web_graphics_context->pixelStorei(GL_UNPACK_FLIP_Y_CHROMIUM, false); | 529 web_graphics_context->pixelStorei(GL_UNPACK_FLIP_Y_CHROMIUM, false); |
530 web_graphics_context->pixelStorei(GL_UNPACK_PREMULTIPLY_ALPHA_CHROMIUM, | 530 web_graphics_context->pixelStorei(GL_UNPACK_PREMULTIPLY_ALPHA_CHROMIUM, |
531 false); | 531 false); |
532 | 532 |
533 if (mailbox_holder->texture_target == GL_TEXTURE_EXTERNAL_OES) | 533 if (mailbox_holder->texture_target == GL_TEXTURE_EXTERNAL_OES) |
534 web_graphics_context->bindTexture(GL_TEXTURE_EXTERNAL_OES, 0); | 534 web_graphics_context->bindTexture(GL_TEXTURE_EXTERNAL_OES, 0); |
535 else | 535 else |
536 web_graphics_context->bindTexture(GL_TEXTURE_2D, texture); | 536 web_graphics_context->bindTexture(GL_TEXTURE_2D, texture); |
537 web_graphics_context->deleteTexture(source_texture); | 537 web_graphics_context->deleteTexture(source_texture); |
538 web_graphics_context->flush(); | 538 web_graphics_context->flush(); |
539 video_frame->AppendReleaseSyncPoint(web_graphics_context->insertSyncPoint()); | 539 |
| 540 std::ostringstream convert; |
| 541 convert << "blink_" << web_graphics_context; |
| 542 video_frame->AppendReleaseSyncPoint(convert.str(), |
| 543 web_graphics_context->insertSyncPoint()); |
540 return true; | 544 return true; |
541 } | 545 } |
542 | 546 |
543 bool WebMediaPlayerAndroid::hasSingleSecurityOrigin() const { | 547 bool WebMediaPlayerAndroid::hasSingleSecurityOrigin() const { |
544 if (info_loader_) | 548 if (info_loader_) |
545 return info_loader_->HasSingleOrigin(); | 549 return info_loader_->HasSingleOrigin(); |
546 // The info loader may have failed. | 550 // The info loader may have failed. |
547 if (player_type_ == MEDIA_PLAYER_TYPE_URL) | 551 if (player_type_ == MEDIA_PLAYER_TYPE_URL) |
548 return false; | 552 return false; |
549 return true; | 553 return true; |
(...skipping 1015 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1565 | 1569 |
1566 void WebMediaPlayerAndroid::exitFullscreen() { | 1570 void WebMediaPlayerAndroid::exitFullscreen() { |
1567 player_manager_->ExitFullscreen(player_id_); | 1571 player_manager_->ExitFullscreen(player_id_); |
1568 } | 1572 } |
1569 | 1573 |
1570 bool WebMediaPlayerAndroid::canEnterFullscreen() const { | 1574 bool WebMediaPlayerAndroid::canEnterFullscreen() const { |
1571 return player_manager_->CanEnterFullscreen(frame_); | 1575 return player_manager_->CanEnterFullscreen(frame_); |
1572 } | 1576 } |
1573 | 1577 |
1574 } // namespace content | 1578 } // namespace content |
OLD | NEW |