A single-header C graphics library for recreational coding, prototyping, small games, and experimentation.
CGL (C Graphics Library) is a single-header, multipurpose library for graphics programming, small game development, and creative coding in C/C++. It bundles utilities for rendering, windowing, AI, data structures, and more into one file, simplifying prototyping and experimentation.
Hobbyist programmers, demo scene creators, and developers prototyping small games or graphical applications in C/C++ who want an all-in-one solution without complex setup.
Developers choose CGL for its minimal footprint, extensive feature set, and ease of integration—enabling rapid experimentation with graphics, AI, and utilities while maintaining cross-platform compatibility and performance.
CGL (C Game Library) is a multipurpose library mainly for recreational coding / demo scenes / prototyping / small games / experimentation.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
The entire library is contained in `cgl.h`, with implementation enabled only once via `#define CGL_IMPLEMENTATION`, drastically reducing setup time and easing integration into C/C++ projects.
Bundles graphics rendering, AI modules like neural networks, data structures, noise generation, and immediate-mode UI widgets, enabling rapid prototyping without external dependencies for many tasks.
Features can be excluded via defines such as `CGL_EXCLUDE_WINDOW_API`, allowing developers to trim unused parts and optimize for performance or size in constrained environments.
Supports Windows, Linux, macOS, and WebAssembly with abstractions for threading and networking, making it viable for hobbyist projects targeting multiple platforms.
WebAssembly support is marked as beta, macOS is untested, and Android is 'coming soon,' indicating instability and limited reliability for cross-platform deployment.
Key modules like text rendering require FreeType2, and SSL sockets need OpenSSL, adding setup complexity that contradicts the library's minimal footprint promise.
The README lists features with example links but lacks comprehensive API documentation, forcing developers to rely on source code inspection for advanced usage.
As a solo-maintained project, long-term updates, bug fixes, and community support are uncertain compared to larger, organization-backed libraries.