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

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

Issue 2744973002: Remove enable_vulkan from build/config, and move it to the buildflag_header system. (Closed)
Patch Set: awww year Created 3 years, 9 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/renderer_host/compositor_impl_android.h ('k') | content/gpu/BUILD.gn » ('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 032239f506d355024d1abcbbaaac0c30bc45ea85..0ed2a5c70df2cf2097880db42353602028af749e 100644
--- a/content/browser/renderer_host/compositor_impl_android.cc
+++ b/content/browser/renderer_host/compositor_impl_android.cc
@@ -61,6 +61,7 @@
#include "gpu/ipc/client/command_buffer_proxy_impl.h"
#include "gpu/ipc/client/gpu_channel_host.h"
#include "gpu/ipc/common/gpu_surface_tracker.h"
+#include "gpu/vulkan/features.h"
#include "gpu/vulkan/vulkan_surface.h"
#include "services/ui/public/cpp/gpu/context_provider_command_buffer.h"
#include "third_party/khronos/GLES2/gl2.h"
@@ -99,7 +100,7 @@ struct CompositorDependencies {
cc::SurfaceManager surface_manager;
cc::FrameSinkIdAllocator frame_sink_id_allocator;
-#if defined(ENABLE_VULKAN)
+#if BUILDFLAG(ENABLE_VULKAN)
scoped_refptr<cc::VulkanContextProvider> vulkan_context_provider;
#endif
};
@@ -109,7 +110,7 @@ base::LazyInstance<CompositorDependencies>::DestructorAtExit
const unsigned int kMaxDisplaySwapBuffers = 1U;
-#if defined(ENABLE_VULKAN)
+#if BUILDFLAG(ENABLE_VULKAN)
scoped_refptr<cc::VulkanContextProvider> GetSharedVulkanContextProvider() {
if (base::CommandLine::ForCurrentProcess()->HasSwitch(
switches::kEnableVulkan)) {
@@ -304,7 +305,7 @@ class AndroidOutputSurface : public cc::OutputSurface {
base::WeakPtrFactory<AndroidOutputSurface> weak_ptr_factory_;
};
-#if defined(ENABLE_VULKAN)
+#if BUILDFLAG(ENABLE_VULKAN)
class VulkanOutputSurface : public cc::OutputSurface {
public:
explicit VulkanOutputSurface(
@@ -627,7 +628,7 @@ void CompositorImpl::HandlePendingCompositorFrameSinkRequest() {
if (!host_->IsVisible())
return;
-#if defined(ENABLE_VULKAN)
+#if BUILDFLAG(ENABLE_VULKAN)
CreateVulkanOutputSurface()
if (display_)
return;
@@ -658,7 +659,7 @@ void CompositorImpl::OnGpuChannelTimeout() {
LOG(FATAL) << "Timed out waiting for GPU channel.";
}
-#if defined(ENABLE_VULKAN)
+#if BUILDFLAG(ENABLE_VULKAN)
void CompositorImpl::CreateVulkanOutputSurface() {
if (!base::CommandLine::ForCurrentProcess()->HasSwitch(
switches::kEnableVulkan))
« no previous file with comments | « content/browser/renderer_host/compositor_impl_android.h ('k') | content/gpu/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698