What is GGlib
GGlib is a collection of libraries, or packages, for creating real-time 3D web applications, such as games or anything else that requires 3D rendering in the browser.
Each package solves a specific problem domain while staying as independent as possible. When working with GGlib, you decide what level of abstraction your project needs, and where you draw the line to bring in your own custom architecture.
Each block builds on the blocks below it.
Why?
GGlib is a personal project. It is where I do my research and experiments in graphics and game engine programming, a hobby that started back in the days of XNA and never really stopped.
Engines and frameworks make many decisions for you, and that is a good thing until you want to try something they were not designed for. I wanted a codebase where I own the whole frame: resource creation, scene traversal and visibility detection, render pass orchestration and what ends up on the GPU. When an idea needs a change in the internals, I change the internals, instead of working around them.
GGlib is not meant to compete with Three.js, Babylon.js or PlayCanvas. Those are mature projects built by large communities, and GGlib borrows ideas from them.
Should I use it?
WARNING
GGlib is not stable. APIs change whenever an idea needs them to, often without a migration path.
Maybe, if you want to learn from it. You can take pieces for your own engine, fork it or just use some of the GGlib's packages as a foundation if you feel experimental.
Don't, if you need something stable and production ready with strong documentation and community support. In that case reach for Three.js, Babylon.js or PlayCanvas.
Essentials
Essential low-level packages required by every GGlib application.
@gglib/utils- provides a basic game loop and event system@gglib/math- all the algebra@gglib/graphics- WebGPU and WebGL abstractions
Together these give you a graphics API that manages WebGPU and WebGL state, while staying low level enough to do almost anything you could do with vanilla WebGPU or WebGL.
Mid level
@gglib/game- provides an advanced game loop and input management (keyboard, mouse, gamepad)@gglib/content- provides an extensible content loading pipeline@gglib/loaders- adds content loaders for.gltf,.dds,.ktxand more
@gglib/effects- provides shaders and post-processing effects like Bloom, HDR, IBL Prefilter@gglib/model- provides a 3D model with animation support
High level
@gglib/render- provides a renderer and a simple frame graph to orchestrate scene rendering@gglib/ecs- a bare-bones Entity Component System for scene management@gglib/components- common components for the ECS