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

Unified Diff: content/browser/renderer_host/compositor_impl_android.cc

Issue 2971083002: gpu: Reduce direct use of BrowserGpuMemoryBufferManager (Closed)
Patch Set: . Created 3 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/gpu/gpu_internals_ui.cc ('k') | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/compositor_impl_android.cc
diff --git a/content/browser/renderer_host/compositor_impl_android.cc b/content/browser/renderer_host/compositor_impl_android.cc
index 9f9fd0129e97532e91540be74261b870fc13286c..afbf62a337011ac03b2a1c75cfb588144667efe1 100644
--- a/content/browser/renderer_host/compositor_impl_android.cc
+++ b/content/browser/renderer_host/compositor_impl_android.cc
@@ -53,7 +53,6 @@
#include "components/viz/service/frame_sinks/frame_sink_manager_impl.h"
#include "content/browser/browser_main_loop.h"
#include "content/browser/compositor/surface_utils.h"
-#include "content/browser/gpu/browser_gpu_memory_buffer_manager.h"
#include "content/browser/gpu/compositor_util.h"
#include "content/browser/renderer_host/render_widget_host_impl.h"
#include "content/common/gpu_stream_constants.h"
@@ -806,10 +805,13 @@ void CompositorImpl::InitializeDisplay(
renderer_settings.highp_threshold_min = 2048;
renderer_settings.enable_color_correct_rendering =
base::FeatureList::IsEnabled(features::kColorCorrectRendering);
+ auto* gpu_memory_buffer_manager = BrowserMainLoop::GetInstance()
+ ->gpu_channel_establish_factory()
+ ->GetGpuMemoryBufferManager();
display_.reset(new cc::Display(
- viz::ServerSharedBitmapManager::current(),
- BrowserGpuMemoryBufferManager::current(), renderer_settings,
- frame_sink_id_, std::move(display_output_surface), std::move(scheduler),
+ viz::ServerSharedBitmapManager::current(), gpu_memory_buffer_manager,
+ renderer_settings, frame_sink_id_, std::move(display_output_surface),
+ std::move(scheduler),
base::MakeUnique<cc::TextureMailboxDeleter>(task_runner)));
auto layer_tree_frame_sink =
@@ -819,7 +821,8 @@ void CompositorImpl::InitializeDisplay(
vulkan_context_provider)
: base::MakeUnique<cc::DirectLayerTreeFrameSink>(
frame_sink_id_, manager, display_.get(), context_provider,
- nullptr, BrowserGpuMemoryBufferManager::current(),
+ nullptr /* worker_context_provider */,
+ gpu_memory_buffer_manager,
viz::ServerSharedBitmapManager::current());
display_->SetVisible(true);
« no previous file with comments | « content/browser/gpu/gpu_internals_ui.cc ('k') | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698