Site icon Libretro

Kronos 2.1.2 progress report (Sega Saturn emulator)

It has been some time since the last report, let’s try to go a bit more in-depth this time.

The OpenGL CS video renderer

The Saturn is a beast. It features 8 processors, among them are 2 custom graphics processors called VDP1 and VDP2. The VDP2 handled backgrounds, while the VDP1 handled sprites, textures and polygons.

The VDP1 was rendering “quads” line per line, the general idea was to interpolate endpoints along the horizontal edges, then to draw textured lines between those endpoints. It had to draw the lines with an extra pixel where the slope changed, so all of the pixels had a neighbor to the left, right, top, or bottom. They did this to prevent gaps between the lines.

A modern graphics APIs like OpenGL doesn’t know how to do that, because its rendering pipeline is based on triangle geometry, so basically it can’t reproduce VDP1 behavior. There are tricks like tesselation, but ultimately they are just workarounds for specific issues and not all-in-one solutions for this. Here is some good news though : with OpenGL 4.3, a new feature called compute shaders was introduced, you might have heard about it through Flycast’s order independent transparency, or N64’s parallel, this new component gives lots of flexibility to OpenGL, and allows the implementation of routines to render quads line per line. It is what this renderer is about : reproducing VDP1 behavior accurately.

Let’s do some comparison, from first to last, those images were shot from console, Mednafen/beetle, Kronos (OpenGL CS renderer), Kronos (the old OpenGL renderer, based on YabaSanshiro’s). There are 2 things noticeable related to this VDP1 behavior in those :

It’s possible to workaround those holes with the OpenGL renderer, but at the end of the day you end up creating other issues in the process. Until recently we used such workaround but, in the case of Sega Rally, it was magnifying the dots on the border of the road.

The only known downside of this new renderer is that it will require a fairly good GPU!

ST-V support was improved

While still a bit preliminary, some major rework was done recently on ST-V support :

Improvements on the Libretro port

There were some long-term issues with the Libretro implementation, but a lot of improvements were done about them :

Also, here is a summary of this core’s options :

On a sidenote, lots of other things were fixed/improved since my last report, but nothing seemed major so we decided to skip them. If you want to know more about this emulator, you can check the youtube channel, or join us on discord.

Exit mobile version