diff options
author | Chris Dalton <csmartdalton@google.com> | 2018-01-08 17:21:41 -0500 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-01-08 22:51:11 +0000 |
commit | 383a2ef6edb84dbebc7a9c22ea7423037bbf6a2f (patch) | |
tree | 8ffed2cbcf6ecd3288176045f851e1246ae6dd72 /src/gpu/ccpr/GrCCClipProcessor.h | |
parent | c35959f3cb855c6500f279b893eea07ce5a2573b (diff) |
CCPR: Rename GrCCPR* -> GrCC*
Also runs clang-format on the files that don't have special shader
builder styling.
Bug: skia:
Change-Id: I4a67569a7c8472acfb9200644c913844a92e3b2d
Reviewed-on: https://skia-review.googlesource.com/92083
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Diffstat (limited to 'src/gpu/ccpr/GrCCClipProcessor.h')
-rw-r--r-- | src/gpu/ccpr/GrCCClipProcessor.h | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/src/gpu/ccpr/GrCCClipProcessor.h b/src/gpu/ccpr/GrCCClipProcessor.h new file mode 100644 index 0000000000..374a2dfe95 --- /dev/null +++ b/src/gpu/ccpr/GrCCClipProcessor.h @@ -0,0 +1,42 @@ +/* + * Copyright 2017 Google Inc. + * + * Use of this source code is governed by a BSD-style license that can be + * found in the LICENSE file. + */ + +#ifndef GrCCClipProcessor_DEFINED +#define GrCCClipProcessor_DEFINED + +#include "GrFragmentProcessor.h" +#include "ccpr/GrCoverageCountingPathRenderer.h" + +class GrCCClipProcessor : public GrFragmentProcessor { +public: + using ClipPath = GrCoverageCountingPathRenderer::ClipPath; + + enum class MustCheckBounds : bool { + kNo = false, + kYes = true + }; + + GrCCClipProcessor(const ClipPath*, MustCheckBounds, SkPath::FillType overrideFillType); + + const char* name() const override { return "GrCCClipProcessor"; } + std::unique_ptr<GrFragmentProcessor> clone() const override; + void onGetGLSLProcessorKey(const GrShaderCaps&, GrProcessorKeyBuilder*) const override; + bool onIsEqual(const GrFragmentProcessor&) const override; + GrGLSLFragmentProcessor* onCreateGLSLInstance() const override; + +private: + const ClipPath* const fClipPath; + const bool fMustCheckBounds; + const SkPath::FillType fOverrideFillType; + const TextureSampler fAtlasAccess; + + class Impl; + + typedef GrFragmentProcessor INHERITED; +}; + +#endif |