backends/native: Update MetaBezier coding style for modern standards
Let's try to get past that pesky code-style checker. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3399>
This commit is contained in:
parent
414357a70f
commit
f2ed377f48
@ -64,18 +64,18 @@ struct _MetaBezier
|
|||||||
* bezier coefficients -- these are calculated using multiplication and
|
* bezier coefficients -- these are calculated using multiplication and
|
||||||
* addition from integer input, so these are also integers
|
* addition from integer input, so these are also integers
|
||||||
*/
|
*/
|
||||||
gint ax;
|
int ax;
|
||||||
gint bx;
|
int bx;
|
||||||
gint cx;
|
int cx;
|
||||||
gint dx;
|
int dx;
|
||||||
|
|
||||||
gint ay;
|
int ay;
|
||||||
gint by;
|
int by;
|
||||||
gint cy;
|
int cy;
|
||||||
gint dy;
|
int dy;
|
||||||
|
|
||||||
/* length of the bezier */
|
/* length of the bezier */
|
||||||
guint length;
|
unsigned int length;
|
||||||
};
|
};
|
||||||
|
|
||||||
MetaBezier *
|
MetaBezier *
|
||||||
@ -93,8 +93,9 @@ meta_bezier_free (MetaBezier * b)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static gint
|
static int
|
||||||
meta_bezier_t2x (const MetaBezier * b, _FixedT t)
|
meta_bezier_t2x (const MetaBezier *b,
|
||||||
|
_FixedT t)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
* NB -- the int coefficients can be at most 8192 for the multiplication
|
* NB -- the int coefficients can be at most 8192 for the multiplication
|
||||||
@ -104,8 +105,9 @@ meta_bezier_t2x (const MetaBezier * b, _FixedT t)
|
|||||||
+ b->dx;
|
+ b->dx;
|
||||||
}
|
}
|
||||||
|
|
||||||
static gint
|
static int
|
||||||
meta_bezier_t2y (const MetaBezier * b, _FixedT t)
|
meta_bezier_t2y (const MetaBezier *b,
|
||||||
|
_FixedT t)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
* NB -- the int coefficients can be at most 8192 for the multiplication
|
* NB -- the int coefficients can be at most 8192 for the multiplication
|
||||||
@ -277,7 +279,7 @@ meta_bezier_init (MetaBezier *b,
|
|||||||
int x = meta_bezier_t2x (b, t);
|
int x = meta_bezier_t2x (b, t);
|
||||||
int y = meta_bezier_t2y (b, t);
|
int y = meta_bezier_t2y (b, t);
|
||||||
|
|
||||||
guint l = sqrti ((y - yp)*(y - yp) + (x - xp)*(x - xp));
|
unsigned int l = sqrti ((y - yp) * (y - yp) + (x - xp) * (x - xp));
|
||||||
|
|
||||||
l += length[i - 1];
|
l += length[i - 1];
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user