46#define IMG_BUFFER_SIZE 307200
uint8_t buffer1[IMG_BUFFER_SIZE]
second raw image buffer that decoded from qoi image file
Definition main.c:57
uint8_t buffer0[IMG_BUFFER_SIZE]
Raw image buffer that decoded from qoi image file.
Definition main.c:54
void toggleDebugText(qoi_img_info_t *info)
Toggles printing debugging text.
Definition qoi_viewer.h:105
void draw_image(surface_t *disp, qoi_img_info_t info)
This function draws image decoded from QOI.
Definition qoi_viewer.c:50
qoi_error_code
Error codes for different situations when handling a QOI file.
Definition qoi_viewer.h:53
@ QOI_NOT_INITIALIZED
QOI Image not yet decoded.
Definition qoi_viewer.h:55
@ QOI_OK
QOI Image decoded successfully.
Definition qoi_viewer.h:57
@ QOI_INVAILD_FILE
Invaild QOI image file found.
Definition qoi_viewer.h:61
@ QOI_NO_FILENAME
Filename to the QOI image not passed to decoder.
Definition qoi_viewer.h:65
@ QOI_NO_FILE
No file found given a filename to the supposed QOI image.
Definition qoi_viewer.h:63
@ QOI_NULL_BUFFER
No buffer for image found.
Definition qoi_viewer.h:59
void openQOIFile(const char *filename, uint8_t *bytes, qoi_img_info_t *info)
This function decodes QOI file from from into the framebuffer.
Definition qoi_viewer.c:110
struct qoi_img_info qoi_img_info_t
Metadata about the QOI image and the QOI image viewer.
#define IMG_BUFFER_SIZE
Image buffer size: 320 pixels in width * 240 pixels in height * 4 channels.
Definition qoi_viewer.h:46
Metadata about the QOI image and the QOI image viewer.
Definition qoi_viewer.h:69
int channels
Number of channels of the QOI image where 3 is RGB and 4 is RGBA.
Definition qoi_viewer.h:77
char name[256]
Names of QOI file.
Definition qoi_viewer.h:86
int height
Height of the QOI image.
Definition qoi_viewer.h:74
float decodeTime
Decoding time in seconds.
Definition qoi_viewer.h:83
int width
Width of the QOI image.
Definition qoi_viewer.h:71
bool renderDebugFont
Whether to toggle displaying debug text upon pressing the Start button on the N64 controller.
Definition qoi_viewer.h:89
qoi_error_code error
Error code as the result of decoding.
Definition qoi_viewer.h:80