Port Window.c and crt.c from SDL2 to SDL3 - #137
Open
Grosama wants to merge 1 commit into
Open
Conversation
- Replace SDL_WINDOW_FULLSCREEN_DESKTOP with SDL_WINDOW_FULLSCREEN - Replace SDL_CreateWindow signature (removed x/y position params) - Replace SDL_CreateRenderer (removed index and flags params) - Add SDL_SetRenderVSync for vsync control - Replace SDL_RenderCopy with SDL_RenderTexture - Replace SDL_ShowCursor with SDL_HideCursor - Replace SDL_PRESSED/SDL_RELEASED with bool down in events - Replace SDL_QUIT/SDL_KEYDOWN etc with SDL_EVENT_* equivalents - Replace keysym.sym/mod with key/mod in SDL_KeyboardEvent - Replace SDL_JoystickGetAttached with SDL_JoystickConnected - Replace SDL_JoystickClose with SDL_CloseJoystick - Replace SDL_NumJoysticks with SDL_HasJoystick - Replace SDL_QueryTexture with SDL_GetTextureSize - Replace SDL_CreateRGBSurface with SDL_CreateSurface - Replace SDL_HINT_RENDER_SCALE_QUALITY with SDL_SetTextureScaleMode - Fix SDL_Init return type (bool in SDL3) - Use SDL_FRect instead of SDL_Rect for render destination
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Changes in Window.c and crt.c:
Tested on Windows with MSYS2 MinGW64 toolchain and SDL3 3.4.2.
Note: CMakeLists.txt may need adjustments depending on how SDL3 is installed on your platform.