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

Unified Diff: webrtc/modules/audio_coding/neteq/tools/fake_decode_from_file.h

Issue 2275903002: Make FakeDecodeFromFile handle codec-internal CNG (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fixing compile errors Created 4 years, 4 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 | « no previous file | webrtc/modules/audio_coding/neteq/tools/fake_decode_from_file.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/audio_coding/neteq/tools/fake_decode_from_file.h
diff --git a/webrtc/modules/audio_coding/neteq/tools/fake_decode_from_file.h b/webrtc/modules/audio_coding/neteq/tools/fake_decode_from_file.h
index 2c51998261c3998baa85345f6fafcab173d865a6..69f9c82d3845a6a1569782cd9acaad43ef5ef7e4 100644
--- a/webrtc/modules/audio_coding/neteq/tools/fake_decode_from_file.h
+++ b/webrtc/modules/audio_coding/neteq/tools/fake_decode_from_file.h
@@ -50,11 +50,13 @@ class FakeDecodeFromFile : public AudioDecoder {
int16_t* decoded,
SpeechType* speech_type) override;
- // Helper method. Writes |timestamp| and |samples| to |encoded| in a format
- // that the FakeDecpdeFromFile decoder will understand. |encoded| must be at
- // least 8 bytes long.
+ // Helper method. Writes |timestamp|, |samples| and
+ // |original_payload_size_bytes| to |encoded| in a format that the
+ // FakeDecodeFromFile decoder will understand. |encoded| must be at least 12
+ // bytes long.
static void PrepareEncoded(uint32_t timestamp,
size_t samples,
+ size_t original_payload_size_bytes,
rtc::ArrayView<uint8_t> encoded);
private:
@@ -62,6 +64,8 @@ class FakeDecodeFromFile : public AudioDecoder {
rtc::Optional<uint32_t> next_timestamp_from_input_;
const int sample_rate_hz_;
const bool stereo_;
+ size_t last_decoded_length_ = 0;
+ bool cng_mode_ = false;
};
} // namespace test
« no previous file with comments | « no previous file | webrtc/modules/audio_coding/neteq/tools/fake_decode_from_file.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698