Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 13 matching lines...) Expand all Loading... | |
| 24 * By far the most common color space. | 24 * By far the most common color space. |
| 25 * This is the default space for images, unmarked content, and monitors . | 25 * This is the default space for images, unmarked content, and monitors . |
| 26 */ | 26 */ |
| 27 kSRGB_Named, | 27 kSRGB_Named, |
| 28 | 28 |
| 29 /** | 29 /** |
| 30 * Very common wide gamut color space. | 30 * Very common wide gamut color space. |
| 31 * Often used by images and monitors. | 31 * Often used by images and monitors. |
| 32 */ | 32 */ |
| 33 kAdobeRGB_Named, | 33 kAdobeRGB_Named, |
| 34 | |
| 35 /** | |
| 36 * Colorspace with the sRGB primaries, but a linear (1.0) gamma. | |
|
msarett
2016/09/27 20:53:52
Might be interesting to comment on why this is int
| |
| 37 */ | |
| 38 kSRGBLinear_Named, | |
| 34 }; | 39 }; |
| 35 | 40 |
| 36 enum RenderTargetGamma : uint8_t { | 41 enum RenderTargetGamma : uint8_t { |
| 37 kLinear_RenderTargetGamma, | 42 kLinear_RenderTargetGamma, |
| 38 | 43 |
| 39 /** | 44 /** |
| 40 * Transfer function is the canonical sRGB curve, which has a short lin ear segment | 45 * Transfer function is the canonical sRGB curve, which has a short lin ear segment |
| 41 * followed by a 2.4f exponential. | 46 * followed by a 2.4f exponential. |
| 42 */ | 47 */ |
| 43 kSRGB_RenderTargetGamma, | 48 kSRGB_RenderTargetGamma, |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 98 */ | 103 */ |
| 99 static bool Equals(const SkColorSpace* src, const SkColorSpace* dst); | 104 static bool Equals(const SkColorSpace* src, const SkColorSpace* dst); |
| 100 | 105 |
| 101 protected: | 106 protected: |
| 102 SkColorSpace(const SkMatrix44& toXYZD50); | 107 SkColorSpace(const SkMatrix44& toXYZD50); |
| 103 | 108 |
| 104 const SkMatrix44 fToXYZD50; | 109 const SkMatrix44 fToXYZD50; |
| 105 }; | 110 }; |
| 106 | 111 |
| 107 #endif | 112 #endif |
| OLD | NEW |