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

Side by Side Diff: content/renderer/media/android/stream_texture_factory.h

Issue 1417853006: gpu: introduce glSetStreamTextureSizeCHROMIUM(GLuint texture, GLint stream_id, GLsizei width, GLsiz… Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix android_webview.test failure Created 5 years, 1 month 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef CONTENT_RENDERER_MEDIA_ANDROID_STREAM_TEXTURE_FACTORY_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_ANDROID_STREAM_TEXTURE_FACTORY_H_
6 #define CONTENT_RENDERER_MEDIA_ANDROID_STREAM_TEXTURE_FACTORY_H_ 6 #define CONTENT_RENDERER_MEDIA_ANDROID_STREAM_TEXTURE_FACTORY_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/single_thread_task_runner.h" 10 #include "base/single_thread_task_runner.h"
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 58
59 // Send an IPC message to the browser process to request a java surface 59 // Send an IPC message to the browser process to request a java surface
60 // object for the given stream_id. After the the surface is created, 60 // object for the given stream_id. After the the surface is created,
61 // it will be passed back to the WebMediaPlayerAndroid object identified by 61 // it will be passed back to the WebMediaPlayerAndroid object identified by
62 // the player_id. 62 // the player_id.
63 virtual void EstablishPeer(int32 stream_id, int player_id) = 0; 63 virtual void EstablishPeer(int32 stream_id, int player_id) = 0;
64 64
65 // Creates a StreamTexture and returns its id. Sets |*texture_id| to the 65 // Creates a StreamTexture and returns its id. Sets |*texture_id| to the
66 // client-side id of the StreamTexture. The texture is produced into 66 // client-side id of the StreamTexture. The texture is produced into
67 // a mailbox so it can be shipped in a VideoFrame. 67 // a mailbox so it can be shipped in a VideoFrame.
68 virtual unsigned CreateStreamTexture(unsigned texture_target, 68 virtual int32 CreateStreamTexture(unsigned texture_target,
69 unsigned* texture_id, 69 unsigned* texture_id,
70 gpu::Mailbox* texture_mailbox) = 0; 70 gpu::Mailbox* texture_mailbox) = 0;
71
72 // Set the streamTexture size for the given stream Id.
73 virtual void SetStreamTextureSize(int32 texture_id,
74 const gfx::Size& size) = 0;
75 71
76 virtual gpu::gles2::GLES2Interface* ContextGL() = 0; 72 virtual gpu::gles2::GLES2Interface* ContextGL() = 0;
77 73
78 virtual void AddObserver(StreamTextureFactoryContextObserver* obs) = 0; 74 virtual void AddObserver(StreamTextureFactoryContextObserver* obs) = 0;
79 virtual void RemoveObserver(StreamTextureFactoryContextObserver* obs) = 0; 75 virtual void RemoveObserver(StreamTextureFactoryContextObserver* obs) = 0;
80 76
81 protected: 77 protected:
82 friend class base::RefCounted<StreamTextureFactory>; 78 friend class base::RefCounted<StreamTextureFactory>;
83 virtual ~StreamTextureFactory() {} 79 virtual ~StreamTextureFactory() {}
84 }; 80 };
85 81
86 } // namespace content 82 } // namespace content
87 83
88 #endif // CONTENT_RENDERER_MEDIA_ANDROID_STREAM_TEXTURE_FACTORY_H_ 84 #endif // CONTENT_RENDERER_MEDIA_ANDROID_STREAM_TEXTURE_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698