Create a game window using SDL3 and C

preview_player
Показать описание
🎮Hello friends! Today we're taking a look at creating a main function with the SDL3 preview release using C. SDL 3.1.0 Preview to be precise.

The SDL3 API sounds like it's fairly solid, but I'll keep an eye on the library as it hurtles towards its official release! Lots of enhancements and changes over SDL2, that I'll work to highlight on this channel.

🔗Links & References

👋🏻Connect with me

📖I'm also going through the Bible over at @BibleTimeWithWazoo

#gamedev #sdl3 #cprogramming
Рекомендации по теме
Комментарии
Автор

Wowowow. I bought your book on game programming a long time ago when I was beginning to learn. This was so unexpected; it's like meeting a school teacher after a long time. Happy to see you! Unreal.

jere
Автор

If you don't mind me asking, why should we choose SDL3 over SDL2? What's new in it

ArnabJhaYT
Автор

The create renderer function changed and you can use something like the following now. The migration notes showed that the accelerated flag is removed since all renderers are accelerated.
SDL_RendererFlags RendererFlags = 0;
renderer = SDL_CreateRenderer(window, "Window!", RendererFlags);

Burnrate
Автор

The callback-based program flow is significant because it enables web-based deployment of your C-based SDL3-based game. That in turn is useful for game jams or sharing with friends.

Unavailable
Автор

This is what I am excited about "SDL3 Introduces A Vulkan Renderer"

I was considering going with SFML as I am already familiar with it, but learned SDL3 was coming out and had a look at some of the things they were bringing to the table and was like, hell yeah! I am in.

Do you plan on doing a full tutorial series? Most of the SDL tutorials on YouTube are quite old and are not the best, so could be good to get up some before the influx of new tech videos pop up for SDL3.

Anyway, I really enjoyed the vid and just discovered this channel today.

cameronbelcher
Автор

What are YOU looking forward to using or learning about in SDL3?

ErikYuzwa
Автор

Don't you think adding the linking process would of been a great thing to include in the video?

bouz
Автор

Hi. I'm a complete beginner learning C, about to learn pointers and memory management. I want to eventually make simple games using sdl2, but now I've learnt of the existence of sdl3. Considering the amount of time each has been in use (SDL2 and SDL3) and the tutorials on these written strictly in C, should I learn sdl2 or sdl3?

maroofshah
Автор

May I know why we need to put a SDL_Delay(1) in the loop?

JunKaiGan
Автор

When is SDL3 going to be released (not prerelease)?

WyMustIGo
Автор

SDL3 is gonna come with a powerful GPU API. I think a tutorial series on a old-school C++ 3D game engine would be very useful. Especially if it reaches some sort of conclusion and not end after a few episodes. It doesn't have to be very powerful and fully-featured, something for games like quake 1, doom 1, counter-strike 1.6, unreal tournament 1. I hope somebody makes a tutorial on this - maybe you since you've already written a book about it before. There are some game engine series that are good but they span in the hundreds of videos or are unfinished. I think using a few libraries can help speed up things (sdl3 for windowing, graphics and audio; glm for math; imgui for engine UI or whatever else needed) and show a complete project suitable for beginners. There are enough videos in the category of "Make a game with { pygame, SFML, etc } framework", especially for 2D games. I want a proper 3D engine one.

Duerdak
Автор

I'm looking for an experienced SQL developer. For a paid job porting DX7 to SDL3 pure API without OpenGL. And who can also do some UI reconstruction to be more mobile friendly and stop being static. @Erik Yuzwa arent this a job for you ?

johnnycleiton.camargodossa
Автор

Dipping your toes into icebergs can't be good for global warming 😔

nateedwards
Автор

keysym is no longer being used now, the code should be:
if (event.key.key == SDLK_ESCAPE) { ...

chai