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

Side by Side Diff: cc/surfaces/surface_factory.h

Issue 2098953003: Make cc::CompositorFrames movable [Part 2 of 2] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed exo unittests Created 4 years, 5 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
« no previous file with comments | « cc/surfaces/surface_display_output_surface.cc ('k') | cc/surfaces/surface_factory.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 CC_SURFACES_SURFACE_FACTORY_H_ 5 #ifndef CC_SURFACES_SURFACE_FACTORY_H_
6 #define CC_SURFACES_SURFACE_FACTORY_H_ 6 #define CC_SURFACES_SURFACE_FACTORY_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <set> 9 #include <set>
10 #include <unordered_map> 10 #include <unordered_map>
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 55
56 // Set the GpuMemoryBuffer client id for resources coming from a surface. 56 // Set the GpuMemoryBuffer client id for resources coming from a surface.
57 void SetSurfaceGpuMemoryBufferClientId(SurfaceId surface_id, 57 void SetSurfaceGpuMemoryBufferClientId(SurfaceId surface_id,
58 int gpu_memory_buffer_client_id); 58 int gpu_memory_buffer_client_id);
59 59
60 // A frame can only be submitted to a surface created by this factory, 60 // A frame can only be submitted to a surface created by this factory,
61 // although the frame may reference surfaces created by other factories. 61 // although the frame may reference surfaces created by other factories.
62 // The callback is called the first time this frame is used to draw, or if 62 // The callback is called the first time this frame is used to draw, or if
63 // the frame is discarded. 63 // the frame is discarded.
64 void SubmitCompositorFrame(SurfaceId surface_id, 64 void SubmitCompositorFrame(SurfaceId surface_id,
65 std::unique_ptr<CompositorFrame> frame, 65 CompositorFrame frame,
66 const DrawCallback& callback); 66 const DrawCallback& callback);
67 void RequestCopyOfSurface(SurfaceId surface_id, 67 void RequestCopyOfSurface(SurfaceId surface_id,
68 std::unique_ptr<CopyOutputRequest> copy_request); 68 std::unique_ptr<CopyOutputRequest> copy_request);
69 69
70 void WillDrawSurface(SurfaceId id, const gfx::Rect& damage_rect); 70 void WillDrawSurface(SurfaceId id, const gfx::Rect& damage_rect);
71 71
72 SurfaceFactoryClient* client() { return client_; } 72 SurfaceFactoryClient* client() { return client_; }
73 73
74 void ReceiveFromChild(const TransferableResourceArray& resources); 74 void ReceiveFromChild(const TransferableResourceArray& resources);
75 void RefResources(const TransferableResourceArray& resources); 75 void RefResources(const TransferableResourceArray& resources);
(...skipping 21 matching lines...) Expand all
97 using OwningSurfaceMap = 97 using OwningSurfaceMap =
98 std::unordered_map<SurfaceId, std::unique_ptr<Surface>, SurfaceIdHash>; 98 std::unordered_map<SurfaceId, std::unique_ptr<Surface>, SurfaceIdHash>;
99 OwningSurfaceMap surface_map_; 99 OwningSurfaceMap surface_map_;
100 100
101 DISALLOW_COPY_AND_ASSIGN(SurfaceFactory); 101 DISALLOW_COPY_AND_ASSIGN(SurfaceFactory);
102 }; 102 };
103 103
104 } // namespace cc 104 } // namespace cc
105 105
106 #endif // CC_SURFACES_SURFACE_FACTORY_H_ 106 #endif // CC_SURFACES_SURFACE_FACTORY_H_
OLDNEW
« no previous file with comments | « cc/surfaces/surface_display_output_surface.cc ('k') | cc/surfaces/surface_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698