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

Side by Side Diff: content/browser/compositor/onscreen_display_client.h

Issue 303113007: Add software renderer support for surfaces. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CONTENT_BROWSER_COMPOSITOR_ONSCREEN_DISPLAY_CLIENT_H_ 5 #ifndef CONTENT_BROWSER_COMPOSITOR_ONSCREEN_DISPLAY_CLIENT_H_
6 #define CONTENT_BROWSER_COMPOSITOR_ONSCREEN_DISPLAY_CLIENT_H_ 6 #define CONTENT_BROWSER_COMPOSITOR_ONSCREEN_DISPLAY_CLIENT_H_
7 7
8 #include "cc/surfaces/display_client.h" 8 #include "cc/surfaces/display_client.h"
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
11 #include "base/memory/scoped_ptr.h" 11 #include "base/memory/scoped_ptr.h"
12 #include "cc/surfaces/display.h" 12 #include "cc/surfaces/display.h"
13 13
14 namespace cc { 14 namespace cc {
15 class ContextProvider; 15 class ContextProvider;
16 class SurfaceManager; 16 class SurfaceManager;
17 } 17 }
18 18
19 namespace content { 19 namespace content {
20 20
21 // This class provides a DisplayClient implementation for drawing directly to an 21 // This class provides a DisplayClient implementation for drawing directly to an
22 // onscreen context. 22 // onscreen context.
23 class OnscreenDisplayClient : cc::DisplayClient { 23 class OnscreenDisplayClient : cc::DisplayClient {
24 public: 24 public:
25 OnscreenDisplayClient( 25 OnscreenDisplayClient(
26 const scoped_refptr<cc::ContextProvider>& onscreen_context_provider, 26 const scoped_refptr<cc::ContextProvider>& onscreen_context_provider,
27 scoped_ptr<cc::OutputSurface> software_surface,
27 cc::SurfaceManager* manager); 28 cc::SurfaceManager* manager);
28 virtual ~OnscreenDisplayClient(); 29 virtual ~OnscreenDisplayClient();
29 30
30 cc::Display* display() { return &display_; } 31 cc::Display* display() { return &display_; }
31 32
32 // cc::DisplayClient implementation. 33 // cc::DisplayClient implementation.
33 virtual scoped_ptr<cc::OutputSurface> CreateOutputSurface() OVERRIDE; 34 virtual scoped_ptr<cc::OutputSurface> CreateOutputSurface() OVERRIDE;
34 35
35 private: 36 private:
36 scoped_refptr<cc::ContextProvider> onscreen_context_provider_; 37 scoped_refptr<cc::ContextProvider> onscreen_context_provider_;
38 scoped_ptr<cc::OutputSurface> software_surface_;
37 cc::Display display_; 39 cc::Display display_;
38 40
39 DISALLOW_COPY_AND_ASSIGN(OnscreenDisplayClient); 41 DISALLOW_COPY_AND_ASSIGN(OnscreenDisplayClient);
40 }; 42 };
41 43
42 } // namespace content 44 } // namespace content
43 45
44 #endif // CONTENT_BROWSER_COMPOSITOR_ONSCREEN_DISPLAY_CLIENT_H_ 46 #endif // CONTENT_BROWSER_COMPOSITOR_ONSCREEN_DISPLAY_CLIENT_H_
OLDNEW
« no previous file with comments | « content/browser/compositor/gpu_process_transport_factory.cc ('k') | content/browser/compositor/onscreen_display_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698