| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2007 The Android Open Source Project | 2 * Copyright 2007 The Android Open Source Project |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
| 6 */ | 6 */ |
| 7 | 7 |
| 8 #ifndef SkColorMatrixFilter_DEFINED | 8 #ifndef SkColorMatrixFilter_DEFINED |
| 9 #define SkColorMatrixFilter_DEFINED | 9 #define SkColorMatrixFilter_DEFINED |
| 10 | 10 |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 int fShift; | 34 int fShift; |
| 35 }; | 35 }; |
| 36 | 36 |
| 37 SK_TO_STRING_OVERRIDE() | 37 SK_TO_STRING_OVERRIDE() |
| 38 | 38 |
| 39 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkColorMatrixFilter) | 39 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkColorMatrixFilter) |
| 40 | 40 |
| 41 protected: | 41 protected: |
| 42 explicit SkColorMatrixFilter(const SkColorMatrix&); | 42 explicit SkColorMatrixFilter(const SkColorMatrix&); |
| 43 explicit SkColorMatrixFilter(const SkScalar array[20]); | 43 explicit SkColorMatrixFilter(const SkScalar array[20]); |
| 44 #ifdef SK_SUPPORT_LEGACY_DEEPFLATTENING |
| 45 explicit SkColorMatrixFilter(SkReadBuffer& buffer); |
| 46 #endif |
| 44 virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; | 47 virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; |
| 45 | 48 |
| 46 private: | 49 private: |
| 47 SkColorMatrix fMatrix; | 50 SkColorMatrix fMatrix; |
| 48 | 51 |
| 49 typedef void (*Proc)(const State&, unsigned r, unsigned g, unsigned b, | 52 typedef void (*Proc)(const State&, unsigned r, unsigned g, unsigned b, |
| 50 unsigned a, int32_t result[4]); | 53 unsigned a, int32_t result[4]); |
| 51 | 54 |
| 52 Proc fProc; | 55 Proc fProc; |
| 53 State fState; | 56 State fState; |
| 54 uint32_t fFlags; | 57 uint32_t fFlags; |
| 55 | 58 |
| 56 void initState(const SkScalar array[20]); | 59 void initState(const SkScalar array[20]); |
| 57 | 60 |
| 58 typedef SkColorFilter INHERITED; | 61 typedef SkColorFilter INHERITED; |
| 59 }; | 62 }; |
| 60 | 63 |
| 61 #endif | 64 #endif |
| OLD | NEW |