Backends: Start adding sdl2 surface

This commit is contained in:
moonpower
2025-12-24 23:17:37 +03:00
parent 922a11f084
commit f2703c1015
4 changed files with 365 additions and 0 deletions
+14
View File
@@ -0,0 +1,14 @@
// imgui_impl_sdlsurface2.h
// CPU-only SDL_Surface backend for Dear ImGui
#pragma once
#include "imgui.h"
#include <SDL.h>
// Initialize with target SDL_Surface (32-bit RGBA)
IMGUI_API bool ImGui_ImplSDLSurface2_Init(SDL_Surface* surface);
IMGUI_API void ImGui_ImplSDLSurface2_Shutdown();
IMGUI_API void ImGui_ImplSDLSurface2_NewFrame();
IMGUI_API void ImGui_ImplSDLSurface2_RenderDrawData(ImDrawData* draw_data);
IMGUI_API SDL_Surface* ImGui_ImplSDLSurface2_CreateFontAtlasSurface();