mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 01:47:34 +00:00
Meta+Userland: Pass Gfx::IntSize by value
Just two ints like Gfx::IntPoint.
This commit is contained in:
parent
e011eafd37
commit
27fae78335
63 changed files with 142 additions and 142 deletions
|
@ -20,12 +20,12 @@ static float normalized_gradient_angle_radians(float gradient_angle)
|
|||
return real_angle * (AK::Pi<float> / 180);
|
||||
}
|
||||
|
||||
static float calulate_gradient_length(Gfx::IntSize const& gradient_size, float sin_angle, float cos_angle)
|
||||
static float calulate_gradient_length(Gfx::IntSize gradient_size, float sin_angle, float cos_angle)
|
||||
{
|
||||
return AK::fabs(gradient_size.height() * sin_angle) + AK::fabs(gradient_size.width() * cos_angle);
|
||||
}
|
||||
|
||||
static float calulate_gradient_length(Gfx::IntSize const& gradient_size, float gradient_angle)
|
||||
static float calulate_gradient_length(Gfx::IntSize gradient_size, float gradient_angle)
|
||||
{
|
||||
float angle = normalized_gradient_angle_radians(gradient_angle);
|
||||
float sin_angle, cos_angle;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue