Hard Work at Figuring out the Graphics

I should be finishing Re-Hoard and Reckless Abandon, but, other than doing most of the sprites at Re-Hoard, I spent most of my time trying to figure out how to display graphics through Libretro.

Basically, because I plan on using software rendering (which is more portable due to not dependent on any specific API), all I need to do is render to a framebuffer… or the backbuffer. I know that I am going to exclusively use .png files and, because of my choice of 2D retro-style graphics, the RGB565 format, but I do not know the exact procedure in displaying and moving graphics while targeting Libretro. I mean, I did not even know of RGB565 before reading the libretro.h file! LÖVE did not give me this much trouble!

I can use a sprite library, but those were made without the knowledge of Libretro, which means that they would render using SDL2 or OpenGL instead of the generic software rendering layer that Libretro uses. Even if I did find one that uses software rendering, I have trouble knowing how to write .png files to a framebuffer or backbuffer! Libretro does have its own png decoder, but I do not know how to use the thing! This is not even taking into account the Box2D or Chipmunk physics engines that I plan on using!

I still plan on going ahead with using straight C++ with Libretro instead of writing in Lua and running the resulting core through Lutro. After all, I prefer to be the closest possible to the Libretro library because I find that the extra control outweighs the difficulty. Besides, this knowledge would be helpful if I ever get a job at another game company. However, if this gets too difficult, then I shall use a Rust engine and rely on Libretro’s Rust wrapper, instead.