Revert of Opus implementation of the AudioDecoderFactoryTemplate API (patchset #1 id:1 of https://codereview.webrtc.org/2942733003/ )
Reason for revert:
breaking downstream projects
Original issue's description:
> Opus implementation of the AudioDecoderFactoryTemplate API
>
> BUG=webrtc:7837
>
> Review-Url: https://codereview.webrtc.org/2942733003
> Cr-Commit-Position: refs/heads/master@{#18646}
> Committed: d053fe4ab3
TBR=ossu@webrtc.org,solenberg@webrtc.org,kwiberg@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:7837
Review-Url: https://codereview.webrtc.org/2944763002
Cr-Commit-Position: refs/heads/master@{#18648}
This commit is contained in:
@ -26,7 +26,6 @@ if (rtc_include_tests) {
|
||||
"../../../test:test_support",
|
||||
"../g722:audio_decoder_g722",
|
||||
"../g722:audio_encoder_g722",
|
||||
"../opus:audio_decoder_opus",
|
||||
"../opus:audio_encoder_opus",
|
||||
"//testing/gmock",
|
||||
]
|
||||
|
||||
@ -10,7 +10,6 @@
|
||||
|
||||
#include "webrtc/api/audio_codecs/audio_decoder_factory_template.h"
|
||||
#include "webrtc/api/audio_codecs/g722/audio_decoder_g722.h"
|
||||
#include "webrtc/api/audio_codecs/opus/audio_decoder_opus.h"
|
||||
#include "webrtc/base/ptr_util.h"
|
||||
#include "webrtc/test/gmock.h"
|
||||
#include "webrtc/test/gtest.h"
|
||||
@ -125,21 +124,4 @@ TEST(AudioDecoderFactoryTemplateTest, G722) {
|
||||
EXPECT_EQ(16000, dec->SampleRateHz());
|
||||
}
|
||||
|
||||
TEST(AudioDecoderFactoryTemplateTest, Opus) {
|
||||
auto factory = CreateAudioDecoderFactory<AudioDecoderOpus>();
|
||||
AudioCodecInfo opus_info{48000, 1, 64000, 6000, 510000};
|
||||
opus_info.allow_comfort_noise = false;
|
||||
opus_info.supports_network_adaption = true;
|
||||
const SdpAudioFormat opus_format(
|
||||
{"opus", 48000, 2, {{"minptime", "10"}, {"useinbandfec", "1"}}});
|
||||
EXPECT_THAT(factory->GetSupportedDecoders(),
|
||||
testing::ElementsAre(AudioCodecSpec{opus_format, opus_info}));
|
||||
EXPECT_FALSE(factory->IsSupportedDecoder({"opus", 48000, 1}));
|
||||
EXPECT_TRUE(factory->IsSupportedDecoder({"opus", 48000, 2}));
|
||||
EXPECT_EQ(nullptr, factory->MakeAudioDecoder({"bar", 16000, 1}));
|
||||
auto dec = factory->MakeAudioDecoder({"opus", 48000, 2});
|
||||
ASSERT_NE(nullptr, dec);
|
||||
EXPECT_EQ(48000, dec->SampleRateHz());
|
||||
}
|
||||
|
||||
} // namespace webrtc
|
||||
|
||||
Reference in New Issue
Block a user