Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
blog:x68_launcher_3 [2020/09/07 11:17] – [bmp.c / bmp.h] john | blog:x68_launcher_3 [2020/09/07 11:51] (current) – john | ||
---|---|---|---|
Line 2: | Line 2: | ||
==== bmp.c / bmp.h ==== | ==== bmp.c / bmp.h ==== | ||
+ | |||
+ | * https:// | ||
+ | * https:// | ||
The header includes these common files: | The header includes these common files: | ||
Line 116: | Line 119: | ||
* Check BMP is correct pixel depth and size | * Check BMP is correct pixel depth and size | ||
* Read pixel data | * Read pixel data | ||
+ | |||
+ | |||
+ | <code " | ||
+ | FILE *f; | ||
+ | int status; | ||
+ | |||
+ | f = fopen(" | ||
+ | if (f == NULL){ | ||
+ | | ||
+ | } | ||
+ | |||
+ | bmp = (bmpdata_t *) malloc(sizeof(bmpdata_t)); | ||
+ | bmp-> | ||
+ | status = bmp_ReadImageHeader(f, | ||
+ | if (status != 0){ | ||
+ | | ||
+ | | ||
+ | } | ||
+ | |||
+ | if (bmp-> | ||
+ | printf(" | ||
+ | } else ( | ||
+ | printf(" | ||
+ | status = bmp_ReadImageData(f, | ||
+ | ) | ||
+ | |||
+ | fclose(f); | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | [[blog: | ||
+ | |||
+ |