tiny-skia-cpp
A C++20 2D rendering library (port of tiny-skia)
Loading...
Searching...
No Matches
Color.h File Reference

Color types (8-bit and floating-point, straight and premultiplied). More...

#include <array>
#include <cstdint>
#include <optional>
#include "tiny_skia/FloatingPoint.h"
#include "tiny_skia/Math.h"
#include "tiny_skia/pipeline/Pipeline.h"
Include dependency graph for Color.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  tiny_skia::ColorU8
 8-bit RGBA color (straight alpha). More...
 
class  tiny_skia::PremultipliedColorU8
 8-bit RGBA color (premultiplied alpha). Internal pixel format. More...
 
class  tiny_skia::Color
 Floating-point RGBA color [0,1] (straight alpha). More...
 
class  tiny_skia::PremultipliedColor
 Floating-point RGBA color [0,1] (premultiplied alpha). More...
 

Typedefs

using tiny_skia::AlphaU8 = std::uint8_t
 8-bit alpha value.
 

Enumerations

enum class  tiny_skia::ColorSpace { Linear , Gamma2 , SimpleSRGB , FullSRGBGamma }
 Colorspace for gamma-correct blending. More...
 

Enumeration Type Documentation

◆ ColorSpace

enum class tiny_skia::ColorSpace
strong
Enumerator
Linear 

Linear RGB (no gamma).

Gamma2 

Power-of-2 gamma approximation.

SimpleSRGB 

Simplified sRGB transfer function.

FullSRGBGamma 

Full sRGB gamma curve.