| Index: webrtc/api/videotrack.cc
|
| diff --git a/webrtc/api/videotrack.cc b/webrtc/api/videotrack.cc
|
| index b47a32044f33d4ee7f0e52bf41016076a5fb4b3b..2fa2ba671a8724b3f8a6fff3fa5b1015b2a15bf2 100644
|
| --- a/webrtc/api/videotrack.cc
|
| +++ b/webrtc/api/videotrack.cc
|
| @@ -19,7 +19,8 @@ const char MediaStreamTrackInterface::kVideoKind[] = "video";
|
| VideoTrack::VideoTrack(const std::string& label,
|
| VideoTrackSourceInterface* video_source)
|
| : MediaStreamTrack<VideoTrackInterface>(label),
|
| - video_source_(video_source) {
|
| + video_source_(video_source),
|
| + content_hint_(ContentHint::kNone) {
|
| worker_thread_checker_.DetachFromThread();
|
| video_source_->RegisterObserver(this);
|
| }
|
| @@ -49,6 +50,19 @@ void VideoTrack::RemoveSink(rtc::VideoSinkInterface<VideoFrame>* sink) {
|
| video_source_->RemoveSink(sink);
|
| }
|
|
|
| +VideoTrackInterface::ContentHint VideoTrack::content_hint() const {
|
| + RTC_DCHECK_RUN_ON(&signaling_thread_checker_);
|
| + return content_hint_;
|
| +}
|
| +
|
| +void VideoTrack::set_content_hint(ContentHint hint) {
|
| + RTC_DCHECK_RUN_ON(&signaling_thread_checker_);
|
| + if (content_hint_ == hint)
|
| + return;
|
| + content_hint_ = hint;
|
| + Notifier<VideoTrackInterface>::FireOnChanged();
|
| +}
|
| +
|
| bool VideoTrack::set_enabled(bool enable) {
|
| RTC_DCHECK(signaling_thread_checker_.CalledOnValidThread());
|
| for (auto& sink_pair : sink_pairs()) {
|
|
|