Chromium Code Reviews| Index: content/renderer/renderer_blink_platform_impl.cc |
| diff --git a/content/renderer/renderer_blink_platform_impl.cc b/content/renderer/renderer_blink_platform_impl.cc |
| index 242a5950a3c6cca3b1b844a75efd806d3955dfcf..e477905ad6c846cef7b4a9c4abed9cec348424ec 100644 |
| --- a/content/renderer/renderer_blink_platform_impl.cc |
| +++ b/content/renderer/renderer_blink_platform_impl.cc |
| @@ -929,7 +929,31 @@ bool RendererBlinkPlatformImpl::processMemorySizesInBytes( |
| blink::WebGraphicsContext3D* |
| RendererBlinkPlatformImpl::createOffscreenGraphicsContext3D( |
| const blink::WebGraphicsContext3D::Attributes& attributes) { |
| - return createOffscreenGraphicsContext3D(attributes, NULL); |
| + blink::WebGLInfo gl_info; |
|
piman
2014/10/27 19:43:47
Why create a WebGLInfo if we're going to discard i
sivag
2014/10/28 15:29:00
Done. Sorry i missed this.
|
| + return createOffscreenGraphicsContext3D(attributes, NULL, &gl_info); |
| +} |
| + |
| +blink::WebGraphicsContext3D* |
| +RendererBlinkPlatformImpl::createOffscreenGraphicsContext3D( |
| + const blink::WebGraphicsContext3D::Attributes& attributes, |
| + blink::WebGraphicsContext3D* share_context, |
| + blink::WebGLInfo* gl_info) { |
| + |
| + RenderThreadImpl* render_thread = RenderThreadImpl::current(); |
| + if (render_thread && gl_info) { |
| + GpuChannelHost* gpu_channel_host = render_thread->GetGpuChannel(); |
|
piman
2014/10/27 19:43:47
This could be NULL, or a different channel than th
sivag
2014/10/28 15:29:00
Done.
|
| + if (gpu_channel_host) { |
| + const gpu::GPUInfo& gpu_info = gpu_channel_host->gpu_info(); |
| + gl_info->vendorInfo.assign( |
| + blink::WebString::fromUTF8(gpu_info.gl_vendor)); |
| + gl_info->rendererInfo.assign( |
| + blink::WebString::fromUTF8(gpu_info.gl_renderer)); |
| + gl_info->driverVersion.assign( |
| + blink::WebString::fromUTF8(gpu_info.gl_version)); |
| + } |
| + } |
| + |
| + return createOffscreenGraphicsContext3D(attributes, share_context); |
| } |
| blink::WebGraphicsContext3D* |