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/chunk_demuxer.h" | 5 #include "media/filters/chunk_demuxer.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <deque> | 8 #include <deque> |
9 #include <limits> | 9 #include <limits> |
10 | 10 |
(...skipping 1325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1336 audio_.reset(new ChunkDemuxerStream(DemuxerStream::AUDIO)); | 1336 audio_.reset(new ChunkDemuxerStream(DemuxerStream::AUDIO)); |
1337 return audio_.get(); | 1337 return audio_.get(); |
1338 break; | 1338 break; |
1339 case DemuxerStream::VIDEO: | 1339 case DemuxerStream::VIDEO: |
1340 if (video_) | 1340 if (video_) |
1341 return NULL; | 1341 return NULL; |
1342 video_.reset(new ChunkDemuxerStream(DemuxerStream::VIDEO)); | 1342 video_.reset(new ChunkDemuxerStream(DemuxerStream::VIDEO)); |
1343 return video_.get(); | 1343 return video_.get(); |
1344 break; | 1344 break; |
1345 case DemuxerStream::UNKNOWN: | 1345 case DemuxerStream::UNKNOWN: |
| 1346 case DemuxerStream::TEXT: |
1346 case DemuxerStream::NUM_TYPES: | 1347 case DemuxerStream::NUM_TYPES: |
1347 NOTREACHED(); | 1348 NOTREACHED(); |
1348 return NULL; | 1349 return NULL; |
1349 } | 1350 } |
1350 NOTREACHED(); | 1351 NOTREACHED(); |
1351 return NULL; | 1352 return NULL; |
1352 } | 1353 } |
1353 | 1354 |
1354 bool ChunkDemuxer::OnTextBuffers( | 1355 bool ChunkDemuxer::OnTextBuffers( |
1355 TextTrack* text_track, | 1356 TextTrack* text_track, |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1448 | 1449 |
1449 void ChunkDemuxer::CompletePendingReadsIfPossible() { | 1450 void ChunkDemuxer::CompletePendingReadsIfPossible() { |
1450 if (audio_) | 1451 if (audio_) |
1451 audio_->CompletePendingReadIfPossible(); | 1452 audio_->CompletePendingReadIfPossible(); |
1452 | 1453 |
1453 if (video_) | 1454 if (video_) |
1454 video_->CompletePendingReadIfPossible(); | 1455 video_->CompletePendingReadIfPossible(); |
1455 } | 1456 } |
1456 | 1457 |
1457 } // namespace media | 1458 } // namespace media |
OLD | NEW |