Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(455)

Side by Side Diff: include/core/SkXfermode.h

Issue 1406413003: Attempt to update Xfermode comments to have parallel structure. (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 9
10 #ifndef SkXfermode_DEFINED 10 #ifndef SkXfermode_DEFINED
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 For these equations, the colors are in premultiplied state. 63 For these equations, the colors are in premultiplied state.
64 If no xfermode is specified, kSrcOver is assumed. 64 If no xfermode is specified, kSrcOver is assumed.
65 The modes are ordered by those that can be expressed as a pair of Coeffs , followed by those 65 The modes are ordered by those that can be expressed as a pair of Coeffs , followed by those
66 that aren't Coeffs but have separable r,g,b computations, and finally 66 that aren't Coeffs but have separable r,g,b computations, and finally
67 those that are not separable. 67 those that are not separable.
68 */ 68 */
69 enum Mode { 69 enum Mode {
70 kClear_Mode, //!< [0, 0] 70 kClear_Mode, //!< [0, 0]
71 kSrc_Mode, //!< [Sa, Sc] 71 kSrc_Mode, //!< [Sa, Sc]
72 kDst_Mode, //!< [Da, Dc] 72 kDst_Mode, //!< [Da, Dc]
73 kSrcOver_Mode, //!< [Sa + Da - Sa*Da, Rc = Sc + (1 - Sa)*Dc] 73 kSrcOver_Mode, //!< [Sa + Da * (1 - Sa), Sc + Dc * (1 - Sa)]
74 kDstOver_Mode, //!< [Sa + Da - Sa*Da, Rc = Dc + (1 - Da)*Sc] 74 kDstOver_Mode, //!< [Da + Sa * (1 - Da), Dc + Sc * (1 - Da)]
75 kSrcIn_Mode, //!< [Sa * Da, Sc * Da] 75 kSrcIn_Mode, //!< [Sa * Da, Sc * Da]
76 kDstIn_Mode, //!< [Sa * Da, Sa * Dc] 76 kDstIn_Mode, //!< [Da * Sa, Dc * Sa]
77 kSrcOut_Mode, //!< [Sa * (1 - Da), Sc * (1 - Da)] 77 kSrcOut_Mode, //!< [Sa * (1 - Da), Sc * (1 - Da)]
78 kDstOut_Mode, //!< [Da * (1 - Sa), Dc * (1 - Sa)] 78 kDstOut_Mode, //!< [Da * (1 - Sa), Dc * (1 - Sa)]
79 kSrcATop_Mode, //!< [Da, Sc * Da + (1 - Sa) * Dc] 79 kSrcATop_Mode, //!< [Da, Sc * Da + Dc * (1 - Sa)]
80 kDstATop_Mode, //!< [Sa, Sa * Dc + Sc * (1 - Da)] 80 kDstATop_Mode, //!< [Sa, Dc * Sa + Sc * (1 - Da)]
81 kXor_Mode, //!< [Sa + Da - 2 * Sa * Da, Sc * (1 - Da) + (1 - Sa) * Dc] 81 kXor_Mode, //!< [Sa + Da - 2 * Sa * Da, Sc * (1 - Da) + Dc * (1 - S a)]
82 kPlus_Mode, //!< [Sa + Da, Sc + Dc] 82 kPlus_Mode, //!< [Sa + Da, Sc + Dc]
83 kModulate_Mode, // multiplies all components (= alpha and color) 83 kModulate_Mode, // multiplies all components (= alpha and color)
84 84
85 // Following blend modes are defined in the CSS Compositing standard: 85 // Following blend modes are defined in the CSS Compositing standard:
86 // https://dvcs.w3.org/hg/FXTF/rawfile/tip/compositing/index.html#blendi ng 86 // https://dvcs.w3.org/hg/FXTF/rawfile/tip/compositing/index.html#blendi ng
87 kScreen_Mode, 87 kScreen_Mode,
88 kLastCoeffMode = kScreen_Mode, 88 kLastCoeffMode = kScreen_Mode,
89 89
90 kOverlay_Mode, 90 kOverlay_Mode,
91 kDarken_Mode, 91 kDarken_Mode,
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 235
236 private: 236 private:
237 enum { 237 enum {
238 kModeCount = kLastMode + 1 238 kModeCount = kLastMode + 1
239 }; 239 };
240 240
241 typedef SkFlattenable INHERITED; 241 typedef SkFlattenable INHERITED;
242 }; 242 };
243 243
244 #endif 244 #endif
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698