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

Side by Side Diff: ui/views/mus/surface_context_factory.h

Issue 2337913003: Fork cc::OutputSurface into cc::CompositorFrameSink. (Closed)
Patch Set: cfsfork: android-vulkan Created 4 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_VIEWS_MUS_SURFACE_CONTEXT_FACTORY_H_ 5 #ifndef UI_VIEWS_MUS_SURFACE_CONTEXT_FACTORY_H_
6 #define UI_VIEWS_MUS_SURFACE_CONTEXT_FACTORY_H_ 6 #define UI_VIEWS_MUS_SURFACE_CONTEXT_FACTORY_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "cc/surfaces/surface_manager.h" 11 #include "cc/surfaces/surface_manager.h"
12 #include "services/ui/public/cpp/raster_thread_helper.h" 12 #include "services/ui/public/cpp/raster_thread_helper.h"
13 #include "services/ui/public/interfaces/window_tree.mojom.h" 13 #include "services/ui/public/interfaces/window_tree.mojom.h"
14 #include "ui/compositor/compositor.h" 14 #include "ui/compositor/compositor.h"
15 #include "ui/views/mus/mus_export.h" 15 #include "ui/views/mus/mus_export.h"
16 16
17 namespace ui { 17 namespace ui {
18 class GpuService; 18 class GpuService;
19 } 19 }
20 20
21 namespace views { 21 namespace views {
22 22
23 class VIEWS_MUS_EXPORT SurfaceContextFactory : public ui::ContextFactory { 23 class VIEWS_MUS_EXPORT SurfaceContextFactory : public ui::ContextFactory {
24 public: 24 public:
25 explicit SurfaceContextFactory(ui::GpuService* gpu_service); 25 explicit SurfaceContextFactory(ui::GpuService* gpu_service);
26 ~SurfaceContextFactory() override; 26 ~SurfaceContextFactory() override;
27 27
28 private: 28 private:
29 // ContextFactory: 29 // ContextFactory:
30 void CreateOutputSurface(base::WeakPtr<ui::Compositor> compositor) override; 30 void CreateCompositorFrameSink(
31 base::WeakPtr<ui::Compositor> compositor) override;
31 std::unique_ptr<ui::Reflector> CreateReflector( 32 std::unique_ptr<ui::Reflector> CreateReflector(
32 ui::Compositor* mirrored_compositor, 33 ui::Compositor* mirrored_compositor,
33 ui::Layer* mirroring_layer) override; 34 ui::Layer* mirroring_layer) override;
34 void RemoveReflector(ui::Reflector* reflector) override; 35 void RemoveReflector(ui::Reflector* reflector) override;
35 scoped_refptr<cc::ContextProvider> SharedMainThreadContextProvider() override; 36 scoped_refptr<cc::ContextProvider> SharedMainThreadContextProvider() override;
36 void RemoveCompositor(ui::Compositor* compositor) override; 37 void RemoveCompositor(ui::Compositor* compositor) override;
37 bool DoesCreateTestContexts() override; 38 bool DoesCreateTestContexts() override;
38 uint32_t GetImageTextureTarget(gfx::BufferFormat format, 39 uint32_t GetImageTextureTarget(gfx::BufferFormat format,
39 gfx::BufferUsage usage) override; 40 gfx::BufferUsage usage) override;
40 cc::SharedBitmapManager* GetSharedBitmapManager() override; 41 cc::SharedBitmapManager* GetSharedBitmapManager() override;
(...skipping 19 matching lines...) Expand all
60 uint32_t next_surface_id_namespace_; 61 uint32_t next_surface_id_namespace_;
61 ui::RasterThreadHelper raster_thread_helper_; 62 ui::RasterThreadHelper raster_thread_helper_;
62 ui::GpuService* gpu_service_; 63 ui::GpuService* gpu_service_;
63 64
64 DISALLOW_COPY_AND_ASSIGN(SurfaceContextFactory); 65 DISALLOW_COPY_AND_ASSIGN(SurfaceContextFactory);
65 }; 66 };
66 67
67 } // namespace views 68 } // namespace views
68 69
69 #endif // UI_VIEWS_MUS_SURFACE_CONTEXT_FACTORY_H_ 70 #endif // UI_VIEWS_MUS_SURFACE_CONTEXT_FACTORY_H_
OLDNEW
« no previous file with comments | « ui/compositor/test/in_process_context_factory.cc ('k') | ui/views/mus/surface_context_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698