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

Unified Diff: media/filters/video_frame_scheduler_impl.h

Issue 1111993002: Remove VideoFrameScheduler and dependents. (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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/filters/video_frame_scheduler.h ('k') | media/filters/video_frame_scheduler_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/video_frame_scheduler_impl.h
diff --git a/media/filters/video_frame_scheduler_impl.h b/media/filters/video_frame_scheduler_impl.h
deleted file mode 100644
index 6398969f2c063027a994cb0ebe5d4eae40abd97c..0000000000000000000000000000000000000000
--- a/media/filters/video_frame_scheduler_impl.h
+++ /dev/null
@@ -1,74 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef MEDIA_FILTERS_VIDEO_FRAME_SCHEDULER_IMPL_H_
-#define MEDIA_FILTERS_VIDEO_FRAME_SCHEDULER_IMPL_H_
-
-#include <queue>
-
-#include "base/memory/ref_counted.h"
-#include "base/timer/timer.h"
-#include "media/filters/video_frame_scheduler.h"
-
-namespace base {
-class SingleThreadTaskRunner;
-class TickClock;
-}
-
-namespace media {
-
-// A scheduler that uses delayed tasks on a task runner for timing the display
-// of video frames.
-//
-// Single threaded. Calls must be on |task_runner|.
-class MEDIA_EXPORT VideoFrameSchedulerImpl : public VideoFrameScheduler {
- public:
- typedef base::Callback<void(const scoped_refptr<VideoFrame>&)> DisplayCB;
-
- // |task_runner| is used for scheduling the delayed tasks.
- // |display_cb| is run when a frame is to be displayed.
- VideoFrameSchedulerImpl(
- const scoped_refptr<base::SingleThreadTaskRunner>& task_runner,
- const DisplayCB& display_cb);
- ~VideoFrameSchedulerImpl() override;
-
- // VideoFrameScheduler implementation.
- void ScheduleVideoFrame(const scoped_refptr<VideoFrame>& frame,
- base::TimeTicks wall_ticks,
- const DoneCB& done_cb) override;
- void Reset() override;
-
- void SetTickClockForTesting(scoped_ptr<base::TickClock> tick_clock);
-
- private:
- void ResetTimerIfNecessary();
- void OnTimerFired();
-
- scoped_refptr<base::SingleThreadTaskRunner> task_runner_;
- DisplayCB display_cb_;
- scoped_ptr<base::TickClock> tick_clock_;
- base::OneShotTimer<VideoFrameScheduler> timer_;
-
- struct PendingFrame {
- PendingFrame(const scoped_refptr<VideoFrame>& frame,
- base::TimeTicks wall_ticks,
- const DoneCB& done_cb);
- ~PendingFrame();
-
- // For use with std::priority_queue<T>.
- bool operator<(const PendingFrame& other) const;
-
- scoped_refptr<VideoFrame> frame;
- base::TimeTicks wall_ticks;
- DoneCB done_cb;
- };
- typedef std::priority_queue<PendingFrame> PendingFrameQueue;
- PendingFrameQueue pending_frames_;
-
- DISALLOW_COPY_AND_ASSIGN(VideoFrameSchedulerImpl);
-};
-
-} // namespace media
-
-#endif // MEDIA_FILTERS_VIDEO_FRAME_SCHEDULER_IMPL_H_
« no previous file with comments | « media/filters/video_frame_scheduler.h ('k') | media/filters/video_frame_scheduler_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698