Use sps and pps to determine decodability of H.264 frames.
NOPRESUBMIT=true BUG=webrtc:6208 R=philipel@webrtc.org Review URL: https://codereview.webrtc.org/2341713002 . Cr-Commit-Position: refs/heads/master@{#14458}
This commit is contained in:
@ -11,11 +11,16 @@
|
||||
#ifndef WEBRTC_MODULES_VIDEO_CODING_DECODING_STATE_H_
|
||||
#define WEBRTC_MODULES_VIDEO_CODING_DECODING_STATE_H_
|
||||
|
||||
#include <map>
|
||||
#include <set>
|
||||
#include <vector>
|
||||
|
||||
#include "webrtc/typedefs.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
||||
// Forward declarations
|
||||
struct NaluInfo;
|
||||
class VCMFrameBuffer;
|
||||
class VCMPacket;
|
||||
|
||||
@ -61,6 +66,7 @@ class VCMDecodingState {
|
||||
bool UsingPictureId(const VCMFrameBuffer* frame) const;
|
||||
bool UsingFlexibleMode(const VCMFrameBuffer* frame) const;
|
||||
bool AheadOfFramesDecodedClearedTo(uint16_t index) const;
|
||||
bool HaveSpsAndPps(const std::vector<NaluInfo>& nalus) const;
|
||||
|
||||
// Keep state of last decoded frame.
|
||||
// TODO(mikhal/stefan): create designated classes to handle these types.
|
||||
@ -75,6 +81,8 @@ class VCMDecodingState {
|
||||
// Used to check references in flexible mode.
|
||||
bool frame_decoded_[kFrameDecodedLength];
|
||||
uint16_t frame_decoded_cleared_to_;
|
||||
std::set<int> received_sps_;
|
||||
std::map<int, int> received_pps_;
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
||||
Reference in New Issue
Block a user