| OLD | NEW |
| 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 "gpu/command_buffer/service/gles2_cmd_decoder.h" | 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" |
| 6 | 6 |
| 7 #include <stdio.h> | 7 #include <stdio.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <list> | 10 #include <list> |
| (...skipping 2347 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2358 const scoped_refptr<gfx::GLSurface>& surface, | 2358 const scoped_refptr<gfx::GLSurface>& surface, |
| 2359 const scoped_refptr<gfx::GLContext>& context, | 2359 const scoped_refptr<gfx::GLContext>& context, |
| 2360 bool offscreen, | 2360 bool offscreen, |
| 2361 const gfx::Size& size, | 2361 const gfx::Size& size, |
| 2362 const DisallowedFeatures& disallowed_features, | 2362 const DisallowedFeatures& disallowed_features, |
| 2363 const std::vector<int32>& attribs) { | 2363 const std::vector<int32>& attribs) { |
| 2364 TRACE_EVENT0("gpu", "GLES2DecoderImpl::Initialize"); | 2364 TRACE_EVENT0("gpu", "GLES2DecoderImpl::Initialize"); |
| 2365 DCHECK(context->IsCurrent(surface.get())); | 2365 DCHECK(context->IsCurrent(surface.get())); |
| 2366 DCHECK(!context_.get()); | 2366 DCHECK(!context_.get()); |
| 2367 | 2367 |
| 2368 surfaceless_ = surface->IsSurfaceless(); | 2368 surfaceless_ = surface->IsSurfaceless() && !offscreen; |
| 2369 | 2369 |
| 2370 set_initialized(); | 2370 set_initialized(); |
| 2371 gpu_tracer_.reset(new GPUTracer(this)); | 2371 gpu_tracer_.reset(new GPUTracer(this)); |
| 2372 gpu_state_tracer_ = GPUStateTracer::Create(&state_); | 2372 gpu_state_tracer_ = GPUStateTracer::Create(&state_); |
| 2373 | 2373 |
| 2374 if (CommandLine::ForCurrentProcess()->HasSwitch( | 2374 if (CommandLine::ForCurrentProcess()->HasSwitch( |
| 2375 switches::kEnableGPUDebugging)) { | 2375 switches::kEnableGPUDebugging)) { |
| 2376 set_debug(true); | 2376 set_debug(true); |
| 2377 } | 2377 } |
| 2378 | 2378 |
| (...skipping 8817 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 11196 } | 11196 } |
| 11197 } | 11197 } |
| 11198 | 11198 |
| 11199 // Include the auto-generated part of this file. We split this because it means | 11199 // Include the auto-generated part of this file. We split this because it means |
| 11200 // we can easily edit the non-auto generated parts right here in this file | 11200 // we can easily edit the non-auto generated parts right here in this file |
| 11201 // instead of having to edit some template or the code generator. | 11201 // instead of having to edit some template or the code generator. |
| 11202 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" | 11202 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" |
| 11203 | 11203 |
| 11204 } // namespace gles2 | 11204 } // namespace gles2 |
| 11205 } // namespace gpu | 11205 } // namespace gpu |
| OLD | NEW |