| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/ffmpeg_demuxer.h" | 5 #include "media/filters/ffmpeg_demuxer.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/base64.h" | 10 #include "base/base64.h" |
| (...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 261 | 261 |
| 262 SatisfyPendingRead(); | 262 SatisfyPendingRead(); |
| 263 } | 263 } |
| 264 | 264 |
| 265 void FFmpegDemuxerStream::EnableBitstreamConverter() { | 265 void FFmpegDemuxerStream::EnableBitstreamConverter() { |
| 266 DCHECK(task_runner_->BelongsToCurrentThread()); | 266 DCHECK(task_runner_->BelongsToCurrentThread()); |
| 267 CHECK(bitstream_converter_.get()); | 267 CHECK(bitstream_converter_.get()); |
| 268 bitstream_converter_enabled_ = true; | 268 bitstream_converter_enabled_ = true; |
| 269 } | 269 } |
| 270 | 270 |
| 271 bool FFmpegDemuxerStream::SupportsConfigChanges() { return false; } |
| 272 |
| 271 AudioDecoderConfig FFmpegDemuxerStream::audio_decoder_config() { | 273 AudioDecoderConfig FFmpegDemuxerStream::audio_decoder_config() { |
| 272 DCHECK(task_runner_->BelongsToCurrentThread()); | 274 DCHECK(task_runner_->BelongsToCurrentThread()); |
| 273 CHECK_EQ(type_, AUDIO); | 275 CHECK_EQ(type_, AUDIO); |
| 274 return audio_config_; | 276 return audio_config_; |
| 275 } | 277 } |
| 276 | 278 |
| 277 VideoDecoderConfig FFmpegDemuxerStream::video_decoder_config() { | 279 VideoDecoderConfig FFmpegDemuxerStream::video_decoder_config() { |
| 278 DCHECK(task_runner_->BelongsToCurrentThread()); | 280 DCHECK(task_runner_->BelongsToCurrentThread()); |
| 279 CHECK_EQ(type_, VIDEO); | 281 CHECK_EQ(type_, VIDEO); |
| 280 return video_config_; | 282 return video_config_; |
| (...skipping 701 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 982 } | 984 } |
| 983 for (size_t i = 0; i < buffered.size(); ++i) | 985 for (size_t i = 0; i < buffered.size(); ++i) |
| 984 host_->AddBufferedTimeRange(buffered.start(i), buffered.end(i)); | 986 host_->AddBufferedTimeRange(buffered.start(i), buffered.end(i)); |
| 985 } | 987 } |
| 986 | 988 |
| 987 void FFmpegDemuxer::OnDataSourceError() { | 989 void FFmpegDemuxer::OnDataSourceError() { |
| 988 host_->OnDemuxerError(PIPELINE_ERROR_READ); | 990 host_->OnDemuxerError(PIPELINE_ERROR_READ); |
| 989 } | 991 } |
| 990 | 992 |
| 991 } // namespace media | 993 } // namespace media |
| OLD | NEW |