mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 19:37:35 +00:00
AK: Add to_radians and to_degrees math functions
This commit is contained in:
parent
9b7aa8f6b6
commit
494a8cb816
15 changed files with 40 additions and 40 deletions
|
@ -30,7 +30,7 @@ public:
|
|||
private:
|
||||
static FloatMatrix3x3 calculate_hue_rotate_matrix(float angle_degrees)
|
||||
{
|
||||
float const angle_rads = angle_degrees * (AK::Pi<float> / 180.0f);
|
||||
float const angle_rads = AK::to_radians(angle_degrees);
|
||||
float cos_angle = 0.;
|
||||
float sin_angle = 0.;
|
||||
AK::sincos(angle_rads, sin_angle, cos_angle);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue