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

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

Issue 663363002: Standardize usage of virtual/override/final in gpu/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update generator script Created 6 years, 2 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/error_state.h" 5 #include "gpu/command_buffer/service/error_state.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/strings/stringprintf.h" 9 #include "base/strings/stringprintf.h"
10 #include "gpu/command_buffer/common/gles2_cmd_utils.h" 10 #include "gpu/command_buffer/common/gles2_cmd_utils.h"
11 #include "gpu/command_buffer/service/logger.h" 11 #include "gpu/command_buffer/service/logger.h"
12 #include "ui/gl/gl_bindings.h" 12 #include "ui/gl/gl_bindings.h"
13 13
14 namespace gpu { 14 namespace gpu {
15 namespace gles2 { 15 namespace gles2 {
16 16
17 class ErrorStateImpl : public ErrorState { 17 class ErrorStateImpl : public ErrorState {
18 public: 18 public:
19 explicit ErrorStateImpl(ErrorStateClient* client, Logger* logger); 19 explicit ErrorStateImpl(ErrorStateClient* client, Logger* logger);
20 virtual ~ErrorStateImpl(); 20 ~ErrorStateImpl() override;
21 21
22 virtual uint32 GetGLError() override; 22 uint32 GetGLError() override;
23 23
24 virtual void SetGLError( 24 void SetGLError(const char* filename,
25 const char* filename, 25 int line,
26 int line, 26 unsigned int error,
27 unsigned int error, 27 const char* function_name,
28 const char* function_name, 28 const char* msg) override;
29 const char* msg) override; 29 void SetGLErrorInvalidEnum(const char* filename,
30 virtual void SetGLErrorInvalidEnum( 30 int line,
31 const char* filename, 31 const char* function_name,
32 int line, 32 unsigned int value,
33 const char* function_name, 33 const char* label) override;
34 unsigned int value, 34 void SetGLErrorInvalidParami(const char* filename,
35 const char* label) override; 35 int line,
36 virtual void SetGLErrorInvalidParami( 36 unsigned int error,
37 const char* filename, 37 const char* function_name,
38 int line, 38 unsigned int pname,
39 unsigned int error, 39 int param) override;
40 const char* function_name, 40 void SetGLErrorInvalidParamf(const char* filename,
41 unsigned int pname, 41 int line,
42 int param) override; 42 unsigned int error,
43 virtual void SetGLErrorInvalidParamf( 43 const char* function_name,
44 const char* filename, 44 unsigned int pname,
45 int line, 45 float param) override;
46 unsigned int error,
47 const char* function_name,
48 unsigned int pname,
49 float param) override;
50 46
51 virtual unsigned int PeekGLError( 47 unsigned int PeekGLError(const char* filename,
52 const char* filename, int line, const char* function_name) override; 48 int line,
49 const char* function_name) override;
53 50
54 virtual void CopyRealGLErrorsToWrapper( 51 void CopyRealGLErrorsToWrapper(const char* filename,
55 const char* filename, int line, const char* function_name) override; 52 int line,
53 const char* function_name) override;
56 54
57 virtual void ClearRealGLErrors( 55 void ClearRealGLErrors(const char* filename,
58 const char* filename, int line, const char* function_name) override; 56 int line,
57 const char* function_name) override;
59 58
60 private: 59 private:
61 // The last error message set. 60 // The last error message set.
62 std::string last_error_; 61 std::string last_error_;
63 // Current GL error bits. 62 // Current GL error bits.
64 uint32 error_bits_; 63 uint32 error_bits_;
65 64
66 ErrorStateClient* client_; 65 ErrorStateClient* client_;
67 Logger* logger_; 66 Logger* logger_;
68 67
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 GLES2Util::GetStringEnum(error) + " : " + 195 GLES2Util::GetStringEnum(error) + " : " +
197 function_name + ": was unhandled"); 196 function_name + ": was unhandled");
198 NOTREACHED() << "GL error " << error << " was unhandled."; 197 NOTREACHED() << "GL error " << error << " was unhandled.";
199 } 198 }
200 } 199 }
201 } 200 }
202 201
203 } // namespace gles2 202 } // namespace gles2
204 } // namespace gpu 203 } // namespace gpu
205 204
OLDNEW
« no previous file with comments | « gpu/command_buffer/service/common_decoder_unittest.cc ('k') | gpu/command_buffer/service/framebuffer_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698