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

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

Issue 792383004: Run draw callback immediately if no Display is damaged. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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_manager.cc ('k') | content/browser/compositor/delegated_frame_host.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 CONTENT_BROWSER_COMPOSITOR_DELEGATED_FRAME_HOST_H_ 5 #ifndef CONTENT_BROWSER_COMPOSITOR_DELEGATED_FRAME_HOST_H_
6 #define CONTENT_BROWSER_COMPOSITOR_DELEGATED_FRAME_HOST_H_ 6 #define CONTENT_BROWSER_COMPOSITOR_DELEGATED_FRAME_HOST_H_
7 7
8 #include "cc/layers/delegated_frame_provider.h" 8 #include "cc/layers/delegated_frame_provider.h"
9 #include "cc/layers/delegated_frame_resource_collection.h" 9 #include "cc/layers/delegated_frame_resource_collection.h"
10 #include "cc/output/copy_output_result.h" 10 #include "cc/output/copy_output_result.h"
11 #include "cc/surfaces/surface_factory_client.h" 11 #include "cc/surfaces/surface_factory_client.h"
12 #include "content/browser/compositor/image_transport_factory.h" 12 #include "content/browser/compositor/image_transport_factory.h"
13 #include "content/browser/compositor/owned_mailbox.h" 13 #include "content/browser/compositor/owned_mailbox.h"
14 #include "content/browser/renderer_host/delegated_frame_evictor.h" 14 #include "content/browser/renderer_host/delegated_frame_evictor.h"
15 #include "content/browser/renderer_host/dip_util.h" 15 #include "content/browser/renderer_host/dip_util.h"
16 #include "content/browser/renderer_host/render_widget_host_impl.h" 16 #include "content/browser/renderer_host/render_widget_host_impl.h"
17 #include "content/browser/renderer_host/render_widget_host_view_base.h" 17 #include "content/browser/renderer_host/render_widget_host_view_base.h"
18 #include "content/public/browser/render_process_host.h" 18 #include "content/public/browser/render_process_host.h"
19 #include "ui/compositor/compositor.h" 19 #include "ui/compositor/compositor.h"
20 #include "ui/compositor/compositor_observer.h" 20 #include "ui/compositor/compositor_observer.h"
21 #include "ui/compositor/compositor_vsync_manager.h" 21 #include "ui/compositor/compositor_vsync_manager.h"
22 #include "ui/compositor/layer.h" 22 #include "ui/compositor/layer.h"
23 #include "ui/compositor/layer_owner_delegate.h" 23 #include "ui/compositor/layer_owner_delegate.h"
24 #include "ui/gfx/geometry/rect_conversions.h" 24 #include "ui/gfx/geometry/rect_conversions.h"
25 25
26 namespace cc { 26 namespace cc {
27 class SurfaceFactory; 27 class SurfaceFactory;
28 enum class SurfaceDrawStatus;
28 } 29 }
29 30
30 namespace media { 31 namespace media {
31 class VideoFrame; 32 class VideoFrame;
32 } 33 }
33 34
34 namespace content { 35 namespace content {
35 36
36 class DelegatedFrameHost; 37 class DelegatedFrameHost;
37 class ReadbackYUVInterface; 38 class ReadbackYUVInterface;
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
205 const base::Callback<void(bool)>& callback, 206 const base::Callback<void(bool)>& callback,
206 scoped_refptr<OwnedMailbox> subscriber_texture, 207 scoped_refptr<OwnedMailbox> subscriber_texture,
207 scoped_ptr<cc::SingleReleaseCallback> release_callback, 208 scoped_ptr<cc::SingleReleaseCallback> release_callback,
208 bool result); 209 bool result);
209 static void ReturnSubscriberTexture( 210 static void ReturnSubscriberTexture(
210 base::WeakPtr<DelegatedFrameHost> rwhva, 211 base::WeakPtr<DelegatedFrameHost> rwhva,
211 scoped_refptr<OwnedMailbox> subscriber_texture, 212 scoped_refptr<OwnedMailbox> subscriber_texture,
212 uint32 sync_point); 213 uint32 sync_point);
213 214
214 void SendDelegatedFrameAck(uint32 output_surface_id); 215 void SendDelegatedFrameAck(uint32 output_surface_id);
215 void SurfaceDrawn(uint32 output_surface_id, bool drawn); 216 void SurfaceDrawn(uint32 output_surface_id, cc::SurfaceDrawStatus drawn);
216 void SendReturnedDelegatedResources(uint32 output_surface_id); 217 void SendReturnedDelegatedResources(uint32 output_surface_id);
217 218
218 // DelegatedFrameEvictorClient implementation. 219 // DelegatedFrameEvictorClient implementation.
219 void EvictDelegatedFrame() override; 220 void EvictDelegatedFrame() override;
220 221
221 // cc::DelegatedFrameProviderClient implementation. 222 // cc::DelegatedFrameProviderClient implementation.
222 void UnusedResourcesAreAvailable() override; 223 void UnusedResourcesAreAvailable() override;
223 224
224 // cc::SurfaceFactoryClient implementation. 225 // cc::SurfaceFactoryClient implementation.
225 void ReturnResources(const cc::ReturnedResourceArray& resources) override; 226 void ReturnResources(const cc::ReturnedResourceArray& resources) override;
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 // YUV readback pipeline. 309 // YUV readback pipeline.
309 scoped_ptr<content::ReadbackYUVInterface> 310 scoped_ptr<content::ReadbackYUVInterface>
310 yuv_readback_pipeline_; 311 yuv_readback_pipeline_;
311 312
312 scoped_ptr<DelegatedFrameEvictor> delegated_frame_evictor_; 313 scoped_ptr<DelegatedFrameEvictor> delegated_frame_evictor_;
313 }; 314 };
314 315
315 } // namespace content 316 } // namespace content
316 317
317 #endif // CONTENT_BROWSER_COMPOSITOR_DELEGATED_FRAME_HOST_H_ 318 #endif // CONTENT_BROWSER_COMPOSITOR_DELEGATED_FRAME_HOST_H_
OLDNEW
« no previous file with comments | « cc/surfaces/surface_manager.cc ('k') | content/browser/compositor/delegated_frame_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698