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

Unified Diff: chrome/renderer/media/cast_session_delegate.cc

Issue 207593002: Cast: Enable use of VideoEncodeAccelerator for hardware video encoding (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: typedef 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/renderer/media/cast_rtp_stream.cc ('k') | media/cast/cast.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/media/cast_session_delegate.cc
diff --git a/chrome/renderer/media/cast_session_delegate.cc b/chrome/renderer/media/cast_session_delegate.cc
index 093615d0ea10298e8c6f5ae8202daa9d4f2f1960..917ee90b2f47dbd389727a7e0881961bda54d233 100644
--- a/chrome/renderer/media/cast_session_delegate.cc
+++ b/chrome/renderer/media/cast_session_delegate.cc
@@ -38,6 +38,20 @@ const int kMaxVideoEventEntries = kMaxSerializedBytes / 150;
// Assume serialized log data for each frame will take up to 75 bytes.
const int kMaxAudioEventEntries = kMaxSerializedBytes / 75;
+void CreateVideoEncodeAccelerator(const base::Callback<
+ void(scoped_refptr<base::SingleThreadTaskRunner>,
+ scoped_ptr<media::VideoEncodeAccelerator>)>& callback) {
+ NOTIMPLEMENTED();
+ // Delegate the call to content API on the render thread.
+}
+
+void CreateVideoEncodeMemory(
+ size_t size,
+ const base::Callback<void(scoped_ptr<base::SharedMemory>)>&) {
+ NOTIMPLEMENTED();
+ // Delegate the call to content API on the render thread.
+}
+
} // namespace
CastSessionDelegate::CastSessionDelegate()
@@ -103,13 +117,12 @@ void CastSessionDelegate::StartVideo(
transport_config.codec = config.codec;
transport_config.base.rtp_config = config.rtp_config;
cast_transport_->InitializeVideo(transport_config);
- // TODO(mikhal): Pass in a valid GpuVideoAcceleratorFactories to support
- // hardware video encoding.
cast_sender_->InitializeVideo(
config,
base::Bind(&CastSessionDelegate::InitializationResultCB,
weak_factory_.GetWeakPtr()),
- NULL /* GPU*/);
+ base::Bind(&CreateVideoEncodeAccelerator),
+ base::Bind(&CreateVideoEncodeMemory));
}
void CastSessionDelegate::StartUDP(const net::IPEndPoint& remote_endpoint) {
« no previous file with comments | « chrome/renderer/media/cast_rtp_stream.cc ('k') | media/cast/cast.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698