| 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/filters/decoder_stream_traits.h" | 5 #include "media/filters/decoder_stream_traits.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "media/base/audio_buffer.h" | 8 #include "media/base/audio_buffer.h" |
| 9 #include "media/base/audio_decoder.h" | 9 #include "media/base/audio_decoder.h" |
| 10 #include "media/base/audio_decoder_config.h" | 10 #include "media/base/audio_decoder_config.h" |
| 11 #include "media/base/video_decoder.h" | 11 #include "media/base/video_decoder.h" |
| 12 #include "media/base/video_decoder_config.h" | 12 #include "media/base/video_decoder_config.h" |
| 13 #include "media/base/video_frame.h" | 13 #include "media/base/video_frame.h" |
| 14 | 14 |
| 15 namespace media { | 15 namespace media { |
| 16 | 16 |
| 17 std::string DecoderStreamTraits<DemuxerStream::AUDIO>::ToString() { | 17 std::string DecoderStreamTraits<DemuxerStream::AUDIO>::ToString() { |
| 18 return "Audio"; | 18 return "audio"; |
| 19 } | 19 } |
| 20 | 20 |
| 21 void DecoderStreamTraits<DemuxerStream::AUDIO>::Initialize( | 21 void DecoderStreamTraits<DemuxerStream::AUDIO>::Initialize( |
| 22 DecoderType* decoder, | 22 DecoderType* decoder, |
| 23 const DecoderConfigType& config, | 23 const DecoderConfigType& config, |
| 24 bool low_delay, | 24 bool low_delay, |
| 25 const PipelineStatusCB& status_cb, | 25 const PipelineStatusCB& status_cb, |
| 26 const OutputCB& output_cb) { | 26 const OutputCB& output_cb) { |
| 27 decoder->Initialize(config, status_cb, output_cb); | 27 decoder->Initialize(config, status_cb, output_cb); |
| 28 } | 28 } |
| (...skipping 11 matching lines...) Expand all Loading... |
| 40 DemuxerStream& stream) { | 40 DemuxerStream& stream) { |
| 41 return stream.audio_decoder_config(); | 41 return stream.audio_decoder_config(); |
| 42 } | 42 } |
| 43 | 43 |
| 44 scoped_refptr<DecoderStreamTraits<DemuxerStream::AUDIO>::OutputType> | 44 scoped_refptr<DecoderStreamTraits<DemuxerStream::AUDIO>::OutputType> |
| 45 DecoderStreamTraits<DemuxerStream::AUDIO>::CreateEOSOutput() { | 45 DecoderStreamTraits<DemuxerStream::AUDIO>::CreateEOSOutput() { |
| 46 return OutputType::CreateEOSBuffer(); | 46 return OutputType::CreateEOSBuffer(); |
| 47 } | 47 } |
| 48 | 48 |
| 49 std::string DecoderStreamTraits<DemuxerStream::VIDEO>::ToString() { | 49 std::string DecoderStreamTraits<DemuxerStream::VIDEO>::ToString() { |
| 50 return "Video"; | 50 return "video"; |
| 51 } | 51 } |
| 52 | 52 |
| 53 void DecoderStreamTraits<DemuxerStream::VIDEO>::Initialize( | 53 void DecoderStreamTraits<DemuxerStream::VIDEO>::Initialize( |
| 54 DecoderType* decoder, | 54 DecoderType* decoder, |
| 55 const DecoderConfigType& config, | 55 const DecoderConfigType& config, |
| 56 bool low_delay, | 56 bool low_delay, |
| 57 const PipelineStatusCB& status_cb, | 57 const PipelineStatusCB& status_cb, |
| 58 const OutputCB& output_cb) { | 58 const OutputCB& output_cb) { |
| 59 decoder->Initialize(config, low_delay, status_cb, output_cb); | 59 decoder->Initialize(config, low_delay, status_cb, output_cb); |
| 60 } | 60 } |
| (...skipping 16 matching lines...) Expand all Loading... |
| 77 DemuxerStream& stream) { | 77 DemuxerStream& stream) { |
| 78 return stream.video_decoder_config(); | 78 return stream.video_decoder_config(); |
| 79 } | 79 } |
| 80 | 80 |
| 81 scoped_refptr<DecoderStreamTraits<DemuxerStream::VIDEO>::OutputType> | 81 scoped_refptr<DecoderStreamTraits<DemuxerStream::VIDEO>::OutputType> |
| 82 DecoderStreamTraits<DemuxerStream::VIDEO>::CreateEOSOutput() { | 82 DecoderStreamTraits<DemuxerStream::VIDEO>::CreateEOSOutput() { |
| 83 return OutputType::CreateEOSFrame(); | 83 return OutputType::CreateEOSFrame(); |
| 84 } | 84 } |
| 85 | 85 |
| 86 } // namespace media | 86 } // namespace media |
| OLD | NEW |