Created
January 29, 2025 13:09
-
-
Save agvxov/409c151e1547532175ecfd273cedb09d to your computer and use it in GitHub Desktop.
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
| { // sdl_hw.c | |
| // @BAKE gcc $@ -o sdl_hw.out -Wall -Wpedantic $(pkg-config --cflags --libs sdl2) | |
| #include <SDL.h> | |
| signed main(int argc, char* argv[]) { | |
| SDL_Init(SDL_INIT_VIDEO); | |
| SDL_Window* window = SDL_CreateWindow("HW", 0, 0, 800, 800, SDL_WINDOW_SHOWN); | |
| SDL_Renderer* renderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_ACCELERATED); | |
| SDL_SetRenderDrawColor(renderer, 255, 0, 0, 255); | |
| SDL_RenderClear(renderer); | |
| SDL_RenderPresent(renderer); | |
| while (1) { ; } | |
| return 0; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment