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

Side by Side Diff: cc/surfaces/display.cc

Issue 2349743004: cc: Remove things from OutputSurface and CompositorFrameSink. (Closed)
Patch Set: delete-stuff-cfs: comment-and-rebase Created 4 years, 3 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/direct_compositor_frame_sink.cc ('k') | cc/test/fake_compositor_frame_sink.h » ('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 #include "cc/surfaces/display.h" 5 #include "cc/surfaces/display.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "base/memory/ptr_util.h" 9 #include "base/memory/ptr_util.h"
10 #include "base/trace_event/trace_event.h" 10 #include "base/trace_event/trace_event.h"
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 161
162 if (aggregator_) { 162 if (aggregator_) {
163 aggregator_->set_output_is_secure(secure); 163 aggregator_->set_output_is_secure(secure);
164 // Force a redraw. 164 // Force a redraw.
165 if (!current_surface_id_.is_null()) 165 if (!current_surface_id_.is_null())
166 aggregator_->SetFullDamageForSurface(current_surface_id_); 166 aggregator_->SetFullDamageForSurface(current_surface_id_);
167 } 167 }
168 } 168 }
169 169
170 void Display::InitializeRenderer() { 170 void Display::InitializeRenderer() {
171 // Not relevant for display compositor since it's not delegated.
172 bool delegated_sync_points_required = false;
171 resource_provider_.reset(new ResourceProvider( 173 resource_provider_.reset(new ResourceProvider(
172 output_surface_->context_provider(), bitmap_manager_, 174 output_surface_->context_provider(), bitmap_manager_,
173 gpu_memory_buffer_manager_, nullptr, settings_.highp_threshold_min, 175 gpu_memory_buffer_manager_, nullptr, settings_.highp_threshold_min,
174 settings_.texture_id_allocation_chunk_size, 176 settings_.texture_id_allocation_chunk_size,
175 output_surface_->capabilities().delegated_sync_points_required, 177 delegated_sync_points_required, settings_.use_gpu_memory_buffer_resources,
176 settings_.use_gpu_memory_buffer_resources, false, 178 false, settings_.buffer_to_texture_target_map));
177 settings_.buffer_to_texture_target_map));
178 179
179 if (output_surface_->context_provider()) { 180 if (output_surface_->context_provider()) {
180 DCHECK(texture_mailbox_deleter_); 181 DCHECK(texture_mailbox_deleter_);
181 renderer_ = base::MakeUnique<GLRenderer>( 182 renderer_ = base::MakeUnique<GLRenderer>(
182 &settings_, output_surface_.get(), resource_provider_.get(), 183 &settings_, output_surface_.get(), resource_provider_.get(),
183 texture_mailbox_deleter_.get(), settings_.highp_threshold_min); 184 texture_mailbox_deleter_.get(), settings_.highp_threshold_min);
184 } else if (output_surface_->vulkan_context_provider()) { 185 } else if (output_surface_->vulkan_context_provider()) {
185 #if defined(ENABLE_VULKAN) 186 #if defined(ENABLE_VULKAN)
186 DCHECK(texture_mailbox_deleter_); 187 DCHECK(texture_mailbox_deleter_);
187 renderer_ = base::MakeUnique<VulkanRenderer>( 188 renderer_ = base::MakeUnique<VulkanRenderer>(
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
428 const SurfaceId& Display::CurrentSurfaceId() { 429 const SurfaceId& Display::CurrentSurfaceId() {
429 return current_surface_id_; 430 return current_surface_id_;
430 } 431 }
431 432
432 void Display::ForceImmediateDrawAndSwapIfPossible() { 433 void Display::ForceImmediateDrawAndSwapIfPossible() {
433 if (scheduler_) 434 if (scheduler_)
434 scheduler_->ForceImmediateSwapIfPossible(); 435 scheduler_->ForceImmediateSwapIfPossible();
435 } 436 }
436 437
437 } // namespace cc 438 } // namespace cc
OLDNEW
« no previous file with comments | « cc/surfaces/direct_compositor_frame_sink.cc ('k') | cc/test/fake_compositor_frame_sink.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698