Looks like cross-platform game development with SDL is going to get easier, as Ryan Gordon (also known as Icculus) has confirmed an Epic MegaGrant and details what it will be used for.
What is SDL? Simple DirectMedia Layer (SDL) is a cross-platform development library designed to provide low level access to audio, keyboard, mouse, joystick, and graphics hardware. It is used by video playback software, emulators, popular games and some game engines.
Ryan Gordon is one of the people responsible for its development, and Gordon has also ported plenty of games to Linux, macOS and other platforms over many years. In a new post on Patreon, a fun announcement was detailed about an approved Epic MegaGrant and how it's going to be used to improve SDL.
Previously if people wanted more than what SDL could do on a graphics level, they would be told something like "use OpenGL directly". Not great advice now, with Vulkan being pushed forwards and Vulkan is a much more modern and performant API to use for games. The problem is, Vulkan is also quite complicated. As the post mentions:
"It seems bonkers to tell people 'write these three lines of code to make a window, and then 2000 more to clear it,' but that's the migration funnel--and meat grinder--that SDL users are eventually going to get shoved into, and that's unacceptable to me." - Ryan Gordon.
What to do it about it then? Make working with Vulkan easier, by upgrading SDL to have a "simple, cross-platform, hopefully pleasant-to-use interface that Just Works and finds the best way to get things done with what it finds on the end-user's system" - Ryan Gordon.
Speaking to me on Twitter to spell it out even clearer, Gordon said:
"It’s going to be new SDL APIs that expose the functionality of Vulkan but do it with whatever API behind the scenes (Vulkan, Metal, Direct3D etc). There will be some limitations, but I think it will make the next-gen APIs way more accessible to people that aren’t AAA engine devs."
"In the same way that SDL currently provides functions to say 'get this window on the screen and this sound to the audio device and I don’t care how you _actually_ do it.'"
This sounds like a really great project, and hopefully something game developers will appreciate.
Hope this update goes well. And I understand that if anyone wants to use opengl/vulkan in raw, they will be able to use it, like the other parts of sdl.
Last edited by Shmerl on 12 November 2021 at 8:37 pm UTC
Quoting: ShmerlIsn't there gfx-rs for that? It provides a simpler API than raw Vulkan but it's built on top of Vulkan. I hope SDL won't start making a new one with the same idea.gfx-rs went into maintenance mode and the Rust ecosystem seems to be moving towards wgpu. Either way, it's not very helpful for people that insist on writing in C or C++, and I guess for that purpose an SDL wrapper would be useful.
Some of his work still runs perfectly to this day, even if the Loki installers don't. For example, Unreal Tournament 2004... in one of his patches he included a 64 bit build. I still run that SAME game (with the directory copied to new computers over the years) on a pure 64 bit system simply by dropping some older 64 bit libraries in the program directory. (e.g. libstdc++.so.5)
I still have some digital and boxed versions of games like Postal 2 (LGP), Eric's Ultimate Solitaire, Heavy Metal: FAKK 2, Candy Cruncher, and so on. I don't even count how many times I played Postal 2 and Lugaru on Linux.
It's such a shame that he probably didn't get paid to finish the Linux version of Medal of Honor. It's an excellent game, and I know the Linux version is buggy. However, I don't regret that I spend about 17$ to buy an old computer to run Medal of Honor for Linux without any crashes. It was a great game when kernel 2.4 was popular on PCs, and I highly recommend it.
Quotewrite these three lines of code to make a window, and then 2000 more to clear it
Hrm, I'm kind of annoyed with the persistence of this mindset. My entire Vk renderer is ~1200 sloc compared to my GL3 renderer at ~900 sloc. Yes, it's more complicated, and I would have been pretty lost if it was my first rodeo. It doesn't take thousands of lines of code to draw a triangle with Vulkan though, and I'm kind of annoyed that people keep saying so and discouraging others to even try it. :(
That said, there's a good 200-300 sloc of any Vk renderer that's just sort of "free" with GL. You don't have to carefully initialize a device to get sane defaults, and you need very little effort to get a framebuffer + sync. Khronos could make a reasonable library to simplify those parts of the API for 99% of the use cases I feel.
Last edited by slembcke on 13 November 2021 at 2:45 am UTC
one or some?
one developers?
Quoting: slembckeQuotewrite these three lines of code to make a window, and then 2000 more to clear it
Hrm, I'm kind of annoyed with the persistence of this mindset. My entire Vk renderer is ~1200 sloc compared to my GL3 renderer at ~900 sloc. Yes, it's more complicated, and I would have been pretty lost if it was my first rodeo. It doesn't take thousands of lines of code to draw a triangle with Vulkan though, and I'm kind of annoyed that people keep saying so and discouraging others to even try it. :(
That said, there's a good 200-300 sloc of any Vk renderer that's just sort of "free" with GL. You don't have to carefully initialize a device to get sane defaults, and you need very little effort to get a framebuffer + sync. Khronos could make a reasonable library to simplify those parts of the API for 99% of the use cases I feel.
afaik the whole point of vulkan is that openGL was abstracting too much stuff, while on vulkan you have to understand what is happening behind the scenes, because those assumptions that the driver/compiler/library did for you, werent the best options in terms of performance.
if we gonna abstract everything again, we might as well just go back to openGL instead.
the same goes for dx12 against 11 and the previous ones.
See more from me