Chromium Code Reviews| Index: src/core/SkLightingShader.h |
| diff --git a/src/core/SkLightingShader.h b/src/core/SkLightingShader.h |
| index f25b30342a70699506cc03a5ffbc786e1e620207..a58b08c8f54fa5d6b1ad52d8bf12b9dc9badb4eb 100644 |
| --- a/src/core/SkLightingShader.h |
| +++ b/src/core/SkLightingShader.h |
| @@ -16,6 +16,30 @@ class SkMatrix; |
| class SK_API SkLightingShader { |
| public: |
| + class NormalSource : public SkFlattenable { |
| + public: |
| + virtual ~NormalSource(); |
| + |
| +#if SK_SUPPORT_GPU |
| + virtual sk_sp<GrFragmentProcessor> asFragmentProcessor( |
|
reed1
2016/06/10 19:15:23
use override instead
dvonbeck
2016/06/10 21:00:16
This is not overriding anything, it's the NormalSo
|
| + GrContext* context, |
| + const SkMatrix& viewM, |
| + const SkMatrix* localMatrix, |
| + SkFilterQuality filterQuality, |
| + SkSourceGammaTreatment gammaTreatment) const = 0; |
| +#endif |
| + |
| + SK_DEFINE_FLATTENABLE_TYPE(NormalSource) |
|
dvonbeck
2016/06/10 18:31:21
FLATTENABLE: Macro
|
| + }; |
| + |
| + class SK_API NormalMapSource { |
| + public: |
| + static sk_sp<NormalSource> Make(const SkBitmap& normal, const SkVector& invNormRotation, |
| + const SkMatrix* normLocalM); |
| + |
| + SK_DECLARE_FLATTENABLE_REGISTRAR_GROUP() |
|
dvonbeck
2016/06/10 18:31:21
FLATTENABLE: Macro
|
| + }; |
| + |
| /** Returns a shader that lights the diffuse and normal maps with a set of lights. |
| It returns a shader with a reference count of 1. |