additional precision made a difference in extents test
This commit is contained in:
parent
9e5180cd44
commit
5fff6ab002
@ -229,7 +229,7 @@ struct Number
|
||||
{
|
||||
return (int32_t)(value * 65536.0);
|
||||
}
|
||||
inline void set_real (double v) { value = (double)v; }
|
||||
inline void set_real (double v) { value = v; }
|
||||
inline double to_real (void) const
|
||||
{
|
||||
return value;
|
||||
|
@ -169,7 +169,7 @@ struct CFF2CSInterpEnv : CSInterpEnv<BlendArg, CFF2Subrs>
|
||||
{
|
||||
if (likely (scalars.len == arg.deltas.len))
|
||||
{
|
||||
float v = arg.to_real ();
|
||||
double v = arg.to_real ();
|
||||
for (unsigned int i = 0; i < scalars.len; i++)
|
||||
{
|
||||
v += scalars[i] * arg.deltas[i].to_real ();
|
||||
|
@ -171,7 +171,7 @@ test_extents_cff2_vsindex (void)
|
||||
g_assert_cmpint (extents.x_bearing, ==, 11);
|
||||
g_assert_cmpint (extents.y_bearing, ==, 656);
|
||||
g_assert_cmpint (extents.width, ==, 653);
|
||||
g_assert_cmpint (extents.height, ==, -656);
|
||||
g_assert_cmpint (extents.height, ==, -657);
|
||||
|
||||
result = hb_font_get_glyph_extents (font, 2, &extents);
|
||||
g_assert (result);
|
||||
|
Loading…
Reference in New Issue
Block a user