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

Side by Side Diff: android_webview/browser/hardware_renderer.cc

Issue 665463003: gpu: Add CHROMIUM_image support to in-process command buffer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move-gpu-memory-buffer-factory-to-gpu-image-factory
Patch Set: fix HardwareRenderer Created 6 years, 1 month 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 | « no previous file | cc/BUILD.gn » ('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 "android_webview/browser/hardware_renderer.h" 5 #include "android_webview/browser/hardware_renderer.h"
6 6
7 #include "android_webview/browser/aw_gl_surface.h" 7 #include "android_webview/browser/aw_gl_surface.h"
8 #include "android_webview/browser/deferred_gpu_command_service.h" 8 #include "android_webview/browser/deferred_gpu_command_service.h"
9 #include "android_webview/browser/parent_output_surface.h" 9 #include "android_webview/browser/parent_output_surface.h"
10 #include "android_webview/browser/shared_renderer_state.h" 10 #include "android_webview/browser/shared_renderer_state.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 scoped_ptr<gpu::GLInProcessContext> context(gpu::GLInProcessContext::Create( 55 scoped_ptr<gpu::GLInProcessContext> context(gpu::GLInProcessContext::Create(
56 service, 56 service,
57 surface, 57 surface,
58 surface->IsOffscreen(), 58 surface->IsOffscreen(),
59 gfx::kNullAcceleratedWidget, 59 gfx::kNullAcceleratedWidget,
60 surface->GetSize(), 60 surface->GetSize(),
61 NULL /* share_context */, 61 NULL /* share_context */,
62 false /* share_resources */, 62 false /* share_resources */,
63 attribs_for_gles2, 63 attribs_for_gles2,
64 gpu_preference, 64 gpu_preference,
65 gpu::GLInProcessContextSharedMemoryLimits())); 65 gpu::GLInProcessContextSharedMemoryLimits(),
66 nullptr,
67 nullptr));
66 DCHECK(context.get()); 68 DCHECK(context.get());
67 69
68 return webkit::gpu::ContextProviderInProcess::Create( 70 return webkit::gpu::ContextProviderInProcess::Create(
69 WebGraphicsContext3DInProcessCommandBufferImpl::WrapContext( 71 WebGraphicsContext3DInProcessCommandBufferImpl::WrapContext(
70 context.Pass(), attributes), 72 context.Pass(), attributes),
71 "Parent-Compositor"); 73 "Parent-Compositor");
72 } 74 }
73 75
74 } // namespace 76 } // namespace
75 77
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 } 264 }
263 265
264 void HardwareRenderer::UnusedResourcesAreAvailable() { 266 void HardwareRenderer::UnusedResourcesAreAvailable() {
265 cc::ReturnedResourceArray returned_resources; 267 cc::ReturnedResourceArray returned_resources;
266 resource_collection_->TakeUnusedResourcesForChildCompositor( 268 resource_collection_->TakeUnusedResourcesForChildCompositor(
267 &returned_resources); 269 &returned_resources);
268 shared_renderer_state_->InsertReturnedResourcesOnRT(returned_resources); 270 shared_renderer_state_->InsertReturnedResourcesOnRT(returned_resources);
269 } 271 }
270 272
271 } // namespace android_webview 273 } // namespace android_webview
OLDNEW
« no previous file with comments | « no previous file | cc/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698