OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "media/cast/receiver/audio_decoder.h" | 5 #include "media/cast/receiver/audio_decoder.h" |
6 | 6 |
| 7 #include <stdint.h> |
| 8 |
7 #include "base/bind.h" | 9 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
9 #include "base/location.h" | 11 #include "base/location.h" |
10 #include "base/logging.h" | 12 #include "base/logging.h" |
| 13 #include "base/macros.h" |
11 #include "base/sys_byteorder.h" | 14 #include "base/sys_byteorder.h" |
| 15 #include "build/build_config.h" |
12 #include "third_party/opus/src/include/opus.h" | 16 #include "third_party/opus/src/include/opus.h" |
13 | 17 |
14 namespace media { | 18 namespace media { |
15 namespace cast { | 19 namespace cast { |
16 | 20 |
17 // Base class that handles the common problem of detecting dropped frames, and | 21 // Base class that handles the common problem of detecting dropped frames, and |
18 // then invoking the Decode() method implemented by the subclasses to convert | 22 // then invoking the Decode() method implemented by the subclasses to convert |
19 // the encoded payload data into usable audio data. | 23 // the encoded payload data into usable audio data. |
20 class AudioDecoder::ImplBase | 24 class AudioDecoder::ImplBase |
21 : public base::RefCountedThreadSafe<AudioDecoder::ImplBase> { | 25 : public base::RefCountedThreadSafe<AudioDecoder::ImplBase> { |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
243 cast_environment_->PostTask(CastEnvironment::AUDIO, | 247 cast_environment_->PostTask(CastEnvironment::AUDIO, |
244 FROM_HERE, | 248 FROM_HERE, |
245 base::Bind(&AudioDecoder::ImplBase::DecodeFrame, | 249 base::Bind(&AudioDecoder::ImplBase::DecodeFrame, |
246 impl_, | 250 impl_, |
247 base::Passed(&encoded_frame), | 251 base::Passed(&encoded_frame), |
248 callback)); | 252 callback)); |
249 } | 253 } |
250 | 254 |
251 } // namespace cast | 255 } // namespace cast |
252 } // namespace media | 256 } // namespace media |
OLD | NEW |