third_party/cairo/src/cairo-pattern.c
static int
use_bilinear(double x, double y, double t)
{
    /* This is the inverse matrix! */
    double h = x*x + y*y;
    if (h < 1.0 / (0.75 * 0.75))
	return TRUE; /* scale > .75 */
    if ((h > 3.99 && h < 4.01) /* scale is 1/2 */
	&& !_cairo_fixed_from_double(x*y) /* parallel to an axis */
	&& _cairo_fixed_is_integer (_cairo_fixed_from_double (t)))
	return TRUE;
    return FALSE;
}
/*
 * Will given row of back-translation matrix work with bilinear scale?
 * This is true for scales larger than 1. Also it was judged acceptable
 * for scales larger than .75. And if there is integer translation
 * then a scale of exactly .5 works.
 */
Will given row of back-translation matrix work with bilinear scale.
This is true for scales larger than 1. Also it was judged acceptable
for scales larger than .75. And if there is integer translation
then a scale of exactly .5 works.
Will given row of back - translation matrix work with bilinear scale . This is true for scales larger than 1 . Also it was judged acceptable for scales larger than . 75 . And if there is integer translation then a scale of exactly . 5 works .
static int
use_bilinear(double x, double y, double t)
{
    double h = x*x + y*y;
    if (h < 1.0 / (0.75 * 0.75))
	return TRUE; 
    if ((h > 3.99 && h < 4.01) 
	&& !_cairo_fixed_from_double(x*y) 
	&& _cairo_fixed_is_integer (_cairo_fixed_from_double (t)))
	return TRUE;
    return FALSE;
}
static int use_bilinear ( double x , double y , double t ) { double h = x * x + y * y ; if ( h < 1.0 / ( 0.75 * 0.75 ) ) return TRUE ; if ( ( h > 3.99 && h < 4.01 ) && ! _cairo_fixed_from_double ( x * y ) && _cairo_fixed_is_integer ( _cairo_fixed_from_double ( t ) ) ) return TRUE ; return FALSE ; }
Will given row of back-translation matrix work with bilinear scale?
Will given row of back - translation matrix work with bilinear scale?
/* This is the inverse matrix! */ /* scale > .75 */ /* scale is 1/2 */ /* parallel to an axis */