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

Side by Side Diff: src/core/SkColorSpace.h

Issue 1945693002: Create a single, unique pointer to sRGB color space (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 7 months 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 | « src/codec/SkPngCodec.cpp ('k') | src/core/SkColorSpace.cpp » ('j') | 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 * Copyright 2016 Google Inc. 2 * Copyright 2016 Google Inc.
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 SkColorSpace_DEFINED 8 #ifndef SkColorSpace_DEFINED
9 #define SkColorSpace_DEFINED 9 #define SkColorSpace_DEFINED
10 10
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 SkGammaCurve fGreen; 113 SkGammaCurve fGreen;
114 SkGammaCurve fBlue; 114 SkGammaCurve fBlue;
115 115
116 friend class SkColorSpace; 116 friend class SkColorSpace;
117 }; 117 };
118 118
119 /** 119 /**
120 * Return a colorspace instance, given a 3x3 transform from linear_RGB to D 50_XYZ 120 * Return a colorspace instance, given a 3x3 transform from linear_RGB to D 50_XYZ
121 * and the src-gamma, return a ColorSpace 121 * and the src-gamma, return a ColorSpace
122 */ 122 */
123 static sk_sp<SkColorSpace> NewRGB(const SkFloat3x3& toXYZD50, SkGammas gamma s); 123 static sk_sp<SkColorSpace> NewRGB(SkGammas gammas, const SkFloat3x3& toXYZD5 0);
msarett 2016/05/03 15:16:49 Reverse parameter order to match the rest of the f
124 124
125 static sk_sp<SkColorSpace> NewNamed(Named); 125 static sk_sp<SkColorSpace> NewNamed(Named);
126 static sk_sp<SkColorSpace> NewICC(const void*, size_t); 126 static sk_sp<SkColorSpace> NewICC(const void*, size_t);
127 127
128 const SkGammas& gammas() const { return fGammas; } 128 const SkGammas& gammas() const { return fGammas; }
129 SkFloat3x3 xyz() const { return fToXYZD50; } 129 SkFloat3x3 xyz() const { return fToXYZD50; }
130 SkFloat3 xyzOffset() const { return fToXYZOffset; } 130 SkFloat3 xyzOffset() const { return fToXYZOffset; }
131 Named named() const { return fNamed; } 131 Named named() const { return fNamed; }
132 uint32_t uniqueID() const { return fUniqueID; } 132 uint32_t uniqueID() const { return fUniqueID; }
133 133
(...skipping 17 matching lines...) Expand all
151 const SkColorLookUpTable fColorLUT; 151 const SkColorLookUpTable fColorLUT;
152 const SkGammas fGammas; 152 const SkGammas fGammas;
153 const SkFloat3x3 fToXYZD50; 153 const SkFloat3x3 fToXYZD50;
154 const SkFloat3 fToXYZOffset; 154 const SkFloat3 fToXYZOffset;
155 155
156 const uint32_t fUniqueID; 156 const uint32_t fUniqueID;
157 const Named fNamed; 157 const Named fNamed;
158 }; 158 };
159 159
160 #endif 160 #endif
OLDNEW
« no previous file with comments | « src/codec/SkPngCodec.cpp ('k') | src/core/SkColorSpace.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698