| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 ImageCapture_h | 5 #ifndef ImageCapture_h |
| 6 #define ImageCapture_h | 6 #define ImageCapture_h |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include "bindings/core/v8/ActiveScriptWrappable.h" | 9 #include "bindings/core/v8/ActiveScriptWrappable.h" |
| 10 #include "bindings/core/v8/ScriptPromise.h" | 10 #include "bindings/core/v8/ScriptPromise.h" |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 void setMediaTrackConstraints(ScriptPromiseResolver*, | 65 void setMediaTrackConstraints(ScriptPromiseResolver*, |
| 66 const MediaTrackConstraintSet&); | 66 const MediaTrackConstraintSet&); |
| 67 const MediaTrackConstraintSet& getMediaTrackConstraints() const; | 67 const MediaTrackConstraintSet& getMediaTrackConstraints() const; |
| 68 void getMediaTrackSettings(MediaTrackSettings&) const; | 68 void getMediaTrackSettings(MediaTrackSettings&) const; |
| 69 | 69 |
| 70 DECLARE_VIRTUAL_TRACE(); | 70 DECLARE_VIRTUAL_TRACE(); |
| 71 | 71 |
| 72 private: | 72 private: |
| 73 ImageCapture(ExecutionContext*, MediaStreamTrack*); | 73 ImageCapture(ExecutionContext*, MediaStreamTrack*); |
| 74 | 74 |
| 75 void onCapabilities(ScriptPromiseResolver*, | 75 void onPhotoCapabilities(ScriptPromiseResolver*, |
| 76 media::mojom::blink::PhotoCapabilitiesPtr); | 76 media::mojom::blink::PhotoCapabilitiesPtr); |
| 77 void onSetOptions(ScriptPromiseResolver*, bool); | 77 void onSetOptions(ScriptPromiseResolver*, bool); |
| 78 void onTakePhoto(ScriptPromiseResolver*, media::mojom::blink::BlobPtr); | 78 void onTakePhoto(ScriptPromiseResolver*, media::mojom::blink::BlobPtr); |
| 79 void onCapabilitiesUpdate(media::mojom::blink::PhotoCapabilitiesPtr); | 79 void onCapabilitiesUpdate(media::mojom::blink::PhotoCapabilitiesPtr); |
| 80 void onServiceConnectionError(); | 80 void onServiceConnectionError(); |
| 81 | 81 |
| 82 Member<MediaStreamTrack> m_streamTrack; | 82 Member<MediaStreamTrack> m_streamTrack; |
| 83 std::unique_ptr<WebImageCaptureFrameGrabber> m_frameGrabber; | 83 std::unique_ptr<WebImageCaptureFrameGrabber> m_frameGrabber; |
| 84 media::mojom::blink::ImageCapturePtr m_service; | 84 media::mojom::blink::ImageCapturePtr m_service; |
| 85 | 85 |
| 86 MediaTrackCapabilities m_capabilities; | 86 MediaTrackCapabilities m_capabilities; |
| 87 MediaTrackConstraintSet m_currentConstraints; | 87 MediaTrackConstraintSet m_currentConstraints; |
| 88 | 88 |
| 89 HeapHashSet<Member<ScriptPromiseResolver>> m_serviceRequests; | 89 HeapHashSet<Member<ScriptPromiseResolver>> m_serviceRequests; |
| 90 }; | 90 }; |
| 91 | 91 |
| 92 } // namespace blink | 92 } // namespace blink |
| 93 | 93 |
| 94 #endif // ImageCapture_h | 94 #endif // ImageCapture_h |
| OLD | NEW |