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

Unified Diff: remoting/client/plugin/chromoting_instance.cc

Issue 329663002: Fix MediaSource renderer to limit memory consumption. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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 | « remoting/client/plugin/chromoting_instance.h ('k') | remoting/client/plugin/media_source_video_renderer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/client/plugin/chromoting_instance.cc
diff --git a/remoting/client/plugin/chromoting_instance.cc b/remoting/client/plugin/chromoting_instance.cc
index 2790229b963b02d9799dd81c1a439db4dcf335be..b655546ff849df985c508d372132497ebdf66ba6 100644
--- a/remoting/client/plugin/chromoting_instance.cc
+++ b/remoting/client/plugin/chromoting_instance.cc
@@ -1196,14 +1196,15 @@ void ChromotingInstance::OnMediaSourceReset(const std::string& format) {
PostLegacyJsonMessage("mediaSourceReset", data.Pass());
}
-void ChromotingInstance::OnMediaSourceData(uint8_t* buffer,
- size_t buffer_size) {
+void ChromotingInstance::OnMediaSourceData(uint8_t* buffer, size_t buffer_size,
+ bool keyframe) {
pp::VarArrayBuffer array_buffer(buffer_size);
void* data_ptr = array_buffer.Map();
memcpy(data_ptr, buffer, buffer_size);
array_buffer.Unmap();
pp::VarDictionary data_dictionary;
data_dictionary.Set(pp::Var("buffer"), array_buffer);
+ data_dictionary.Set(pp::Var("keyframe"), keyframe);
PostChromotingMessage("mediaSourceData", data_dictionary);
}
« no previous file with comments | « remoting/client/plugin/chromoting_instance.h ('k') | remoting/client/plugin/media_source_video_renderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698