coreboot-kgpe-d16/payloads/libpayload/drivers/video
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
..
bitmap.h treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
corebootfb.c treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
font.c treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
font.h treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
font8x16.c treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
font8x16.h treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
geodelx.c treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
graphics.c libpayload/cbgfx: Remove gap between adjacent boxes 2020-05-26 15:03:59 +00:00
vga.c treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00
video.c treewide: Remove "this file is part of" lines 2020-05-11 17:11:40 +00:00