[][src]Function qt_gui::q_gray_3a

pub unsafe fn q_gray_3a(r: c_int, g: c_int, b: c_int) -> c_int

Returns a gray value (0 to 255) from the (r, g, b) triplet.

Calls C++ function: int qGray(int r, int g, int b).

C++ documentation:

Returns a gray value (0 to 255) from the (r, g, b) triplet.

The gray value is calculated using the formula (r * 11 + g * 16 + b * 5)/32.