From d6c4f757a4bfeabfea35804103cfce10650a101e Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Wed, 29 Jun 2022 11:09:54 -0600 Subject: [PATCH] [avar2] Clamp out values --- src/hb-ot-var-avar-table.hh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hb-ot-var-avar-table.hh b/src/hb-ot-var-avar-table.hh index a76f5ad08..e702517a3 100644 --- a/src/hb-ot-var-avar-table.hh +++ b/src/hb-ot-var-avar-table.hh @@ -195,7 +195,7 @@ struct avar uint32_t varidx = varidx_map.map (i); float delta = var_store.get_delta (varidx, coords, coords_length); v += round (delta); - /* TODO Clamp v? */ + v = hb_clamp (v, -(1<<14), +(1<<14)); out.push (v); }