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

Side by Side Diff: media/tools/shader_bench/painter.h

Issue 4873002: Benchmark tool for GPU-accelerated video rendering (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Style fixes, added comments to headers Created 10 years 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef MEDIA_TOOLS_BENCHMARK_PAINTER_H_
scherkus (not reviewing) 2010/11/30 23:36:10 header guard should be MEDIA_TOOLS_SHADER_BENCH_PA
vrk (LEFT CHROMIUM) 2010/12/01 02:46:11 Done.
6 #define MEDIA_TOOLS_BENCHMARK_PAINTER_H_
7
8 #include <deque>
9
10 #include "base/scoped_ptr.h"
11 #include "media/base/video_frame.h"
12
13 // Class that paints video frames to a window.
14 class Painter {
15 public:
16 Painter();
17
scherkus (not reviewing) 2010/11/30 23:36:10 where's the destructor?
vrk (LEFT CHROMIUM) 2010/12/01 02:46:11 Oops! Added.
18 // Loads frames into Painter. Painter does not take ownership of frames.
19 virtual void LoadFrames(
20 std::deque<scoped_refptr<media::VideoFrame> >* frames);
21
22 // Called window is ready to be painted.
23 virtual void OnPaint();
24
25 // Initialize a Painter class with a width and a height
26 virtual void Initialize(int width, int height) = 0;
27
28 // Paint a single frame to a window.
29 virtual void Paint(scoped_refptr<media::VideoFrame> video_frame) = 0;
30
31 protected:
32 // Frames that the Painter will paint.
33 std::deque<scoped_refptr<media::VideoFrame> >* frames_;
34
35 private:
36 DISALLOW_COPY_AND_ASSIGN(Painter);
37 };
38
39 #endif // MEDIA_TOOLS_BENCHMARK_PAINTER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698