Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(128)

Side by Side Diff: media/renderers/video_renderer_impl.h

Issue 1068593003: Introduce TimeSource notifications to the VideoRenderer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_RENDERERS_VIDEO_RENDERER_IMPL_H_ 5 #ifndef MEDIA_RENDERERS_VIDEO_RENDERER_IMPL_H_
6 #define MEDIA_RENDERERS_VIDEO_RENDERER_IMPL_H_ 6 #define MEDIA_RENDERERS_VIDEO_RENDERER_IMPL_H_
7 7
8 #include <deque> 8 #include <deque>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 const WallClockTimeCB& wall_clock_time_cb, 64 const WallClockTimeCB& wall_clock_time_cb,
65 const base::Closure& waiting_for_decryption_key_cb) override; 65 const base::Closure& waiting_for_decryption_key_cb) override;
66 void Flush(const base::Closure& callback) override; 66 void Flush(const base::Closure& callback) override;
67 void StartPlayingFrom(base::TimeDelta timestamp) override; 67 void StartPlayingFrom(base::TimeDelta timestamp) override;
68 68
69 // PlatformThread::Delegate implementation. 69 // PlatformThread::Delegate implementation.
70 void ThreadMain() override; 70 void ThreadMain() override;
71 71
72 void SetTickClockForTesting(scoped_ptr<base::TickClock> tick_clock); 72 void SetTickClockForTesting(scoped_ptr<base::TickClock> tick_clock);
73 73
74 // TimeSourceDependent implementation.
75 void OnTimeProgressing() override;
76 void OnTimeStopped() override;
77
74 private: 78 private:
75 // Creates a dedicated |thread_| for video rendering. 79 // Creates a dedicated |thread_| for video rendering.
76 void CreateVideoThread(); 80 void CreateVideoThread();
77 81
78 // Callback for |video_frame_stream_| initialization. 82 // Callback for |video_frame_stream_| initialization.
79 void OnVideoFrameStreamInitialized(bool success); 83 void OnVideoFrameStreamInitialized(bool success);
80 84
81 // Callback for |video_frame_stream_| to deliver decoded video frames and 85 // Callback for |video_frame_stream_| to deliver decoded video frames and
82 // report video decoding status. 86 // report video decoding status.
83 void FrameReady(VideoFrameStream::Status status, 87 void FrameReady(VideoFrameStream::Status status,
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 215
212 // NOTE: Weak pointers must be invalidated before all other member variables. 216 // NOTE: Weak pointers must be invalidated before all other member variables.
213 base::WeakPtrFactory<VideoRendererImpl> weak_factory_; 217 base::WeakPtrFactory<VideoRendererImpl> weak_factory_;
214 218
215 DISALLOW_COPY_AND_ASSIGN(VideoRendererImpl); 219 DISALLOW_COPY_AND_ASSIGN(VideoRendererImpl);
216 }; 220 };
217 221
218 } // namespace media 222 } // namespace media
219 223
220 #endif // MEDIA_RENDERERS_VIDEO_RENDERER_IMPL_H_ 224 #endif // MEDIA_RENDERERS_VIDEO_RENDERER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698