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

Side by Side Diff: gpu/command_buffer/service/gles2_cmd_decoder.cc

Issue 7670033: Clear tex_image_2d_failed_ flag during new early return path in (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc » ('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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 5733 matching lines...) Expand 10 before | Expand all | Expand 10 after
5744 GLsizei tex_height = 0; 5744 GLsizei tex_height = 0;
5745 GLenum tex_type = 0; 5745 GLenum tex_type = 0;
5746 GLenum tex_format = 0; 5746 GLenum tex_format = 0;
5747 bool level_is_same = 5747 bool level_is_same =
5748 info->GetLevelSize(target, level, &tex_width, &tex_height) && 5748 info->GetLevelSize(target, level, &tex_width, &tex_height) &&
5749 info->GetLevelType(target, level, &tex_type, &tex_format) && 5749 info->GetLevelType(target, level, &tex_type, &tex_format) &&
5750 width == tex_width && height == tex_height && 5750 width == tex_width && height == tex_height &&
5751 type == tex_type && format == tex_format; 5751 type == tex_type && format == tex_format;
5752 5752
5753 if (level_is_same && !pixels) { 5753 if (level_is_same && !pixels) {
5754 tex_image_2d_failed_ = false;
5754 return error::kNoError; 5755 return error::kNoError;
5755 } 5756 }
5756 5757
5757 scoped_array<int8> zero; 5758 scoped_array<int8> zero;
5758 if (!pixels) { 5759 if (!pixels) {
5759 zero.reset(new int8[pixels_size]); 5760 zero.reset(new int8[pixels_size]);
5760 memset(zero.get(), 0, pixels_size); 5761 memset(zero.get(), 0, pixels_size);
5761 pixels = zero.get(); 5762 pixels = zero.get();
5762 } 5763 }
5763 5764
(...skipping 1049 matching lines...) Expand 10 before | Expand all | Expand 10 after
6813 return false; 6814 return false;
6814 } 6815 }
6815 6816
6816 // Include the auto-generated part of this file. We split this because it means 6817 // Include the auto-generated part of this file. We split this because it means
6817 // we can easily edit the non-auto generated parts right here in this file 6818 // we can easily edit the non-auto generated parts right here in this file
6818 // instead of having to edit some template or the code generator. 6819 // instead of having to edit some template or the code generator.
6819 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" 6820 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h"
6820 6821
6821 } // namespace gles2 6822 } // namespace gles2
6822 } // namespace gpu 6823 } // namespace gpu
OLDNEW
« no previous file with comments | « no previous file | gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698