Save unwrapped tl0_pic_idx for inserted VP8 frames.
As stashed frames are retried their `tl0_pic_idx` are again unwrapped which can lead to the `tl0_unwrapper_` to unwrap the `tl0_pic_idx` of newer frames backwards. Instead unwrap the `tl0_pid_idx` only once and save it with the frame if necessary. Related VP9 CL: https://webrtc-review.googlesource.com/c/src/+/253844 Bug: none Change-Id: I8265dc5f36ee257db92d79cec719f56b165d3855 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/256966 Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> Commit-Queue: Philip Eliasson <philipel@webrtc.org> Cr-Commit-Position: refs/heads/main@{#36356}
This commit is contained in:
@ -38,9 +38,16 @@ class RtpVp8RefFinder {
|
||||
static constexpr int kMaxStashedFrames = 100;
|
||||
static constexpr int kMaxTemporalLayers = 5;
|
||||
|
||||
struct UnwrappedTl0Frame {
|
||||
int64_t unwrapped_tl0;
|
||||
std::unique_ptr<RtpFrameObject> frame;
|
||||
};
|
||||
|
||||
enum FrameDecision { kStash, kHandOff, kDrop };
|
||||
|
||||
FrameDecision ManageFrameInternal(RtpFrameObject* frame);
|
||||
FrameDecision ManageFrameInternal(RtpFrameObject* frame,
|
||||
const RTPVideoHeaderVP8& codec_header,
|
||||
int64_t unwrapped_tl0);
|
||||
void RetryStashedFrames(RtpFrameReferenceFinder::ReturnVector& res);
|
||||
void UpdateLayerInfoVp8(RtpFrameObject* frame,
|
||||
int64_t unwrapped_tl0,
|
||||
@ -58,7 +65,7 @@ class RtpVp8RefFinder {
|
||||
|
||||
// Frames that have been fully received but didn't have all the information
|
||||
// needed to determine their references.
|
||||
std::deque<std::unique_ptr<RtpFrameObject>> stashed_frames_;
|
||||
std::deque<UnwrappedTl0Frame> stashed_frames_;
|
||||
|
||||
// Holds the information about the last completed frame for a given temporal
|
||||
// layer given an unwrapped Tl0 picture index.
|
||||
|
||||
Reference in New Issue
Block a user