Blender
V3.3
|
#include <BLI_color.hh>
Public Member Functions | |
constexpr | ColorSceneLinear4f () |
constexpr | ColorSceneLinear4f (const float *rgba) |
constexpr | ColorSceneLinear4f (float r, float g, float b, float a) |
ColorSceneLinearByteEncoded4b< Alpha > | encode () const |
ColorSceneLinear4f< eAlpha::Premultiplied > | premultiply_alpha () const |
ColorSceneLinear4f< eAlpha::Straight > | unpremultiply_alpha () const |
![]() | |
constexpr | ColorRGBA ()=default |
constexpr | ColorRGBA (const float rgba[4]) |
constexpr | ColorRGBA (const float r, const float g, const float b, const float a) |
operator float * () | |
operator const float * () const | |
uint64_t | hash () const |
Additional Inherited Members | |
![]() | |
float | r |
float | g |
float | b |
float | a |
Definition at line 153 of file BLI_color.hh.
|
inlineconstexpr |
|
inlineconstexpr |
Definition at line 131 of file BLI_color.hh.
|
inlineconstexpr |
Definition at line 131 of file BLI_color.hh.
|
inline |
Convert to its byte encoded counterpart.
Definition at line 172 of file BLI_color.hh.
References linearrgb_to_srgb_uchar4().
Referenced by blender::bke::bool_to_byte_color(), blender::bke::float2_to_byte_color(), blender::bke::float3_to_byte_color(), blender::bke::float_to_byte_color(), blender::bke::int8_to_byte_color(), blender::bke::int_to_byte_color(), and blender::tests::TEST().
|
inline |
Convert color and alpha association to premultiplied alpha.
Does nothing when color already has a premultiplied alpha.
Definition at line 184 of file BLI_color.hh.
References blender::Straight, and straight_to_premul_v4_v4().
Referenced by blender::tests::TEST(), and blender::compositor::ConvertStraightToPremulOperation::update_memory_buffer_partial().
|
inline |
Convert color and alpha association to straight alpha.
Does nothing when color has straight alpha.
Definition at line 201 of file BLI_color.hh.
References premul_to_straight_v4_v4(), and blender::Premultiplied.
Referenced by blender::tests::TEST(), and blender::compositor::ConvertPremulToStraightOperation::update_memory_buffer_partial().