# grimfang4/sdl-gpu

A library for high-performance, modern 2D graphics with SDL written in C.

Repository: https://github.com/grimfang4/sdl-gpu
Canonical: https://ross.abutalabs.com/products/sdl-gpu
Language: C
License: MIT
License Family: permissive
Last push: 2026-05-26T16:23:59+00:00

## Health v2 (maintenance only)
Score: 61/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 84, release rhythm 8, longevity 100
- inputs: {"age_days": 4186, "days_push": 99, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1240, forks 123 (observed 2026-08-28T04:04:06.145255+00:00)

## What it is
SDL_gpu is a C library providing high-performance, hardware-accelerated 2D rendering on top of SDL, with automatic batching, a shader API, and OpenGL/OpenGL ES backends. It offers an SDL 1.2-style API for sprites, geometry, blend states, and built-in primitive shapes.

## Use cases
- render 2D sprites with GPU acceleration in C
- build a 2D game with SDL and OpenGL batching
- draw primitive shapes like lines, rects, and polygons with hardware acceleration
- mix 2D rendering with explicit OpenGL 3D calls
- apply custom shaders to 2D rendering
- load and render PNG, BMP, and TGA images with rotation and scaling

## When to choose
- you want fast 2D rendering in C/C++ without writing OpenGL boilerplate
- you need automatic draw-call batching for many sprites
- you want an SDL-familiar API with shader support and blend state control
- you need to target OpenGL and OpenGL ES across desktop and mobile

## When to avoid
- you need 3D rendering as the primary focus
- you want a modern renderer built on SDL3's SDL_GPU API rather than this legacy project
- you need backends beyond OpenGL/OpenGL ES such as Vulkan, Metal, or Direct3D
- you prefer a higher-level game engine with scene management

## Facets
- artifact type: library
- maturity: maintenance
- function: graphics, image-processing, ui-components
- domain: graphics, cross-platform
- platform: windows, cpp, c, cross-platform, game-engine
- tags: sdl, 2d-graphics, opengl, sprite-rendering, shaders, hardware-accelerated, rendering-library, game-development, linux, macos

## Member repositories
- grimfang4/sdl-gpu (main) score 61

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:06.145255+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T05:09:52.449423+00:00, confidence not recorded.
  - readme: https://github.com/grimfang4/sdl-gpu (fetched 2026-08-28T04:04:06.145255+00:00, sha 530a9944605d)
- Data as of 2026-08-30T08:39:29.467469+00:00.
