struct mrpt::img::TColorf

An RGBA color - floats in the range [0,1].

#include <mrpt/img/TColor.h>

struct TColorf
{
    //
fields

    float R = .0f;
    float G = .0f;

    // construction

    TColorf();

    TColorf(
        float r,
        float g,
        float b,
        float alpha = 1.0f
        );

    TColorf(const TColor& col);

    //
methods

    TColor asTColor() const;
};

Methods

TColor asTColor() const

Returns the 0-255 integer version of this color: RGBA_u8