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

Side by Side Diff: content/browser/gpu/gpu_surface_tracker.h

Issue 1998723002: Move code in ui/gl/* from gfx:: to gl:: (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 7 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 | « content/browser/gpu/gpu_process_host.cc ('k') | content/browser/gpu/gpu_surface_tracker.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_GPU_GPU_SURFACE_TRACKER_H_ 5 #ifndef CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_
6 #define CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_ 6 #define CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 21 matching lines...) Expand all
32 // This class is thread safe. 32 // This class is thread safe.
33 class CONTENT_EXPORT GpuSurfaceTracker : public gpu::GpuSurfaceLookup { 33 class CONTENT_EXPORT GpuSurfaceTracker : public gpu::GpuSurfaceLookup {
34 public: 34 public:
35 // GpuSurfaceLookup implementation: 35 // GpuSurfaceLookup implementation:
36 // Returns the native widget associated with a given surface_handle. 36 // Returns the native widget associated with a given surface_handle.
37 // On Android, this adds a reference on the ANativeWindow. 37 // On Android, this adds a reference on the ANativeWindow.
38 gfx::AcceleratedWidget AcquireNativeWidget( 38 gfx::AcceleratedWidget AcquireNativeWidget(
39 gpu::SurfaceHandle surface_handle) override; 39 gpu::SurfaceHandle surface_handle) override;
40 40
41 #if defined(OS_ANDROID) 41 #if defined(OS_ANDROID)
42 gfx::ScopedJavaSurface AcquireJavaSurface(int surface_id) override; 42 gl::ScopedJavaSurface AcquireJavaSurface(int surface_id) override;
43 #endif 43 #endif
44 44
45 // Gets the global instance of the surface tracker. 45 // Gets the global instance of the surface tracker.
46 static GpuSurfaceTracker* Get() { return GetInstance(); } 46 static GpuSurfaceTracker* Get() { return GetInstance(); }
47 47
48 // Adds a surface for a native widget. Returns the surface ID. 48 // Adds a surface for a native widget. Returns the surface ID.
49 int AddSurfaceForNativeWidget(gfx::AcceleratedWidget widget); 49 int AddSurfaceForNativeWidget(gfx::AcceleratedWidget widget);
50 50
51 // Removes a given existing surface. 51 // Removes a given existing surface.
52 void RemoveSurface(gpu::SurfaceHandle surface_handle); 52 void RemoveSurface(gpu::SurfaceHandle surface_handle);
(...skipping 16 matching lines...) Expand all
69 base::Lock lock_; 69 base::Lock lock_;
70 SurfaceMap surface_map_; 70 SurfaceMap surface_map_;
71 int next_surface_handle_; 71 int next_surface_handle_;
72 72
73 DISALLOW_COPY_AND_ASSIGN(GpuSurfaceTracker); 73 DISALLOW_COPY_AND_ASSIGN(GpuSurfaceTracker);
74 }; 74 };
75 75
76 } // namespace content 76 } // namespace content
77 77
78 #endif // CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_ 78 #endif // CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_
OLDNEW
« no previous file with comments | « content/browser/gpu/gpu_process_host.cc ('k') | content/browser/gpu/gpu_surface_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698