From 8e6080e73661cc8747b21b1153e4336796575cf7 Mon Sep 17 00:00:00 2001 From: Rudy Bousset Date: Fri, 14 Feb 2020 18:47:19 +0100 Subject: Norme is bav --- src/ft_draw_verline.c | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) (limited to 'src/ft_draw_verline.c') diff --git a/src/ft_draw_verline.c b/src/ft_draw_verline.c index f7e5a1c..6584bcb 100644 --- a/src/ft_draw_verline.c +++ b/src/ft_draw_verline.c @@ -1,7 +1,19 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* ft_draw_verline.c :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: rbousset +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2020/02/14 17:22:23 by rbousset #+# #+# */ +/* Updated: 2020/02/14 17:23:42 by rbousset ### ########lyon.fr */ +/* */ +/* ************************************************************************** */ + #include static void -ft_draw_floor(t_cub *cl, int32_t y, int32_t x) + ft_draw_floor(t_cub *cl, int32_t y, int32_t x) { while (y <= cl->wlist->y_size) { @@ -12,7 +24,7 @@ ft_draw_floor(t_cub *cl, int32_t y, int32_t x) } static void -ft_draw_ceil(t_cub *cl, int32_t y, int32_t x) + ft_draw_ceil(t_cub *cl, int32_t y, int32_t x) { int16_t i; @@ -26,7 +38,7 @@ ft_draw_ceil(t_cub *cl, int32_t y, int32_t x) } int8_t -ft_draw_verline(t_cub *cl, int32_t x, int32_t y1, int32_t y2, int32_t color) + ft_draw_verline(t_cub *cl, int32_t x, int32_t y1, int32_t y2) { int32_t y; int32_t t; @@ -47,7 +59,7 @@ ft_draw_verline(t_cub *cl, int32_t x, int32_t y1, int32_t y2, int32_t color) ft_draw_ceil(cl, y, x); while (y <= y2) { - *(int*)(cl->img.ptr + (x * 4 + (y * cl->img.sizeline))) = color; + *(int*)(cl->img.ptr + (x * 4 + (y * cl->img.sizeline))) = 0x0000ffaa; y++; } ft_draw_floor(cl, y, x); -- cgit v1.2.3