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

Unified Diff: webrtc/modules/audio_processing/test/conversational_speech/multiend_call.h

Issue 2790933002: Conversational speech tool, simualtor + unit tests (Closed)
Patch Set: Using AppendFolder() to build paths to folders Created 3 years, 9 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/audio_processing/test/conversational_speech/multiend_call.h
diff --git a/webrtc/modules/audio_processing/test/conversational_speech/multiend_call.h b/webrtc/modules/audio_processing/test/conversational_speech/multiend_call.h
index 6dae8220661e5d41ec909dc9a2e923e6f08e827e..5efe3258061733a0c02c225f391317ee2627b9b2 100644
--- a/webrtc/modules/audio_processing/test/conversational_speech/multiend_call.h
+++ b/webrtc/modules/audio_processing/test/conversational_speech/multiend_call.h
@@ -53,6 +53,7 @@ class MultiEndCall {
const std::map<std::string, std::unique_ptr<WavReaderInterface>>&
audiotrack_readers() const;
bool valid() const;
+ int sample_rate() const;
std::size_t total_duration_samples() const;
const std::vector<SpeakingTurn>& speaking_turns() const;
@@ -60,8 +61,10 @@ class MultiEndCall {
// Finds unique speaker names.
void FindSpeakerNames();
- // Creates one WavReader instance for each unique audiotrack.
- void CreateAudioTrackReaders();
+ // Creates one WavReader instance for each unique audiotrack. It returns false
+ // if the audio tracks do not have the same sample rate or if they are not
+ // mono.
+ bool CreateAudioTrackReaders();
// Validates the speaking turns timing information. Accepts cross-talk, but
// only up to 2 speakers. Rejects unordered turns and self cross-talk.
@@ -79,6 +82,7 @@ class MultiEndCall {
std::map<std::string, std::unique_ptr<WavReaderInterface>>
audiotrack_readers_;
bool valid_;
+ int sample_rate_;
std::size_t total_duration_samples_;
std::vector<SpeakingTurn> speaking_turns_;

Powered by Google App Engine
This is Rietveld 408576698