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

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

Issue 2123493002: Fix histogram name mismatch for GPU.Error_TexImage* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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
« no previous file with comments | « no previous file | no next file » | 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) 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/texture_manager.h" 5 #include "gpu/command_buffer/service/texture_manager.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 2971 matching lines...) Expand 10 before | Expand all | Expand 10 after
2982 glTexImage2D( 2982 glTexImage2D(
2983 args.target, args.level, 2983 args.target, args.level,
2984 AdjustTexInternalFormat(feature_info_.get(), args.internal_format), 2984 AdjustTexInternalFormat(feature_info_.get(), args.internal_format),
2985 args.width, args.height, args.border, 2985 args.width, args.height, args.border,
2986 AdjustTexFormat(feature_info_.get(), args.format), args.type, 2986 AdjustTexFormat(feature_info_.get(), args.format), args.type,
2987 args.pixels); 2987 args.pixels);
2988 } 2988 }
2989 } 2989 }
2990 GLenum error = ERRORSTATE_PEEK_GL_ERROR(error_state, function_name); 2990 GLenum error = ERRORSTATE_PEEK_GL_ERROR(error_state, function_name);
2991 if (args.command_type == DoTexImageArguments::kTexImage3D) { 2991 if (args.command_type == DoTexImageArguments::kTexImage3D) {
2992 UMA_HISTOGRAM_CUSTOM_ENUMERATION("GPU.Error.TexImage3D", error, 2992 UMA_HISTOGRAM_CUSTOM_ENUMERATION("GPU.Error_TexImage3D", error,
2993 GetAllGLErrors()); 2993 GetAllGLErrors());
2994 } else { 2994 } else {
2995 UMA_HISTOGRAM_CUSTOM_ENUMERATION("GPU.Error.TexImage2D", error, 2995 UMA_HISTOGRAM_CUSTOM_ENUMERATION("GPU.Error_TexImage2D", error,
2996 GetAllGLErrors()); 2996 GetAllGLErrors());
2997 } 2997 }
2998 if (error == GL_NO_ERROR) { 2998 if (error == GL_NO_ERROR) {
2999 bool set_as_cleared = (args.pixels != nullptr || unpack_buffer_bound); 2999 bool set_as_cleared = (args.pixels != nullptr || unpack_buffer_bound);
3000 SetLevelInfo( 3000 SetLevelInfo(
3001 texture_ref, args.target, args.level, args.internal_format, args.width, 3001 texture_ref, args.target, args.level, args.internal_format, args.width,
3002 args.height, args.depth, args.border, args.format, args.type, 3002 args.height, args.depth, args.border, args.format, args.type,
3003 set_as_cleared ? gfx::Rect(args.width, args.height) : gfx::Rect()); 3003 set_as_cleared ? gfx::Rect(args.width, args.height) : gfx::Rect());
3004 texture->ApplyFormatWorkarounds(feature_info_.get()); 3004 texture->ApplyFormatWorkarounds(feature_info_.get());
3005 texture_state->tex_image_failed = false; 3005 texture_state->tex_image_failed = false;
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
3364 uint32_t TextureManager::GetServiceIdGeneration() const { 3364 uint32_t TextureManager::GetServiceIdGeneration() const {
3365 return current_service_id_generation_; 3365 return current_service_id_generation_;
3366 } 3366 }
3367 3367
3368 void TextureManager::IncrementServiceIdGeneration() { 3368 void TextureManager::IncrementServiceIdGeneration() {
3369 current_service_id_generation_++; 3369 current_service_id_generation_++;
3370 } 3370 }
3371 3371
3372 } // namespace gles2 3372 } // namespace gles2
3373 } // namespace gpu 3373 } // namespace gpu
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698