SDL Vulkan 2d api is ready now, and Vulk is the default renderer to use too now. You should make a tutorial about 2d vulkan, which I can't find anywhere else still
@MikeShah3 ай бұрын
Will consider that! SDL has some 3D GPU API also that just had a pull request -- exciting things ahead with SDL3!
@Earthium27 күн бұрын
I'm getting into the SDL_GPU. It's new and there's no tutorials and this seems astronomically more difficult than using SDL2 with opengl. I think SDL3 hitting the complexity of single game developers I don't think it's really worth the time to learn until someone can make like a simple tutorial, which this video was posted a year ago, it'll likely be a few more years.
@MikeShah26 күн бұрын
SDL is finally ABI stable, so I can start producing more videos :) 2025 will be the new SDL3 series, and I plan on covering lots of the parts of the API, including the GPU for basic 3D graphics.
@Garfield_Minecraft2 ай бұрын
I'm still using SDL2.. did they bundle SDL_ttf SDL_image SDL_mixer in SDL3? if they did that would be awesome. all in one
@MariusGiurgi Жыл бұрын
Neat. hopefully you will take a deeper dive into SDL3 features.. and how it is different than SDL2 etc.
@MikeShah Жыл бұрын
Cheers! Awaiting the official release, SDL3 docs are continue to pop up however!
@MariusGiurgi Жыл бұрын
@@MikeShah any idea what’s the estimated release date ?
@MikeShah Жыл бұрын
@@MariusGiurgi I recall them saying end of summer at the Game Developers Conference (GDC) -- so I imagine sometime soon? There's probably a dev branch on GitHub I would imagine.
@sophiacristina Жыл бұрын
I noticed some changes indeed. Some examples got me the first moment i used it: The pause function for audio is a little different iirc. There is now a function to play and another to pause and you add the device in the parameters: SDL_PlayAudioDevice(device_id); // New SDL_PauseAudio(0); // Old SDL_PauseAudioDevice(device_id); // New SDL_PauseAudio(1); // Old If i also remember correctly, it now don't have the 'OpenAudio' function and then you should open the audio with 'SDL_OpenAudioDevice'. And the function for the window frame also changed a little and the SDL2 code does not work on the SDL3.
@ItsYouAreNotYour Жыл бұрын
Why not use SDL_Mixer? Mix_PlayChannel() Mix_PlayMusic() Mix_PauseMusic()
@MikeShah Жыл бұрын
Interesting -- noted
@sophiacristina Жыл бұрын
@@ItsYouAreNotYour Ty for the tip, i'm kinda new on SDL yet. However, the SDL_Mixer seems to be about audio file, which seems cool and i'm going to get it. But i'm also manipulating the raw audio data and adding to the audio buffer directly, like, directly from sin(x) to the speaker. Is SDL_Mixer able to do that?
@sophiacristina Жыл бұрын
@@ItsYouAreNotYour I got the notification and i could read the post that was strangely removed, pretty strange... KZbin have an AI that may have found something offensive on your comment and auto-deleted it. Ty once again! :) This 'Twops' seems to be what i'm looking for. Yes, PCM, but one that is played constantly in a circular buffer. But by the description it looks like what i need. Cost nothing to try anyway, haha. What i'm doing is opening a device and using SDL_PauseAudio(0). Then at one moment of my program it calls a function like this example: "double y = some_synth(phase + x * freq * 2 * pi)". Then i add 'y' to the buffer that is pointed in one of the parameters of the SDL audio callback function (ex.: uint8_t buf[samples]), like the example: "buf[n] = (y + 1) * 127.5; // or any other bitdepth" Then it keeps playing anything i synthesize, since it is a circular buffer.
@ItsYouAreNotYour Жыл бұрын
@@sophiacristina Interesting. Yeah, as I stated in the message that got deleted. My PFC Sine wave UPS System uses something along those lines. I'd imagine instead of audio, it's with power. Anyway, yes, the mixer should be able to do what you are talking about. You will have to look into creating your own Mix_Chunk object, and you can edit that data on the fly and call it like you would any other sound data using the mixer. There is also a callback function that accepts raw data. Let me know if it works! Good luck!
@2dapoint424 Жыл бұрын
I hope they have a static build release so I dont have to rebuild the source or add the .dll / .so with the game!
@MikeShah Жыл бұрын
Yup, let's see!
@VoidloniXaarii Жыл бұрын
So exciting! I just want to open a window, draw a sphere, hopefully with hardware acceleration , in Linux while hoping my code will make a Windows executable too. The dream lives in 20 years later
@MikeShah Жыл бұрын
I think the 3D api is going to be a huge step to getting 3d graphics up and running fast. Vulkan, metal, D3D, etc still will be needed, but nice for some apps to get 3D up and running.
@PomuLeafEveryday Жыл бұрын
All I've wanted was a fast solution to Mode 7, SNES style 3D, all I wanted was matrix transformations on textures, didn't need the whole opengl API. Hopefully SDL3 does it well.
@sean721888 Жыл бұрын
Which 2D graphic library you recommend use SDL with ?
@MikeShah Жыл бұрын
The 2D API itself is fine enough to get things drawing, and folks have used it for commercial games. It's probably worth it to eventually learn enough OpenGL to render a quad and take advantage of the shader languages for further work. If you purely want to make 2D games and have no interest otherwise in building more abstractions, SFML may be a more complete solution without having to add too much more infrastructure (i.e. image loading, texture functions, etc.)
@phraggers Жыл бұрын
I thought valve prevented their employees from counting to 3
@MikeShah Жыл бұрын
Fingers crossed we see Half-Life 3 some day!
@bsdooby Жыл бұрын
SFML vs. SDL?
@MikeShah Жыл бұрын
I like both in general. If you need more platforms and different apis(e.g. metal, vulkan, etc) I recommend SDL. If you're just in C++ and target desktop and mobile then I recommend sfml
@bsdooby Жыл бұрын
@@MikeShah Thank you for your insight...Then I will focus on the SDL (D, C++, and some .NET in the mix)...
@mahdies56 Жыл бұрын
Hello Mike, May you make videos for boost asio and networking plz
@MikeShah Жыл бұрын
Will add to the wishlist!
@thearguenaut3187 Жыл бұрын
can you use D with sdl3?
@MikeShah Жыл бұрын
Sure can -- bindbc-sdl is the most stable binding as I understand