#Creating a window & getting it's framebuffer?
23 messages · Page 1 of 1 (latest)
When your question is answered use !solved to mark the question as resolved.
Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question use !howto ask.
any reason why you dont want to use those ?
you normally use a graphics library and just render to a texture
those are approx. less than 50 lines of code in SDL2
It would be much easier to use sdl. If you really want to use win32 api, then you can follow the tutorial windows offers themselves
https://learn.microsoft.com/en-us/windows/win32/learnwin32/learn-to-program-for-windows
You'll have to translate some c++ code to c code though
In very broad terms, you would create the window with CreateWIndowEx() which will return a handle to the window (HWND). When it comes time to draw on this window, you would obtain a handle to a device context for the window with HDC hdc = GetDC(hwnd); This device context would then be used with all the drawing primatives to actually modify the window's frame buffer. When done drawing you would release the device context with ReleaseDC(hwnd, hdc);
But isn't SDL3 out?
But the source code itself is 3.0
what has the version to do with anything
when i tried using it a lot of things were changed
i added it as a submodule
and linked with it in CMake
a lot of things were renamed