| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_VIDEO_CAPTURER_SOURCE_H_ | 5 #ifndef MEDIA_BASE_VIDEO_CAPTURER_SOURCE_H_ |
| 6 #define MEDIA_BASE_VIDEO_CAPTURER_SOURCE_H_ | 6 #define MEDIA_BASE_VIDEO_CAPTURER_SOURCE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 // Asks source to send a refresh frame. In cases where source does not provide | 79 // Asks source to send a refresh frame. In cases where source does not provide |
| 80 // a continuous rate of new frames (e.g. canvas capture, screen capture where | 80 // a continuous rate of new frames (e.g. canvas capture, screen capture where |
| 81 // the screen's content has not changed in a while), consumers may request a | 81 // the screen's content has not changed in a while), consumers may request a |
| 82 // "refresh frame" to be delivered. For instance, this would be needed when | 82 // "refresh frame" to be delivered. For instance, this would be needed when |
| 83 // a new sink is added to a MediaStreamTrack. | 83 // a new sink is added to a MediaStreamTrack. |
| 84 // The default implementation is a no-op and implementations are not required | 84 // The default implementation is a no-op and implementations are not required |
| 85 // to honor this request. If they decide to and capturing is started | 85 // to honor this request. If they decide to and capturing is started |
| 86 // successfully, then |new_frame_callback| should be called with a frame. | 86 // successfully, then |new_frame_callback| should be called with a frame. |
| 87 virtual void RequestRefreshFrame() {} | 87 virtual void RequestRefreshFrame() {} |
| 88 | 88 |
| 89 // Notifies source the capturing link is secure. This is required by content |
| 90 // output protection. |
| 91 virtual void SetCapturingLinkSecured(bool is_secure) {} |
| 92 |
| 89 // Stops capturing frames and clears all callbacks including the | 93 // Stops capturing frames and clears all callbacks including the |
| 90 // SupportedFormatsCallback callback. Note that queued frame callbacks | 94 // SupportedFormatsCallback callback. Note that queued frame callbacks |
| 91 // may still occur after this call, so the caller must take care to | 95 // may still occur after this call, so the caller must take care to |
| 92 // use refcounted or weak references in |new_frame_callback|. | 96 // use refcounted or weak references in |new_frame_callback|. |
| 93 virtual void StopCapture() = 0; | 97 virtual void StopCapture() = 0; |
| 94 }; | 98 }; |
| 95 | 99 |
| 96 } // namespace media | 100 } // namespace media |
| 97 | 101 |
| 98 #endif // MEDIA_BASE_VIDEO_CAPTURER_SOURCE_H_ | 102 #endif // MEDIA_BASE_VIDEO_CAPTURER_SOURCE_H_ |
| OLD | NEW |