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

Unified Diff: media/cast/sender/frame_sender.h

Issue 493823002: Implement adaptive target delay extension (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: explicit masking Created 6 years, 4 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 | « media/cast/sender/audio_sender.cc ('k') | media/cast/sender/frame_sender.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/cast/sender/frame_sender.h
diff --git a/media/cast/sender/frame_sender.h b/media/cast/sender/frame_sender.h
index b0eb561156b0db4a65e4b0c06d64d6d0b2d3b905..5da3927961f7262aca2774ffd60254610c4b17b6 100644
--- a/media/cast/sender/frame_sender.h
+++ b/media/cast/sender/frame_sender.h
@@ -26,9 +26,19 @@ class FrameSender {
CastTransportSender* const transport_sender,
base::TimeDelta rtcp_interval,
int frequency,
- uint32 ssrc);
+ uint32 ssrc,
+ double max_frame_rate,
+ base::TimeDelta playout_delay);
virtual ~FrameSender();
+ // Calling this function is only valid if the receiver supports the
+ // "extra_playout_delay", rtp extension.
+ void SetTargetPlayoutDelay(base::TimeDelta new_target_playout_delay);
+
+ base::TimeDelta GetTargetPlayoutDelay() const {
+ return target_playout_delay_;
+ }
+
protected:
// Schedule and execute periodic sending of RTCP report.
void ScheduleNextRtcpReport();
@@ -63,9 +73,28 @@ class FrameSender {
base::TimeDelta min_rtt_;
base::TimeDelta max_rtt_;
- private:
+ protected:
const base::TimeDelta rtcp_interval_;
+ // The total amount of time between a frame's capture/recording on the sender
+ // and its playback on the receiver (i.e., shown to a user). This is fixed as
+ // a value large enough to give the system sufficient time to encode,
+ // transmit/retransmit, receive, decode, and render; given its run-time
+ // environment (sender/receiver hardware performance, network conditions,
+ // etc.).
+ base::TimeDelta target_playout_delay_;
+
+ // If true, we transmit the target playout delay to the receiver.
+ bool send_target_playout_delay_;
+
+ // Max encoded frames generated per second.
+ double max_frame_rate_;
+
+ // Maximum number of outstanding frames before the encoding and sending of
+ // new frames shall halt.
+ int max_unacked_frames_;
+
+ private:
// NOTE: Weak pointers must be invalidated before all other member variables.
base::WeakPtrFactory<FrameSender> weak_factory_;
« no previous file with comments | « media/cast/sender/audio_sender.cc ('k') | media/cast/sender/frame_sender.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698