struct mrpt::img::TColorf

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

#include <mrpt/img/TColor.h>

struct TColorf
{
    //
fields

    float R;
    float G;

    // construction

    TColorf(
        float r = 0,
        float g = 0,
        float b = 0,
        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.