OLD | NEW |
1 #ifndef SkXfermode_proccoeff_DEFINED | 1 #ifndef SkXfermode_proccoeff_DEFINED |
2 #define SkXfermode_proccoeff_DEFINED | 2 #define SkXfermode_proccoeff_DEFINED |
3 | 3 |
4 #include "SkXfermode.h" | 4 #include "SkXfermode.h" |
5 #include "SkReadBuffer.h" | 5 #include "SkReadBuffer.h" |
6 #include "SkWriteBuffer.h" | 6 #include "SkWriteBuffer.h" |
7 | 7 |
8 struct ProcCoeff { | 8 struct ProcCoeff { |
9 SkXfermodeProc fProc; | 9 SkXfermodeProc fProc; |
10 SkXfermode::Coeff fSC; | 10 SkXfermode::Coeff fSC; |
(...skipping 12 matching lines...) Expand all Loading... |
23 fDstCoeff = rec.fDC; | 23 fDstCoeff = rec.fDC; |
24 } | 24 } |
25 | 25 |
26 virtual void xfer32(SkPMColor dst[], const SkPMColor src[], int count, | 26 virtual void xfer32(SkPMColor dst[], const SkPMColor src[], int count, |
27 const SkAlpha aa[]) const SK_OVERRIDE; | 27 const SkAlpha aa[]) const SK_OVERRIDE; |
28 virtual void xfer16(uint16_t dst[], const SkPMColor src[], int count, | 28 virtual void xfer16(uint16_t dst[], const SkPMColor src[], int count, |
29 const SkAlpha aa[]) const SK_OVERRIDE; | 29 const SkAlpha aa[]) const SK_OVERRIDE; |
30 virtual void xferA8(SkAlpha dst[], const SkPMColor src[], int count, | 30 virtual void xferA8(SkAlpha dst[], const SkPMColor src[], int count, |
31 const SkAlpha aa[]) const SK_OVERRIDE; | 31 const SkAlpha aa[]) const SK_OVERRIDE; |
32 | 32 |
33 virtual bool asMode(Mode* mode) const SK_OVERRIDE; | 33 bool asMode(Mode* mode) const SK_OVERRIDE; |
34 | 34 |
35 virtual bool asCoeff(Coeff* sc, Coeff* dc) const SK_OVERRIDE; | 35 bool asCoeff(Coeff* sc, Coeff* dc) const SK_OVERRIDE; |
36 | 36 |
37 #if SK_SUPPORT_GPU | 37 #if SK_SUPPORT_GPU |
38 virtual bool asFragmentProcessor(GrFragmentProcessor**, | 38 virtual bool asFragmentProcessor(GrFragmentProcessor**, |
39 GrTexture* background) const SK_OVERRIDE; | 39 GrTexture* background) const SK_OVERRIDE; |
40 #endif | 40 #endif |
41 | 41 |
42 SK_TO_STRING_OVERRIDE() | 42 SK_TO_STRING_OVERRIDE() |
43 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkProcCoeffXfermode) | 43 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkProcCoeffXfermode) |
44 | 44 |
45 protected: | 45 protected: |
46 virtual void flatten(SkWriteBuffer& buffer) const SK_OVERRIDE; | 46 void flatten(SkWriteBuffer& buffer) const SK_OVERRIDE; |
47 | 47 |
48 Mode getMode() const { return fMode; } | 48 Mode getMode() const { return fMode; } |
49 | 49 |
50 SkXfermodeProc getProc() const { return fProc; } | 50 SkXfermodeProc getProc() const { return fProc; } |
51 | 51 |
52 private: | 52 private: |
53 SkXfermodeProc fProc; | 53 SkXfermodeProc fProc; |
54 Mode fMode; | 54 Mode fMode; |
55 Coeff fSrcCoeff, fDstCoeff; | 55 Coeff fSrcCoeff, fDstCoeff; |
56 | 56 |
57 friend class SkXfermode; | 57 friend class SkXfermode; |
58 | 58 |
59 typedef SkXfermode INHERITED; | 59 typedef SkXfermode INHERITED; |
60 }; | 60 }; |
61 | 61 |
62 #endif // #ifndef SkXfermode_proccoeff_DEFINED | 62 #endif // #ifndef SkXfermode_proccoeff_DEFINED |
OLD | NEW |