reformat and better bmp all in one function

This commit is contained in:
2025-06-03 19:41:53 +02:00
parent 43927dadf4
commit 9a819f3a81
5 changed files with 92 additions and 122 deletions
+3 -9
View File
@@ -1,9 +1,3 @@
#include <stdlib.h>
#define HEADER_SIZE 54
char *bmp_header(unsigned long width, unsigned long height, unsigned long color_depth);
unsigned long bmp_data_line_length(unsigned long width, unsigned long color_depth);
char *bmp_data_line(unsigned long width, unsigned long color_depth, char *data, unsigned long data_offset);
unsigned long bmp_data_length(unsigned long width, unsigned long height, unsigned long color_depth);
char *bmp_data(unsigned long width, unsigned long height, unsigned long color_depth, char *data);
void bmp_generate(unsigned long width, unsigned long height,
unsigned int color_depth, char *file_path,
void generate_line(unsigned long y, char *data_buffer));