coreboot-kgpe-d16/payloads
Yu-Ping Wu 1c3faabf24 libpayload/cbgfx: Remove gap between adjacent boxes
When drawing two adjacent boxes with draw_box(), there will be a gap
between them. This is due to the truncation in integer division when
calculating the bottom right coordinate of the box.

In this patch, the relative bottom right coordinate is calculated before
transforming to an absolute one. The same issue is also fixed for
draw_rounded_box().

Also check validity of 'pos_rel' and 'dim_rel' arguments for
draw_rounded_box().

BRANCH=none
BUG=chromium:1082593
TEST=emerge-nami libpayload

Change-Id: I073cf8ec6eb3952a0dcb417b4c3c3c7047567837
Signed-off-by: Yu-Ping Wu <yupingso@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/41392
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2020-05-26 15:03:59 +00:00
..
coreinfo treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
external treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
libpayload libpayload/cbgfx: Remove gap between adjacent boxes 2020-05-26 15:03:59 +00:00
linuxcheck treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
nvramcui treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
Kconfig payloads/nvramcui: Select USE_OPTION_TABLE 2020-04-09 15:27:30 +00:00
Makefile.inc treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00