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

Side by Side Diff: content/renderer/gpu/compositor_output_surface.h

Issue 889063002: (not for commit) Create 2nd ContextProvider for Ganesh rasterization. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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 (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_RENDERER_GPU_COMPOSITOR_OUTPUT_SURFACE_H_ 5 #ifndef CONTENT_RENDERER_GPU_COMPOSITOR_OUTPUT_SURFACE_H_
6 #define CONTENT_RENDERER_GPU_COMPOSITOR_OUTPUT_SURFACE_H_ 6 #define CONTENT_RENDERER_GPU_COMPOSITOR_OUTPUT_SURFACE_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 25 matching lines...) Expand all
36 // This class can be created only on the main thread, but then becomes pinned 36 // This class can be created only on the main thread, but then becomes pinned
37 // to a fixed thread when bindToClient is called. 37 // to a fixed thread when bindToClient is called.
38 class CompositorOutputSurface 38 class CompositorOutputSurface
39 : NON_EXPORTED_BASE(public cc::OutputSurface), 39 : NON_EXPORTED_BASE(public cc::OutputSurface),
40 NON_EXPORTED_BASE(public base::NonThreadSafe) { 40 NON_EXPORTED_BASE(public base::NonThreadSafe) {
41 public: 41 public:
42 CompositorOutputSurface( 42 CompositorOutputSurface(
43 int32 routing_id, 43 int32 routing_id,
44 uint32 output_surface_id, 44 uint32 output_surface_id,
45 const scoped_refptr<ContextProviderCommandBuffer>& context_provider, 45 const scoped_refptr<ContextProviderCommandBuffer>& context_provider,
46 const scoped_refptr<ContextProviderCommandBuffer>&
47 worker_context_provider,
46 scoped_ptr<cc::SoftwareOutputDevice> software, 48 scoped_ptr<cc::SoftwareOutputDevice> software,
47 scoped_refptr<FrameSwapMessageQueue> swap_frame_message_queue, 49 scoped_refptr<FrameSwapMessageQueue> swap_frame_message_queue,
48 bool use_swap_compositor_frame_message); 50 bool use_swap_compositor_frame_message);
49 ~CompositorOutputSurface() override; 51 ~CompositorOutputSurface() override;
50 52
51 // cc::OutputSurface implementation. 53 // cc::OutputSurface implementation.
52 bool BindToClient(cc::OutputSurfaceClient* client) override; 54 bool BindToClient(cc::OutputSurfaceClient* client) override;
53 void SwapBuffers(cc::CompositorFrame* frame) override; 55 void SwapBuffers(cc::CompositorFrame* frame) override;
54 56
55 // TODO(epenner): This seems out of place here and would be a better fit 57 // TODO(epenner): This seems out of place here and would be a better fit
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 void OnMessageReceived(const IPC::Message& message); 92 void OnMessageReceived(const IPC::Message& message);
91 void OnUpdateVSyncParametersFromBrowser(base::TimeTicks timebase, 93 void OnUpdateVSyncParametersFromBrowser(base::TimeTicks timebase,
92 base::TimeDelta interval); 94 base::TimeDelta interval);
93 bool Send(IPC::Message* message); 95 bool Send(IPC::Message* message);
94 96
95 bool use_swap_compositor_frame_message_; 97 bool use_swap_compositor_frame_message_;
96 98
97 scoped_refptr<CompositorForwardingMessageFilter> output_surface_filter_; 99 scoped_refptr<CompositorForwardingMessageFilter> output_surface_filter_;
98 CompositorForwardingMessageFilter::Handler output_surface_filter_handler_; 100 CompositorForwardingMessageFilter::Handler output_surface_filter_handler_;
99 scoped_refptr<CompositorOutputSurfaceProxy> output_surface_proxy_; 101 scoped_refptr<CompositorOutputSurfaceProxy> output_surface_proxy_;
102 scoped_refptr<cc::ContextProvider> worker_context_provider_;
100 scoped_refptr<IPC::SyncMessageFilter> message_sender_; 103 scoped_refptr<IPC::SyncMessageFilter> message_sender_;
101 scoped_refptr<FrameSwapMessageQueue> frame_swap_message_queue_; 104 scoped_refptr<FrameSwapMessageQueue> frame_swap_message_queue_;
102 int routing_id_; 105 int routing_id_;
103 bool prefers_smoothness_; 106 bool prefers_smoothness_;
104 base::PlatformThreadHandle main_thread_handle_; 107 base::PlatformThreadHandle main_thread_handle_;
105 108
106 // TODO(danakj): Remove this when crbug.com/311404 109 // TODO(danakj): Remove this when crbug.com/311404
107 bool layout_test_mode_; 110 bool layout_test_mode_;
108 scoped_ptr<cc::CompositorFrameAck> layout_test_previous_frame_ack_; 111 scoped_ptr<cc::CompositorFrameAck> layout_test_previous_frame_ack_;
109 base::WeakPtrFactory<CompositorOutputSurface> weak_ptrs_; 112 base::WeakPtrFactory<CompositorOutputSurface> weak_ptrs_;
110 }; 113 };
111 114
112 } // namespace content 115 } // namespace content
113 116
114 #endif // CONTENT_RENDERER_GPU_COMPOSITOR_OUTPUT_SURFACE_H_ 117 #endif // CONTENT_RENDERER_GPU_COMPOSITOR_OUTPUT_SURFACE_H_
OLDNEW
« no previous file with comments | « content/common/gpu/client/context_provider_command_buffer.cc ('k') | content/renderer/gpu/compositor_output_surface.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698