aboutsummaryrefslogtreecommitdiffstats
path: root/inc
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-03-04 15:30:59 +0100
committerJozanLeClerc <bousset.rudy@gmail.com>2020-03-04 15:30:59 +0100
commitb15be48033300c00ed2981fb69928905e3a85e86 (patch)
tree83820c3fb66f4f610751ef92780cc1ec53ef7d53 /inc
parenttryna save (diff)
download42-cub3d-b15be48033300c00ed2981fb69928905e3a85e86.tar.gz
42-cub3d-b15be48033300c00ed2981fb69928905e3a85e86.tar.bz2
42-cub3d-b15be48033300c00ed2981fb69928905e3a85e86.tar.xz
42-cub3d-b15be48033300c00ed2981fb69928905e3a85e86.tar.zst
42-cub3d-b15be48033300c00ed2981fb69928905e3a85e86.zip
Init bmp
Diffstat (limited to 'inc')
-rw-r--r--inc/cub3d.h3
-rw-r--r--inc/cub3d_structs.h9
2 files changed, 11 insertions, 1 deletions
diff --git a/inc/cub3d.h b/inc/cub3d.h
index b1712c1..f7b1a22 100644
--- a/inc/cub3d.h
+++ b/inc/cub3d.h
@@ -29,6 +29,7 @@ int ft_init_winptr(t_cub *clist);
t_ray ft_init_s_ray(void);
t_rgb ft_init_rgb(void);
int8_t ft_init_map(t_map *mlist);
+t_bmp ft_init_bmp(void);
/*
** ====== HOOKS ======
@@ -120,7 +121,7 @@ void ft_set_minimap_scale(t_cub *clist);
void *ft_music_thread(void *vargp);
void ft_detect(t_cub *cl);
void ft_castray(t_cub *cl);
-int8_t ft_save_to_bmp(void *img, t_cub *cl);
+int8_t ft_save_to_bmp(t_bmp bmp, void *img, t_cub *cl);
int ft_error(const char *errmsg, t_cub *clist);
uint8_t ft_free_words(char **words);
int8_t ft_warp_level(t_cub *cl);
diff --git a/inc/cub3d_structs.h b/inc/cub3d_structs.h
index ae5ee02..df26c26 100644
--- a/inc/cub3d_structs.h
+++ b/inc/cub3d_structs.h
@@ -28,6 +28,15 @@ typedef struct s_win
uint32_t y_size;
} t_win;
+typedef struct s_bmp
+{
+ uint16_t file_type;
+ uint32_t file_size;
+ uint16_t reserv_one;
+ uint16_t reserv_two;
+ uint32_t offset_data;
+} t_bmp;
+
typedef struct s_img
{
void *img;