setos

拙OS
Log | Files | Refs | LICENSE

commit 86dac8fe036182531cf5d7a26e618976c22f8d3e
parent f6ba90b8f9f40402ddeb1e7a82ecec65b19ede5c
Author: Matsuda Kenji <info@mtkn.jp>
Date:   Tue,  2 Apr 2024 15:44:49 +0900

fix bug where the pixels at the top and left border is not rendered

Diffstat:
Msys/src/kernel/draw.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sys/src/kernel/draw.c b/sys/src/kernel/draw.c @@ -20,7 +20,7 @@ init_root_window(RGBA32 *fb_base, int hres, int vres, int ppsl) void pixel(Window *dst, Point p, RGBA32 col) { - if (0 < p.x && p.x < dst->hres && 0 < p.y && p.y < dst->vres) { + if (0 <= p.x && p.x < dst->hres && 0 <= p.y && p.y < dst->vres) { dst->fb[p.y * dst->ppsl + p.x] = col; } }