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

Unified Diff: webrtc/modules/audio_coding/neteq/tools/rtp_file_source.cc

Issue 1427923003: Re-enable PCAP reading in neteq_rtpplay (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: 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
« no previous file with comments | « webrtc/modules/audio_coding/neteq/tools/rtp_file_source.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/audio_coding/neteq/tools/rtp_file_source.cc
diff --git a/webrtc/modules/audio_coding/neteq/tools/rtp_file_source.cc b/webrtc/modules/audio_coding/neteq/tools/rtp_file_source.cc
index 9681ad17ea827ed2477754b169c0d061ae0b8cc9..e3a829bd243a7e4d5f1e203ad5587e2c96cd424b 100644
--- a/webrtc/modules/audio_coding/neteq/tools/rtp_file_source.cc
+++ b/webrtc/modules/audio_coding/neteq/tools/rtp_file_source.cc
@@ -32,6 +32,18 @@ RtpFileSource* RtpFileSource::Create(const std::string& file_name) {
return source;
}
+bool RtpFileSource::ValidRtpDump(const std::string& file_name) {
+ rtc::scoped_ptr<RtpFileReader> temp_file(
+ RtpFileReader::Create(RtpFileReader::kRtpDump, file_name));
+ return !!temp_file;
ivoc 2015/11/02 15:27:09 I have a hard time understanding the !!, is there
hlundin-webrtc 2015/11/02 15:41:21 I blame kwiberg for recruiting me to the dark side
kwiberg-webrtc 2015/11/02 19:24:59 !x is true if x is false, false if x is true. So !
hlundin-webrtc 2015/11/03 06:44:41 Thanks for providing that invaluable truth table.
+}
+
+bool RtpFileSource::ValidPcap(const std::string& file_name) {
+ rtc::scoped_ptr<RtpFileReader> temp_file(
+ RtpFileReader::Create(RtpFileReader::kPcap, file_name));
+ return !!temp_file;
+}
+
RtpFileSource::~RtpFileSource() {
}
« no previous file with comments | « webrtc/modules/audio_coding/neteq/tools/rtp_file_source.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698