#include <SkEncodedInfo.h>
|
enum | Alpha { kOpaque_Alpha
, kUnpremul_Alpha
, kBinary_Alpha
} |
|
enum | Color {
kGray_Color
, kGrayAlpha_Color
, kXAlpha_Color
, k565_Color
,
kPalette_Color
, kRGB_Color
, kRGBA_Color
, kBGR_Color
,
kBGRX_Color
, kBGRA_Color
, kYUV_Color
, kYUVA_Color
,
kInvertedCMYK_Color
, kYCCK_Color
} |
|
|
static SkEncodedInfo | Make (int width, int height, Color color, Alpha alpha, int bitsPerComponent) |
|
static SkEncodedInfo | Make (int width, int height, Color color, Alpha alpha, int bitsPerComponent, std::unique_ptr< ICCProfile > profile) |
|
static SkEncodedInfo | Make (int width, int height, Color color, Alpha alpha, int bitsPerComponent, std::unique_ptr< ICCProfile > profile, int colorDepth) |
|
Definition at line 25 of file SkEncodedInfo.h.
◆ Alpha
Enumerator |
---|
kOpaque_Alpha | |
kUnpremul_Alpha | |
kBinary_Alpha | |
Definition at line 41 of file SkEncodedInfo.h.
◆ Color
Enumerator |
---|
kGray_Color | |
kGrayAlpha_Color | |
kXAlpha_Color | |
k565_Color | |
kPalette_Color | |
kRGB_Color | |
kRGBA_Color | |
kBGR_Color | |
kBGRX_Color | |
kBGRA_Color | |
kYUV_Color | |
kYUVA_Color | |
kInvertedCMYK_Color | |
kYCCK_Color | |
Definition at line 58 of file SkEncodedInfo.h.
58 {
59
61
62
64
65
66
67
68
69
71
72
73
74
75
76
78
79
81
82
85
86
90
91
93
94
96
97
98
99
100
101
102
105 };
◆ SkEncodedInfo() [1/2]
◆ SkEncodedInfo() [2/2]
◆ alpha()
Alpha SkEncodedInfo::alpha |
( |
| ) |
const |
|
inline |
◆ bitsPerComponent()
uint8_t SkEncodedInfo::bitsPerComponent |
( |
| ) |
const |
|
inline |
◆ bitsPerPixel()
uint8_t SkEncodedInfo::bitsPerPixel |
( |
| ) |
const |
|
inline |
Definition at line 214 of file SkEncodedInfo.h.
214 {
215 switch (fColor) {
217 return fBitsPerComponent;
220 return 2 * fBitsPerComponent;
222 return fBitsPerComponent;
227 return 3 * fBitsPerComponent;
234 return 4 * fBitsPerComponent;
235 default:
237 return 0;
238 }
239 }
◆ color()
Color SkEncodedInfo::color |
( |
| ) |
const |
|
inline |
◆ copy()
Definition at line 248 of file SkEncodedInfo.h.
248 {
250 fWidth, fHeight, fColor, fAlpha, fBitsPerComponent, nullptr, fColorDepth);
251 if (fProfile) {
252 copy.fProfile = std::make_unique<ICCProfile>(*fProfile);
253 }
255 }
SkEncodedInfo copy() const
static SkEncodedInfo Make(int width, int height, Color color, Alpha alpha, int bitsPerComponent)
◆ getColorDepth()
uint8_t SkEncodedInfo::getColorDepth |
( |
| ) |
const |
|
inline |
◆ height()
int SkEncodedInfo::height |
( |
| ) |
const |
|
inline |
◆ Make() [1/3]
Definition at line 107 of file SkEncodedInfo.h.
108 {
110 }
uint8_t bitsPerComponent() const
◆ Make() [2/3]
Definition at line 112 of file SkEncodedInfo.h.
113 {
116 }
const skcms_ICCProfile * profile() const
◆ Make() [3/3]
Definition at line 118 of file SkEncodedInfo.h.
120 {
126
130 break;
133 break;
136 break;
142 break;
148 break;
151 break;
155 break;
159 break;
163 break;
164 default:
166 break;
167 }
168
176 }
constexpr uint8_t SkToU8(S x)
SkEncodedInfo(const SkEncodedInfo &orig)=delete
◆ makeImageInfo()
Definition at line 183 of file SkEncodedInfo.h.
183 {
187 kN32_SkColorType ;
191 : nullptr;
192 if (!cs) {
194 }
196 }
@ kOpaque_SkAlphaType
pixel is opaque
@ kAlpha_8_SkColorType
pixel with alpha in 8-bit byte
@ kGray_8_SkColorType
pixel with grayscale level in 8-bit byte
@ kRGB_565_SkColorType
pixel with 5 bits red, 6 bits green, 5 bits blue, in 16-bit word
static sk_sp< SkColorSpace > MakeSRGB()
static sk_sp< SkColorSpace > Make(const skcms_ICCProfile &)
static SkImageInfo Make(int width, int height, SkColorType ct, SkAlphaType at)
◆ opaque()
bool SkEncodedInfo::opaque |
( |
| ) |
const |
|
inline |
◆ operator=() [1/2]
◆ operator=() [2/2]
◆ profile()
Definition at line 203 of file SkEncodedInfo.h.
203 {
204 if (!fProfile) return nullptr;
205 return fProfile->profile();
206 }
◆ profileData()
Definition at line 207 of file SkEncodedInfo.h.
207 {
208 if (!fProfile) return nullptr;
209 return fProfile->data();
210 }
◆ width()
int SkEncodedInfo::width |
( |
| ) |
const |
|
inline |
The documentation for this struct was generated from the following file: