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 #ifndef MEDIA_BASE_PIPELINE_H_ | 5 #ifndef MEDIA_BASE_PIPELINE_H_ |
6 #define MEDIA_BASE_PIPELINE_H_ | 6 #define MEDIA_BASE_PIPELINE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/gtest_prod_util.h" | 10 #include "base/gtest_prod_util.h" |
11 #include "base/synchronization/condition_variable.h" | 11 #include "base/synchronization/condition_variable.h" |
12 #include "base/synchronization/lock.h" | 12 #include "base/synchronization/lock.h" |
13 #include "base/threading/thread_checker.h" | 13 #include "base/threading/thread_checker.h" |
14 #include "base/time/default_tick_clock.h" | 14 #include "base/time/default_tick_clock.h" |
15 #include "media/base/audio_renderer.h" | 15 #include "media/base/audio_renderer.h" |
16 #include "media/base/buffering_state.h" | 16 #include "media/base/buffering_state.h" |
17 #include "media/base/demuxer.h" | 17 #include "media/base/demuxer.h" |
18 #include "media/base/media_export.h" | 18 #include "media/base/media_export.h" |
19 #include "media/base/pipeline_status.h" | 19 #include "media/base/pipeline_status.h" |
20 #include "media/base/ranges.h" | 20 #include "media/base/ranges.h" |
21 #include "media/base/serial_runner.h" | 21 #include "media/base/serial_runner.h" |
22 #include "media/base/video_decoder_config.h" | |
22 #include "ui/gfx/size.h" | 23 #include "ui/gfx/size.h" |
23 | 24 |
24 namespace base { | 25 namespace base { |
25 class SingleThreadTaskRunner; | 26 class SingleThreadTaskRunner; |
26 class TimeDelta; | 27 class TimeDelta; |
27 } | 28 } |
28 | 29 |
29 namespace media { | 30 namespace media { |
30 | 31 |
31 class Clock; | 32 class Clock; |
32 class FilterCollection; | 33 class FilterCollection; |
33 class MediaLog; | 34 class MediaLog; |
34 class TextRenderer; | 35 class TextRenderer; |
35 class TextTrackConfig; | 36 class TextTrackConfig; |
36 class VideoRenderer; | 37 class VideoRenderer; |
37 | 38 |
38 // Metadata describing a pipeline once it has been initialized. | 39 // Metadata describing a pipeline once it has been initialized. |
39 struct PipelineMetadata { | 40 struct PipelineMetadata { |
40 PipelineMetadata() : has_audio(false), has_video(false) {} | 41 PipelineMetadata() : has_audio(false), has_video(false), |
42 rotation(media::kRotate0) {} | |
scherkus (not reviewing)
2014/07/07 20:52:38
we're inside the media namsepace so we can drop me
| |
41 | 43 |
42 bool has_audio; | 44 bool has_audio; |
43 bool has_video; | 45 bool has_video; |
44 gfx::Size natural_size; | 46 gfx::Size natural_size; |
47 media::VideoRotation rotation; | |
scherkus (not reviewing)
2014/07/07 20:52:38
ditto
| |
45 base::Time timeline_offset; | 48 base::Time timeline_offset; |
46 }; | 49 }; |
47 | 50 |
48 typedef base::Callback<void(PipelineMetadata)> PipelineMetadataCB; | 51 typedef base::Callback<void(PipelineMetadata)> PipelineMetadataCB; |
49 | 52 |
50 // Pipeline runs the media pipeline. Filters are created and called on the | 53 // Pipeline runs the media pipeline. Filters are created and called on the |
51 // task runner injected into this object. Pipeline works like a state | 54 // task runner injected into this object. Pipeline works like a state |
52 // machine to perform asynchronous initialization, pausing, seeking and playing. | 55 // machine to perform asynchronous initialization, pausing, seeking and playing. |
53 // | 56 // |
54 // Here's a state diagram that describes the lifetime of this object. | 57 // Here's a state diagram that describes the lifetime of this object. |
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
434 bool underflow_disabled_for_testing_; | 437 bool underflow_disabled_for_testing_; |
435 | 438 |
436 base::ThreadChecker thread_checker_; | 439 base::ThreadChecker thread_checker_; |
437 | 440 |
438 DISALLOW_COPY_AND_ASSIGN(Pipeline); | 441 DISALLOW_COPY_AND_ASSIGN(Pipeline); |
439 }; | 442 }; |
440 | 443 |
441 } // namespace media | 444 } // namespace media |
442 | 445 |
443 #endif // MEDIA_BASE_PIPELINE_H_ | 446 #endif // MEDIA_BASE_PIPELINE_H_ |
OLD | NEW |