Skia
2D Graphics Library
ShaderErrorHandler.h
Go to the documentation of this file.
1 /*
2  * Copyright 2021 Google LLC
3  *
4  * Use of this source code is governed by a BSD-style license that can be
5  * found in the LICENSE file.
6  */
7 
8 #ifndef skgpu_ShaderErrorHandler_DEFINED
9 #define skgpu_ShaderErrorHandler_DEFINED
10 
11 #include "include/core/SkTypes.h"
12 
13 namespace skgpu {
17 class SK_API ShaderErrorHandler {
18 public:
19  virtual ~ShaderErrorHandler() = default;
20 
21  virtual void compileError(const char* shader, const char* errors) = 0;
22 
23 protected:
24  ShaderErrorHandler() = default;
27 };
28 
33 
34 } // namespace skgpu
35 
36 #endif // skgpu_ShaderErrorHandler_DEFINED
Abstract class to report errors when compiling shaders.
Definition: ShaderErrorHandler.h:17
ShaderErrorHandler(const ShaderErrorHandler &)=delete
virtual void compileError(const char *shader, const char *errors)=0
virtual ~ShaderErrorHandler()=default
ShaderErrorHandler & operator=(const ShaderErrorHandler &)=delete
This file includes numerous public types that are used by all of our gpu backends.
Definition: SkCanvas.h:73
ShaderErrorHandler * DefaultShaderErrorHandler()
Used when no error handler is set.