working on xpm implementation

This commit is contained in:
Kbz-8
2023-04-04 15:41:45 +02:00
parent d360c8fb6a
commit f4bf7ea6b7
8 changed files with 145 additions and 28 deletions

View File

@@ -6,7 +6,7 @@
/* By: maldavid <kbz_8.dev@akel-engine.com> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2022/10/04 21:49:46 by maldavid #+# #+# */
/* Updated: 2023/04/03 11:18:41 by maldavid ### ########.fr */
/* Updated: 2023/04/04 13:43:04 by maldavid ### ########.fr */
/* */
/* ************************************************************************** */
@@ -47,6 +47,7 @@ namespace mlx::core
inline void pixelPut(void* win_ptr, int x, int y, int color) const noexcept;
void* newTexture(int w, int h);
void* newXpmTexture(char** data, int* w, int* h);
void* newStbTexture(char* file, int* w, int* h); // stb textures are format managed by stb image (png, jpg, bpm, ...)
char* mapTexture(void* img_ptr, int* bits_per_pixel, int* size_line, int* endian);
inline void texturePut(void* win_ptr, void* img, int x, int y);