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

Unified Diff: gpu/ipc/service/stream_texture_android.cc

Issue 2282633002: Integrate Surface requests with MediaPlayerRenderer (Closed)
Patch Set: Addressed last comments Created 4 years, 2 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 | « gpu/ipc/service/stream_texture_android.h ('k') | media/base/android/stream_texture_wrapper.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/ipc/service/stream_texture_android.cc
diff --git a/gpu/ipc/service/stream_texture_android.cc b/gpu/ipc/service/stream_texture_android.cc
index 7d556b4dc81757ab8f3cd8ddbc64f410753a5def..2aa9bc5633b76027b2122d4d13c54369001a493c 100644
--- a/gpu/ipc/service/stream_texture_android.cc
+++ b/gpu/ipc/service/stream_texture_android.cc
@@ -11,6 +11,7 @@
#include "gpu/command_buffer/service/context_state.h"
#include "gpu/command_buffer/service/gles2_cmd_decoder.h"
#include "gpu/command_buffer/service/texture_manager.h"
+#include "gpu/ipc/common/android/scoped_surface_request_conduit.h"
#include "gpu/ipc/common/android/surface_texture_peer.h"
#include "gpu/ipc/common/gpu_messages.h"
#include "gpu/ipc/service/gpu_channel.h"
@@ -199,6 +200,8 @@ bool StreamTexture::OnMessageReceived(const IPC::Message& message) {
bool handled = true;
IPC_BEGIN_MESSAGE_MAP(StreamTexture, message)
IPC_MESSAGE_HANDLER(GpuStreamTextureMsg_StartListening, OnStartListening)
+ IPC_MESSAGE_HANDLER(GpuStreamTextureMsg_ForwardForSurfaceRequest,
+ OnForwardForSurfaceRequest)
IPC_MESSAGE_HANDLER(GpuStreamTextureMsg_EstablishPeer, OnEstablishPeer)
IPC_MESSAGE_HANDLER(GpuStreamTextureMsg_SetSize, OnSetSize)
IPC_MESSAGE_UNHANDLED(handled = false)
@@ -223,6 +226,16 @@ void StreamTexture::OnEstablishPeer(int32_t primary_id, int32_t secondary_id) {
process, surface_texture_, primary_id, secondary_id);
}
+void StreamTexture::OnForwardForSurfaceRequest(
+ const base::UnguessableToken& request_token) {
+ if (!owner_stub_)
+ return;
+
+ ScopedSurfaceRequestConduit::GetInstance()
+ ->ForwardSurfaceTextureForSurfaceRequest(request_token,
+ surface_texture_.get());
+}
+
bool StreamTexture::BindTexImage(unsigned target) {
NOTREACHED();
return false;
« no previous file with comments | « gpu/ipc/service/stream_texture_android.h ('k') | media/base/android/stream_texture_wrapper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698