diff options
Diffstat (limited to 'src/ft_darken_rgb.c')
-rw-r--r-- | src/ft_darken_rgb.c | 32 |
1 files changed, 14 insertions, 18 deletions
diff --git a/src/ft_darken_rgb.c b/src/ft_darken_rgb.c index 434fcf8..656aac7 100644 --- a/src/ft_darken_rgb.c +++ b/src/ft_darken_rgb.c @@ -29,22 +29,18 @@ uint32_t return (ft_rgb_to_hex(darker)); } -uint32_t - ft_darken_floor(t_rgb rgb, float dist, t_cub *cl) -{ - t_rgb darker; - float calc; +/* uint32_t */ +/* ft_darken_floor(t_rgb rgb, int32_t y, t_cub *cl) */ +/* { */ +/* t_rgb darker; */ +/* float calc; */ - /* calc = ((float)(y + (75000.0 / cl->wlist.y_size)) */ - /* / (cl->wlist.y_size / 2)) - 1.0; */ - /* calc = (calc < 0) ? (0) : (calc); */ - (void)cl; - calc = (dist * 0.4); - calc = (calc >= 255) ? (255) : (calc); - calc = (calc < 1) ? (1) : (calc); - darker = rgb; - darker.r *= calc; - darker.g *= calc; - darker.b *= calc; - return (ft_rgb_to_hex(darker)); -} +/* calc = ((float)(y + (75000.0 / cl->wlist.y_size)) */ +/* / (cl->wlist.y_size / 2)) - 1.0; */ +/* calc = (calc < 0) ? (0) : (calc); */ +/* darker = rgb; */ +/* darker.r *= calc; */ +/* darker.g *= calc; */ +/* darker.b *= calc; */ +/* return (ft_rgb_to_hex(darker)); */ +/* } */ |