11
Check the "demo - vdp2 plane".
While not exactly what you want, it does demonstrate the process of loading an indexed color targa file to a VDP2 background layer.
You could copy this structure entirely, and simply not rotate the background layer.
//jo_img bg;
//bg.data = NULL;
//jo_tga_loader(&bg, "BGO", image_to_load, JO_COLOR_Transparent);
//if (bg.data != NULL) {
//jo_set_background_sprite(&bg, 0, 0);
//jo_free_img(&bg);
//}
jo_img_8bits bg;
bg.data = NULL;
jo_tga_8bits_loader(&bg, "BG8", image_to_load, JO_COLOR_Transparent);
if (bg.data != NULL) {
jo_set_background_8bits_sprite(&bg, 0, false);
jo_free_img(&bg);
}
#include <jo/jo.h>
void my_draw(void) {
jo_set_printf_color_index(JO_COLOR_INDEX_White);
jo_printf(0, 0, "Hello World");
}
void jo_main(void) {
jo_core_init(JO_COLOR_Black);
jo_core_add_callback(my_draw);
jo_core_run();
}