OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2006 The Android Open Source Project | 3 * Copyright 2006 The Android Open Source Project |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 | 8 |
9 #include "SkXfermode.h" | 9 #include "SkXfermode.h" |
10 #include "SkXfermode_opts_SSE2.h" | 10 #include "SkXfermode_opts_SSE2.h" |
(...skipping 686 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
697 return true; | 697 return true; |
698 } else if (xfermode->asMode(&mode) && mode <= kLastCoeffMode) { | 698 } else if (xfermode->asMode(&mode) && mode <= kLastCoeffMode) { |
699 *xpf = GrPorterDuffXPFactory::Create(mode); | 699 *xpf = GrPorterDuffXPFactory::Create(mode); |
700 return true; | 700 return true; |
701 } else if (xfermode->asCoeff(&src, &dst)) { | 701 } else if (xfermode->asCoeff(&src, &dst)) { |
702 *xpf = GrPorterDuffXPFactory::Create(src, dst); | 702 *xpf = GrPorterDuffXPFactory::Create(src, dst); |
703 return true; | 703 return true; |
704 } else if (xfermode->asXPFactory(xpf)) { | 704 } else if (xfermode->asXPFactory(xpf)) { |
705 return true; | 705 return true; |
706 } else { | 706 } else { |
707 return xfermode->asFragmentProcessor(fp); | 707 return xfermode->asFragmentProcessor(fp, NULL); |
708 } | 708 } |
709 } | 709 } |
710 #else | 710 #else |
711 bool SkXfermode::AsFragmentProcessorOrXPFactory(SkXfermode* xfermode, | 711 bool SkXfermode::AsFragmentProcessorOrXPFactory(SkXfermode* xfermode, |
712 GrFragmentProcessor** fp, | 712 GrFragmentProcessor** fp, |
713 GrXPFactory** xpf) { | 713 GrXPFactory** xpf) { |
714 return false; | 714 return false; |
715 } | 715 } |
716 #endif | 716 #endif |
717 | 717 |
(...skipping 1235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1953 } else { | 1953 } else { |
1954 proc16 = rec.fProc16_General; | 1954 proc16 = rec.fProc16_General; |
1955 } | 1955 } |
1956 } | 1956 } |
1957 return proc16; | 1957 return proc16; |
1958 } | 1958 } |
1959 | 1959 |
1960 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_START(SkXfermode) | 1960 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_START(SkXfermode) |
1961 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkProcCoeffXfermode) | 1961 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkProcCoeffXfermode) |
1962 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_END | 1962 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_END |
OLD | NEW |