Fix some chromium-style warnings in webrtc/modules/video_coding/
BUG=163 R=mikhal@webrtc.org Review URL: https://webrtc-codereview.appspot.com/1901005 git-svn-id: http://webrtc.googlecode.com/svn/trunk@4429 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
@ -92,7 +92,7 @@ class PacketManipulatorImpl : public PacketManipulator {
|
||||
const NetworkingConfig& config,
|
||||
bool verbose);
|
||||
virtual ~PacketManipulatorImpl();
|
||||
virtual int ManipulatePackets(webrtc::EncodedImage* encoded_image);
|
||||
virtual int ManipulatePackets(webrtc::EncodedImage* encoded_image) OVERRIDE;
|
||||
virtual void InitializeRandomSeed(unsigned int seed);
|
||||
protected:
|
||||
// Returns a uniformly distributed random value between 0.0 and 1.0
|
||||
|
||||
@ -33,7 +33,7 @@ class PredictivePacketManipulator : public PacketManipulatorImpl {
|
||||
void AddRandomResult(double result);
|
||||
protected:
|
||||
// Returns a uniformly distributed random value between 0.0 and 1.0
|
||||
virtual double RandomUniform();
|
||||
virtual double RandomUniform() OVERRIDE;
|
||||
|
||||
private:
|
||||
std::queue<double> random_results_;
|
||||
|
||||
@ -17,6 +17,20 @@
|
||||
namespace webrtc {
|
||||
namespace test {
|
||||
|
||||
FrameStatistic::FrameStatistic()
|
||||
: encoding_successful(false),
|
||||
decoding_successful(false),
|
||||
encode_return_code(0),
|
||||
decode_return_code(0),
|
||||
encode_time_in_us(0),
|
||||
decode_time_in_us(0),
|
||||
frame_number(0),
|
||||
packets_dropped(0),
|
||||
total_packets(0),
|
||||
bit_rate_in_kbps(0),
|
||||
encoded_frame_length_in_bytes(0),
|
||||
frame_type(kDeltaFrame) {}
|
||||
|
||||
Stats::Stats() {}
|
||||
|
||||
Stats::~Stats() {}
|
||||
|
||||
@ -20,14 +20,8 @@ namespace test {
|
||||
|
||||
// Contains statistics of a single frame that has been processed.
|
||||
struct FrameStatistic {
|
||||
FrameStatistic() :
|
||||
encoding_successful(false), decoding_successful(false),
|
||||
encode_return_code(0), decode_return_code(0),
|
||||
encode_time_in_us(0), decode_time_in_us(0),
|
||||
frame_number(0), packets_dropped(0), total_packets(0),
|
||||
bit_rate_in_kbps(0), encoded_frame_length_in_bytes(0),
|
||||
frame_type(kDeltaFrame) {
|
||||
};
|
||||
FrameStatistic();
|
||||
|
||||
bool encoding_successful;
|
||||
bool decoding_successful;
|
||||
int encode_return_code;
|
||||
@ -35,7 +29,7 @@ struct FrameStatistic {
|
||||
int encode_time_in_us;
|
||||
int decode_time_in_us;
|
||||
int frame_number;
|
||||
// How many packets were discarded of the encoded frame data (if any)
|
||||
// How many packets were discarded of the encoded frame data (if any).
|
||||
int packets_dropped;
|
||||
int total_packets;
|
||||
|
||||
|
||||
@ -20,6 +20,23 @@
|
||||
namespace webrtc {
|
||||
namespace test {
|
||||
|
||||
TestConfig::TestConfig()
|
||||
: name(""),
|
||||
description(""),
|
||||
test_number(0),
|
||||
input_filename(""),
|
||||
output_filename(""),
|
||||
output_dir("out"),
|
||||
networking_config(),
|
||||
exclude_frame_types(kExcludeOnlyFirstKeyFrame),
|
||||
frame_length_in_bytes(-1),
|
||||
use_single_core(false),
|
||||
keyframe_interval(0),
|
||||
codec_settings(NULL),
|
||||
verbose(true) {}
|
||||
|
||||
TestConfig::~TestConfig() {}
|
||||
|
||||
VideoProcessorImpl::VideoProcessorImpl(webrtc::VideoEncoder* encoder,
|
||||
webrtc::VideoDecoder* decoder,
|
||||
FrameReader* frame_reader,
|
||||
|
||||
@ -40,13 +40,8 @@ const char* ExcludeFrameTypesToStr(ExcludeFrameTypes e);
|
||||
|
||||
// Test configuration for a test run
|
||||
struct TestConfig {
|
||||
TestConfig()
|
||||
: name(""), description(""), test_number(0),
|
||||
input_filename(""), output_filename(""), output_dir("out"),
|
||||
networking_config(), exclude_frame_types(kExcludeOnlyFirstKeyFrame),
|
||||
frame_length_in_bytes(-1), use_single_core(false), keyframe_interval(0),
|
||||
codec_settings(NULL), verbose(true) {
|
||||
};
|
||||
TestConfig();
|
||||
~TestConfig();
|
||||
|
||||
// Name of the test. This is purely metadata and does not affect
|
||||
// the test in any way.
|
||||
@ -168,8 +163,8 @@ class VideoProcessorImpl : public VideoProcessor {
|
||||
const TestConfig& config,
|
||||
Stats* stats);
|
||||
virtual ~VideoProcessorImpl();
|
||||
virtual bool Init();
|
||||
virtual bool ProcessFrame(int frame_number);
|
||||
virtual bool Init() OVERRIDE;
|
||||
virtual bool ProcessFrame(int frame_number) OVERRIDE;
|
||||
|
||||
private:
|
||||
// Invoked by the callback when a frame has completed encoding.
|
||||
@ -181,13 +176,13 @@ class VideoProcessorImpl : public VideoProcessor {
|
||||
int GetElapsedTimeMicroseconds(const webrtc::TickTime& start,
|
||||
const webrtc::TickTime& stop);
|
||||
// Updates the encoder with the target bit rate and the frame rate.
|
||||
void SetRates(int bit_rate, int frame_rate);
|
||||
virtual void SetRates(int bit_rate, int frame_rate) OVERRIDE;
|
||||
// Return the size of the encoded frame in bytes.
|
||||
int EncodedFrameSize();
|
||||
virtual int EncodedFrameSize() OVERRIDE;
|
||||
// Return the number of dropped frames.
|
||||
int NumberDroppedFrames();
|
||||
virtual int NumberDroppedFrames() OVERRIDE;
|
||||
// Return the number of spatial resizes.
|
||||
int NumberSpatialResizes();
|
||||
virtual int NumberSpatialResizes() OVERRIDE;
|
||||
|
||||
webrtc::VideoEncoder* encoder_;
|
||||
webrtc::VideoDecoder* decoder_;
|
||||
@ -226,14 +221,14 @@ class VideoProcessorImpl : public VideoProcessor {
|
||||
|
||||
// Callback class required to implement according to the VideoEncoder API.
|
||||
class VideoProcessorEncodeCompleteCallback
|
||||
: public webrtc::EncodedImageCallback {
|
||||
: public webrtc::EncodedImageCallback {
|
||||
public:
|
||||
explicit VideoProcessorEncodeCompleteCallback(VideoProcessorImpl* vp)
|
||||
: video_processor_(vp) {
|
||||
}
|
||||
int32_t Encoded(webrtc::EncodedImage& encoded_image,
|
||||
const webrtc::CodecSpecificInfo* codec_specific_info = NULL,
|
||||
const webrtc::RTPFragmentationHeader* fragmentation = NULL);
|
||||
explicit VideoProcessorEncodeCompleteCallback(VideoProcessorImpl* vp)
|
||||
: video_processor_(vp) {}
|
||||
virtual int32_t Encoded(
|
||||
webrtc::EncodedImage& encoded_image,
|
||||
const webrtc::CodecSpecificInfo* codec_specific_info = NULL,
|
||||
const webrtc::RTPFragmentationHeader* fragmentation = NULL) OVERRIDE;
|
||||
|
||||
private:
|
||||
VideoProcessorImpl* video_processor_;
|
||||
@ -246,7 +241,7 @@ class VideoProcessorImpl : public VideoProcessor {
|
||||
explicit VideoProcessorDecodeCompleteCallback(VideoProcessorImpl* vp)
|
||||
: video_processor_(vp) {
|
||||
}
|
||||
int32_t Decoded(webrtc::I420VideoFrame& image);
|
||||
virtual int32_t Decoded(webrtc::I420VideoFrame& image) OVERRIDE;
|
||||
|
||||
private:
|
||||
VideoProcessorImpl* video_processor_;
|
||||
|
||||
Reference in New Issue
Block a user