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

Side by Side Diff: ui/gfx/compositor/compositor_gl.h

Issue 7770002: gfx::Compositor: SchedulePaint. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix aura, win compile Created 9 years, 3 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 UI_GFX_COMPOSITOR_COMPOSITOR_GL_H_ 5 #ifndef UI_GFX_COMPOSITOR_COMPOSITOR_GL_H_
6 #define UI_GFX_COMPOSITOR_COMPOSITOR_GL_H_ 6 #define UI_GFX_COMPOSITOR_COMPOSITOR_GL_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 86
87 unsigned int texture_id_; 87 unsigned int texture_id_;
88 gfx::Size size_; 88 gfx::Size size_;
89 89
90 private: 90 private:
91 DISALLOW_COPY_AND_ASSIGN(TextureGL); 91 DISALLOW_COPY_AND_ASSIGN(TextureGL);
92 }; 92 };
93 93
94 class COMPOSITOR_EXPORT CompositorGL : public Compositor { 94 class COMPOSITOR_EXPORT CompositorGL : public Compositor {
95 public: 95 public:
96 CompositorGL(gfx::AcceleratedWidget widget, const gfx::Size& size); 96 CompositorGL(CompositorDelegate* delegate,
97 gfx::AcceleratedWidget widget,
98 const gfx::Size& size);
97 virtual ~CompositorGL(); 99 virtual ~CompositorGL();
98 100
99 void MakeCurrent(); 101 void MakeCurrent();
100 gfx::Size GetSize(); 102 gfx::Size GetSize();
101 103
102 protected: 104 protected:
103 virtual void OnWidgetSizeChanged() OVERRIDE; 105 virtual void OnWidgetSizeChanged() OVERRIDE;
104 106
105 private: 107 private:
106 // Overridden from Compositor. 108 // Overridden from Compositor.
107 virtual Texture* CreateTexture() OVERRIDE; 109 virtual Texture* CreateTexture() OVERRIDE;
108 virtual void NotifyStart() OVERRIDE; 110 virtual void NotifyStart() OVERRIDE;
109 virtual void NotifyEnd() OVERRIDE; 111 virtual void NotifyEnd() OVERRIDE;
110 virtual void Blur(const gfx::Rect& bounds) OVERRIDE; 112 virtual void Blur(const gfx::Rect& bounds) OVERRIDE;
111 virtual void SchedulePaint() OVERRIDE; 113 virtual void SchedulePaint() OVERRIDE;
112 114
113 // The GL context used for compositing. 115 // The GL context used for compositing.
114 scoped_refptr<gfx::GLSurface> gl_surface_; 116 scoped_refptr<gfx::GLSurface> gl_surface_;
115 scoped_refptr<gfx::GLContext> gl_context_; 117 scoped_refptr<gfx::GLContext> gl_context_;
116 118
117 // Keep track of whether compositing has started or not. 119 // Keep track of whether compositing has started or not.
118 bool started_; 120 bool started_;
119 121
120 DISALLOW_COPY_AND_ASSIGN(CompositorGL); 122 DISALLOW_COPY_AND_ASSIGN(CompositorGL);
121 }; 123 };
122 124
123 } // namespace ui 125 } // namespace ui
124 126
125 #endif // UI_GFX_COMPOSITOR_COMPOSITOR_GL_H_ 127 #endif // UI_GFX_COMPOSITOR_COMPOSITOR_GL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698