aboutsummaryrefslogtreecommitdiffstats
path: root/src/ft_tex_num_init.c
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-03-23 15:16:07 +0100
committerJozanLeClerc <bousset.rudy@gmail.com>2020-03-23 15:16:07 +0100
commita46856a951455d5bf9078355f2310e1cf1bbf230 (patch)
treea2d6e781c9da6c8d916693403b057c1f6b967f16 /src/ft_tex_num_init.c
parentGood start (diff)
download42-cub3d-a46856a951455d5bf9078355f2310e1cf1bbf230.tar.gz
42-cub3d-a46856a951455d5bf9078355f2310e1cf1bbf230.tar.bz2
42-cub3d-a46856a951455d5bf9078355f2310e1cf1bbf230.tar.xz
42-cub3d-a46856a951455d5bf9078355f2310e1cf1bbf230.tar.zst
42-cub3d-a46856a951455d5bf9078355f2310e1cf1bbf230.zip
It's going well
Diffstat (limited to '')
-rw-r--r--src/ft_tex_num_init.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/ft_tex_num_init.c b/src/ft_tex_num_init.c
index b17910a..34b5c11 100644
--- a/src/ft_tex_num_init.c
+++ b/src/ft_tex_num_init.c
@@ -13,6 +13,23 @@
#include <cub3d.h>
#include <mlx.h>
+/*
+** tnum[] index summary
+** ---------------------
+** 0: zero
+** 1: one
+** 2: two
+** 3: three
+** 4: four
+** 5: five
+** 6: six
+** 7: seven
+** 8: eight
+** 9: nine
+** 10: percent
+** 11: infinite
+*/
+
static void
ft_next_num_init(t_cub *cl)
{
@@ -36,6 +53,10 @@ static void
FT_PER_PATH, &cl->tnum[10].img_w, &cl->tnum[10].img_h);
cl->tnum[10].ptr = mlx_get_data_addr(cl->tnum[10].img,
&cl->tnum[10].bpp, &cl->tnum[10].sizeline, &cl->tnum[10].endian);
+ cl->tnum[11].img = mlx_xpm_file_to_image(cl->wlist.wlx,
+ FT_INF_PATH, &cl->tnum[11].img_w, &cl->tnum[11].img_h);
+ cl->tnum[11].ptr = mlx_get_data_addr(cl->tnum[11].img,
+ &cl->tnum[11].bpp, &cl->tnum[11].sizeline, &cl->tnum[11].endian);
}
void