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

Unified Diff: webrtc/modules/video_coding/utility/include/qp_parser.h

Issue 1340623002: Add stats for average QP per frame for VP8 (for received video streams). (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: address comment Created 5 years, 2 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
Index: webrtc/modules/video_coding/utility/include/qp_parser.h
diff --git a/webrtc/voice_engine/mock/mock_transport.h b/webrtc/modules/video_coding/utility/include/qp_parser.h
similarity index 51%
copy from webrtc/voice_engine/mock/mock_transport.h
copy to webrtc/modules/video_coding/utility/include/qp_parser.h
index c356f44d285b66cdca14df5492199f72e2a3fd7c..7752892f892177d7665afe7331532741920dbcfc 100644
--- a/webrtc/voice_engine/mock/mock_transport.h
+++ b/webrtc/modules/video_coding/utility/include/qp_parser.h
@@ -8,20 +8,26 @@
* be found in the AUTHORS file in the root of the source tree.
*/
-#ifndef WEBRTC_VOICE_ENGINE_MOCK_TRANSPORT_H_
-#define WEBRTC_VOICE_ENGINE_MOCK_TRANSPORT_H_
+#ifndef WEBRTC_MODULES_VIDEO_CODING_UTILITY_QP_PARSER_H_
+#define WEBRTC_MODULES_VIDEO_CODING_UTILITY_QP_PARSER_H_
-#include "testing/gmock/include/gmock/gmock.h"
#include "webrtc/common_types.h"
namespace webrtc {
-class MockTransport : public Transport {
+class QpParser {
public:
- MOCK_METHOD2(SendPacket, int(const void* data, size_t len));
- MOCK_METHOD2(SendRTCPPacket, int(const void* data, size_t len));
+ QpParser() {}
+ ~QpParser() {}
+
+ // Parses |encoded_frame| of |codec_type| and extracts the |qp|.
+ // Returns true on success, false otherwise.
+ bool GetQp(const uint8_t* encoded_frame,
+ size_t length,
+ VideoCodecType codec_type,
stefan-webrtc 2015/10/15 12:49:35 Can this take a VCMEncodedFrame instead maybe?
åsapersson 2015/10/16 09:33:59 Done.
+ int* qp);
};
} // namespace webrtc
-#endif // WEBRTC_VOICE_ENGINE_MOCK_TRANSPORT_H_
+#endif // WEBRTC_MODULES_VIDEO_CODING_UTILITY_QP_PARSER_H_

Powered by Google App Engine
This is Rietveld 408576698