MCPcopy Create free account
hub / github.com/arrayfire/forge / setColor

Method setColor

src/api/cpp/surface.cpp:45–53  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

43}
44
45void Surface::setColor(const Color pColor)
46{
47 float r = (((int) pColor >> 24 ) & 0xFF ) / 255.f;
48 float g = (((int) pColor >> 16 ) & 0xFF ) / 255.f;
49 float b = (((int) pColor >> 8 ) & 0xFF ) / 255.f;
50 float a = (((int) pColor ) & 0xFF ) / 255.f;
51
52 FG_THROW(fg_set_surface_color(get(), r, g, b, a));
53}
54
55void Surface::setColor(const float pRed, const float pGreen,
56 const float pBlue, const float pAlpha)

Callers

nothing calls this directly

Calls 1

fg_set_surface_colorFunction · 0.85

Tested by

no test coverage detected