| 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 3221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3232 if (offscreen_resolved_color_texture_.get()) | 3232 if (offscreen_resolved_color_texture_.get()) |
| 3233 offscreen_resolved_color_texture_->Destroy(); | 3233 offscreen_resolved_color_texture_->Destroy(); |
| 3234 offscreen_resolved_color_texture_.reset(); | 3234 offscreen_resolved_color_texture_.reset(); |
| 3235 offscreen_resolved_frame_buffer_.reset(); | 3235 offscreen_resolved_frame_buffer_.reset(); |
| 3236 | 3236 |
| 3237 return true; | 3237 return true; |
| 3238 } | 3238 } |
| 3239 | 3239 |
| 3240 error::Error GLES2DecoderImpl::HandleResizeCHROMIUM( | 3240 error::Error GLES2DecoderImpl::HandleResizeCHROMIUM( |
| 3241 uint32 immediate_data_size, const gles2::ResizeCHROMIUM& c) { | 3241 uint32 immediate_data_size, const gles2::ResizeCHROMIUM& c) { |
| 3242 if (ShouldDeferDraws()) |
| 3243 return error::kDeferCommandUntilLater; |
| 3244 |
| 3242 GLuint width = static_cast<GLuint>(c.width); | 3245 GLuint width = static_cast<GLuint>(c.width); |
| 3243 GLuint height = static_cast<GLuint>(c.height); | 3246 GLuint height = static_cast<GLuint>(c.height); |
| 3244 TRACE_EVENT2("gpu", "glResizeChromium", "width", width, "height", height); | 3247 TRACE_EVENT2("gpu", "glResizeChromium", "width", width, "height", height); |
| 3245 #if defined(OS_POSIX) && !defined(OS_MACOSX) && \ | 3248 #if defined(OS_POSIX) && !defined(OS_MACOSX) && \ |
| 3246 !defined(UI_COMPOSITOR_IMAGE_TRANSPORT) | 3249 !defined(UI_COMPOSITOR_IMAGE_TRANSPORT) |
| 3247 // Make sure that we are done drawing to the back buffer before resizing. | 3250 // Make sure that we are done drawing to the back buffer before resizing. |
| 3248 glFinish(); | 3251 glFinish(); |
| 3249 #endif | 3252 #endif |
| 3250 bool is_offscreen = !!offscreen_target_frame_buffer_.get(); | 3253 bool is_offscreen = !!offscreen_target_frame_buffer_.get(); |
| 3251 if (is_offscreen) { | 3254 if (is_offscreen) { |
| (...skipping 6142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 9394 } | 9397 } |
| 9395 | 9398 |
| 9396 | 9399 |
| 9397 // Include the auto-generated part of this file. We split this because it means | 9400 // Include the auto-generated part of this file. We split this because it means |
| 9398 // we can easily edit the non-auto generated parts right here in this file | 9401 // we can easily edit the non-auto generated parts right here in this file |
| 9399 // instead of having to edit some template or the code generator. | 9402 // instead of having to edit some template or the code generator. |
| 9400 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" | 9403 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" |
| 9401 | 9404 |
| 9402 } // namespace gles2 | 9405 } // namespace gles2 |
| 9403 } // namespace gpu | 9406 } // namespace gpu |
| OLD | NEW |