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

Unified Diff: media/cast/audio_receiver/audio_receiver.h

Issue 225023010: [Cast] Refactor/clean-up VideoReceiver to match AudioReceiver as closely as possible. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 8 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 | « no previous file | media/cast/audio_receiver/audio_receiver.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/cast/audio_receiver/audio_receiver.h
diff --git a/media/cast/audio_receiver/audio_receiver.h b/media/cast/audio_receiver/audio_receiver.h
index feed5e98ca70074b1d2e8dc21ad12956027874de..8056095d026e655acfa29c8bf2bd6e10f3f1a9b2 100644
--- a/media/cast/audio_receiver/audio_receiver.h
+++ b/media/cast/audio_receiver/audio_receiver.h
@@ -31,8 +31,18 @@ class AudioDecoder;
// AudioReceiver receives packets out-of-order while clients make requests for
// complete frames in-order. (A frame consists of one or more packets.)
-// AudioReceiver also includes logic for mapping RTP timestamps to the local
-// base::TimeTicks clock for each frame.
+//
+// AudioReceiver also includes logic for computing the playout time for each
+// frame, accounting for a constant targeted playout delay. The purpose of the
+// playout delay is to provide a fixed window of time between the capture event
+// on the sender and the playout on the receiver. This is important because
+// each step of the pipeline (i.e., encode frame, then transmit/retransmit from
+// the sender, then receive and re-order packets on the receiver, then decode
+// frame) can vary in duration and is typically very hard to predict.
+// Heuristics will determine when the targeted playout delay is insufficient in
+// the current environment; and the receiver can then increase the playout
+// delay, notifying the sender, to account for the extra variance.
+// TODO(miu): Make the last sentence true. http://crbug.com/360111
//
// Two types of frames can be requested: 1) A frame of decoded audio data; or 2)
// a frame of still-encoded audio data, to be passed into an external audio
@@ -63,7 +73,7 @@ class AudioReceiver : public RtpReceiver,
// even if to respond with NULL at shutdown time.
void GetRawAudioFrame(const AudioFrameDecodedCallback& callback);
- // Extract an encoded audio frame from the cast receiver.
+ // Request an encoded audio frame.
//
// The given |callback| is guaranteed to be run at some point in the future,
// even if to respond with NULL at shutdown time.
« no previous file with comments | « no previous file | media/cast/audio_receiver/audio_receiver.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698