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

Side by Side Diff: content/common/gpu/image_transport_surface_android.cc

Issue 1784193003: content gpu refactor: get rid of gpu related content switches. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix the compile problem on windows Created 4 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 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 #include "content/common/gpu/image_transport_surface.h" 5 #include "content/common/gpu/image_transport_surface.h"
6 6
7 #include "base/command_line.h"
8 #include "base/logging.h" 7 #include "base/logging.h"
9 #include "content/common/gpu/gpu_channel.h"
10 #include "content/common/gpu/gpu_channel_manager.h"
11 #include "content/common/gpu/gpu_command_buffer_stub.h"
12 #include "content/common/gpu/gpu_surface_lookup.h" 8 #include "content/common/gpu/gpu_surface_lookup.h"
13 #include "content/common/gpu/pass_through_image_transport_surface.h" 9 #include "content/common/gpu/pass_through_image_transport_surface.h"
14 #include "content/public/common/content_switches.h"
15 #include "ui/gl/gl_surface_egl.h" 10 #include "ui/gl/gl_surface_egl.h"
16 11
17 namespace content { 12 namespace content {
18 13
19 // static 14 // static
20 scoped_refptr<gfx::GLSurface> ImageTransportSurface::CreateNativeSurface( 15 scoped_refptr<gfx::GLSurface> ImageTransportSurface::CreateNativeSurface(
21 GpuChannelManager* manager, 16 GpuChannelManager* manager,
22 GpuCommandBufferStub* stub, 17 GpuCommandBufferStub* stub,
23 gpu::SurfaceHandle surface_handle, 18 gpu::SurfaceHandle surface_handle,
24 gfx::GLSurface::Format format) { 19 gfx::GLSurface::Format format) {
(...skipping 12 matching lines...) Expand all
37 bool initialize_success = surface->Initialize(format); 32 bool initialize_success = surface->Initialize(format);
38 ANativeWindow_release(window); 33 ANativeWindow_release(window);
39 if (!initialize_success) 34 if (!initialize_success)
40 return scoped_refptr<gfx::GLSurface>(); 35 return scoped_refptr<gfx::GLSurface>();
41 36
42 return scoped_refptr<gfx::GLSurface>( 37 return scoped_refptr<gfx::GLSurface>(
43 new PassThroughImageTransportSurface(manager, stub, surface.get())); 38 new PassThroughImageTransportSurface(manager, stub, surface.get()));
44 } 39 }
45 40
46 } // namespace content 41 } // namespace content
OLDNEW
« no previous file with comments | « content/common/gpu/gpu_host_messages.h ('k') | content/common/gpu/image_transport_surface_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698