| Index: gpu/ipc/service/image_transport_surface_overlay_mac.h
|
| diff --git a/gpu/ipc/service/image_transport_surface_overlay_mac.h b/gpu/ipc/service/image_transport_surface_overlay_mac.h
|
| index 75264cb179b260863170654b71de4aae1e3733d9..d5c34d4787eda03d0cfa6c7c739762bff9f6c599 100644
|
| --- a/gpu/ipc/service/image_transport_surface_overlay_mac.h
|
| +++ b/gpu/ipc/service/image_transport_surface_overlay_mac.h
|
| @@ -66,6 +66,8 @@ class ImageTransportSurfaceOverlayMac : public gl::GLSurface,
|
| const gfx::Transform& transform,
|
| int sorting_context_id,
|
| unsigned filter) override;
|
| + void ScheduleCALayerInUseQuery(
|
| + std::vector<CALayerInUseQuery> queries) override;
|
| bool IsSurfaceless() const override;
|
|
|
| // ui::GpuSwitchingObserver implementation.
|
| @@ -98,6 +100,21 @@ class ImageTransportSurfaceOverlayMac : public gl::GLSurface,
|
| gfx::Size pixel_size_;
|
| float scale_factor_;
|
|
|
| + struct IOSurfaceInUseQuery {
|
| + IOSurfaceInUseQuery();
|
| + explicit IOSurfaceInUseQuery(const IOSurfaceInUseQuery&);
|
| + explicit IOSurfaceInUseQuery(IOSurfaceInUseQuery&&);
|
| + ~IOSurfaceInUseQuery();
|
| +
|
| + // It's possible that the client will have destroyed the texture before
|
| + // SwapBuffersInternal is called. It's important that |texture| is only used
|
| + // as an opaque identifier, since it may no longer point to the same
|
| + // texture.
|
| + unsigned texture = 0;
|
| + base::ScopedCFTypeRef<IOSurfaceRef> io_surface;
|
| + };
|
| + std::vector<IOSurfaceInUseQuery> io_surface_in_use_queries_;
|
| +
|
| // A GLFence marking the end of the previous frame. Must only be accessed
|
| // while in a ScopedSetGLToRealGLApi, and while the associated
|
| // |previous_frame_context_| is bound.
|
|
|