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

Side by Side Diff: webrtc/modules/audio_coding/codecs/isac/fix/test/isac_speed_test.cc

Issue 1319683002: AudioDecoder: Replace Init() with Reset() (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@buffer
Patch Set: review fixes Created 5 years, 3 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 30 matching lines...) Expand all
41 41
42 void IsacSpeedTest::SetUp() { 42 void IsacSpeedTest::SetUp() {
43 AudioCodecSpeedTest::SetUp(); 43 AudioCodecSpeedTest::SetUp();
44 44
45 // Check whether the allocated buffer for the bit stream is large enough. 45 // Check whether the allocated buffer for the bit stream is large enough.
46 EXPECT_GE(max_bytes_, static_cast<size_t>(STREAM_MAXW16_60MS)); 46 EXPECT_GE(max_bytes_, static_cast<size_t>(STREAM_MAXW16_60MS));
47 47
48 // Create encoder memory. 48 // Create encoder memory.
49 EXPECT_EQ(0, WebRtcIsacfix_Create(&ISACFIX_main_inst_)); 49 EXPECT_EQ(0, WebRtcIsacfix_Create(&ISACFIX_main_inst_));
50 EXPECT_EQ(0, WebRtcIsacfix_EncoderInit(ISACFIX_main_inst_, 1)); 50 EXPECT_EQ(0, WebRtcIsacfix_EncoderInit(ISACFIX_main_inst_, 1));
51 EXPECT_EQ(0, WebRtcIsacfix_DecoderInit(ISACFIX_main_inst_)); 51 WebRtcIsacfix_DecoderInit(ISACFIX_main_inst_);
52 // Set bitrate and block length. 52 // Set bitrate and block length.
53 EXPECT_EQ(0, WebRtcIsacfix_Control(ISACFIX_main_inst_, bit_rate_, 53 EXPECT_EQ(0, WebRtcIsacfix_Control(ISACFIX_main_inst_, bit_rate_,
54 block_duration_ms_)); 54 block_duration_ms_));
55 } 55 }
56 56
57 void IsacSpeedTest::TearDown() { 57 void IsacSpeedTest::TearDown() {
58 AudioCodecSpeedTest::TearDown(); 58 AudioCodecSpeedTest::TearDown();
59 // Free memory. 59 // Free memory.
60 EXPECT_EQ(0, WebRtcIsacfix_Free(ISACFIX_main_inst_)); 60 EXPECT_EQ(0, WebRtcIsacfix_Free(ISACFIX_main_inst_));
61 } 61 }
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 } 102 }
103 103
104 const coding_param param_set[] = 104 const coding_param param_set[] =
105 {::std::tr1::make_tuple(1, 32000, string("audio_coding/speech_mono_16kHz"), 105 {::std::tr1::make_tuple(1, 32000, string("audio_coding/speech_mono_16kHz"),
106 string("pcm"), true)}; 106 string("pcm"), true)};
107 107
108 INSTANTIATE_TEST_CASE_P(AllTest, IsacSpeedTest, 108 INSTANTIATE_TEST_CASE_P(AllTest, IsacSpeedTest,
109 ::testing::ValuesIn(param_set)); 109 ::testing::ValuesIn(param_set));
110 110
111 } // namespace webrtc 111 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698