Request keyframes more frequently on stream start/decoding error.

In this CL:
 - Added FrameObject::is_keyframe() convinience function.
 - Moved logic to request keyframes on decoding error from VideoReceived to
   VideoReceiveStream.
 - Added keyframe_required as a parameter to FrameBuffer::NextFrame.

BUG=webrtc:8074

Review-Url: https://codereview.webrtc.org/2993793002
Cr-Commit-Position: refs/heads/master@{#19280}
This commit is contained in:
philipel
2017-08-09 03:33:59 -07:00
committed by Commit Bot
parent 445f1a1535
commit 26b4804358
7 changed files with 43 additions and 27 deletions

View File

@ -44,6 +44,8 @@ class FrameObject : public webrtc::VCMEncodedFrame {
size_t size() const { return _length; }
bool is_keyframe() const { return num_references == 0; }
// The tuple (|picture_id|, |spatial_layer|) uniquely identifies a frame
// object. For codec types that don't necessarily have picture ids they
// have to be constructed from the header data relevant to that codec.