#ifndef __G_IMAGES_H__
#define __G_IMAGES_H__

#include <gear/base.h>

#define G_IMAGE_CHANNELS 4

#define G_IMAGE_MISSING_PIXELS (u8*)(u32[4]){ 0xFFFF00FF, 0xFF000000, 0xFF000000, 0xFFFF00FF }
#define G_IMAGE_MISSING_DIMENSIONS 2
#define G_IMAGE_MISSING_BYTESIZE sizeof(u32) * (G_IMAGE_MISSING_DIMENSIONS * G_IMAGE_MISSING_DIMENSIONS)

typedef struct g_image {
    i32 width;
    i32 height;
    i32 channels;
    u8* pixels;
} g_image;

// src/images/create.c
g_image* g_image_create(u8* pixels, i32 width, i32 height);
g_image* g_image_default();

// src/images/load.c
g_image* g_image_load(const char* filename);

// src/images/destroy.c
void g_image_destroy(g_image* image);

#endif
