OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
3 * Copyright (C) 2011 Ericsson AB. All rights reserved. | 3 * Copyright (C) 2011 Ericsson AB. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 17 matching lines...) Expand all Loading... |
28 | 28 |
29 #include "bindings/core/v8/ActiveScriptWrappable.h" | 29 #include "bindings/core/v8/ActiveScriptWrappable.h" |
30 #include "core/dom/ActiveDOMObject.h" | 30 #include "core/dom/ActiveDOMObject.h" |
31 #include "modules/EventTargetModules.h" | 31 #include "modules/EventTargetModules.h" |
32 #include "modules/ModulesExport.h" | 32 #include "modules/ModulesExport.h" |
33 #include "modules/mediastream/SourceInfo.h" | 33 #include "modules/mediastream/SourceInfo.h" |
34 #include "platform/mediastream/MediaStreamDescriptor.h" | 34 #include "platform/mediastream/MediaStreamDescriptor.h" |
35 #include "platform/mediastream/MediaStreamSource.h" | 35 #include "platform/mediastream/MediaStreamSource.h" |
36 #include "public/platform/WebMediaConstraints.h" | 36 #include "public/platform/WebMediaConstraints.h" |
37 #include "wtf/Forward.h" | 37 #include "wtf/Forward.h" |
38 #include <memory> | |
39 | 38 |
40 namespace blink { | 39 namespace blink { |
41 | 40 |
42 class AudioSourceProvider; | 41 class AudioSourceProvider; |
43 class ExceptionState; | 42 class ExceptionState; |
44 class MediaTrackConstraints; | 43 class MediaTrackConstraints; |
45 class MediaStreamTrackSourcesCallback; | 44 class MediaStreamTrackSourcesCallback; |
46 class MediaTrackSettings; | 45 class MediaTrackSettings; |
47 | 46 |
48 class MODULES_EXPORT MediaStreamTrack | 47 class MODULES_EXPORT MediaStreamTrack |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
93 // EventTarget | 92 // EventTarget |
94 const AtomicString& interfaceName() const override; | 93 const AtomicString& interfaceName() const override; |
95 ExecutionContext* getExecutionContext() const override; | 94 ExecutionContext* getExecutionContext() const override; |
96 | 95 |
97 // ActiveScriptWrappable | 96 // ActiveScriptWrappable |
98 bool hasPendingActivity() const final; | 97 bool hasPendingActivity() const final; |
99 | 98 |
100 // ActiveDOMObject | 99 // ActiveDOMObject |
101 void stop() override; | 100 void stop() override; |
102 | 101 |
103 std::unique_ptr<AudioSourceProvider> createWebAudioSource(); | 102 PassOwnPtr<AudioSourceProvider> createWebAudioSource(); |
104 | 103 |
105 DECLARE_VIRTUAL_TRACE(); | 104 DECLARE_VIRTUAL_TRACE(); |
106 | 105 |
107 private: | 106 private: |
108 friend class CanvasCaptureMediaStreamTrack; | 107 friend class CanvasCaptureMediaStreamTrack; |
109 | 108 |
110 MediaStreamTrack(ExecutionContext*, MediaStreamComponent*); | 109 MediaStreamTrack(ExecutionContext*, MediaStreamComponent*); |
111 | 110 |
112 // MediaStreamSourceObserver | 111 // MediaStreamSourceObserver |
113 void sourceChangedState() override; | 112 void sourceChangedState() override; |
114 | 113 |
115 void propagateTrackEnded(); | 114 void propagateTrackEnded(); |
116 | 115 |
117 MediaStreamSource::ReadyState m_readyState; | 116 MediaStreamSource::ReadyState m_readyState; |
118 HeapHashSet<Member<MediaStream>> m_registeredMediaStreams; | 117 HeapHashSet<Member<MediaStream>> m_registeredMediaStreams; |
119 bool m_isIteratingRegisteredMediaStreams; | 118 bool m_isIteratingRegisteredMediaStreams; |
120 bool m_stopped; | 119 bool m_stopped; |
121 Member<MediaStreamComponent> m_component; | 120 Member<MediaStreamComponent> m_component; |
122 WebMediaConstraints m_constraints; | 121 WebMediaConstraints m_constraints; |
123 }; | 122 }; |
124 | 123 |
125 typedef HeapVector<Member<MediaStreamTrack>> MediaStreamTrackVector; | 124 typedef HeapVector<Member<MediaStreamTrack>> MediaStreamTrackVector; |
126 | 125 |
127 } // namespace blink | 126 } // namespace blink |
128 | 127 |
129 #endif // MediaStreamTrack_h | 128 #endif // MediaStreamTrack_h |
OLD | NEW |