| 436 | } |
| 437 | |
| 438 | float Color::toLinear(float in) { |
| 439 | const float a = 0.055f; |
| 440 | if (in <= 0.04045f) |
| 441 | return in / 12.92f; |
| 442 | return powf((in + a) / (1.0f + a), 2.4f); |
| 443 | } |
| 444 | |
| 445 | float Color::fromLinear(float in) { |
| 446 | const float a = 0.055f; |
no test coverage detected