Open-source project
gongminmin/KlayGE avatar
gongminmin/KlayGE

KlayGE: a cross platform C++ engine built as a plugin collection

KlayGE is a cross-platform open source game engine with plugin-based architecture.

2,176 stars354 forksC++GPL-2.0

At a glance

What is it?
KlayGE is a GPL 2.0 game engine that has been developed since 2003 around a plugin architecture, with a Python driven build system and separate graphics backends for Direct3D, OpenGL and Vulkan.
Who is it for?
KlayGE is a good fit if you specifically want a modern C++ engine with a plugin per subsystem, a source tree you can read, and a licence that lets you ship a game as long as that game is GPL. It is a poor fit if you need something with a maintained release cadence, because the most recent tagged release is v4.17 from 2020-07-01 while the default branch is `develop` and the last push was on 2026-07-17, which means you are building from an untagged tip.
Can I use it commercially?
Yes, with conditions. GPL-2.0 is a copyleft licence: if you distribute software that includes it, you must release that software's source code under the same licence. Running it internally without distributing it does not trigger that obligation.
Is it still maintained?
Yes. The repository last received commits 97 days ago.
What is it written in?
Mainly C++, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on October 22, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • gongminmin/KlayGE2,176 ★ · +1
Star history
Repository2026-10-072026-10-22
gongminmin/KlayGE2.2k2.2k

1 Stars in the last 15 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

Getting the source tree to build, which is a Python script not a make target

The README's getting started section is three sentences and one prerequisite list. Before compiling KlayGE you need Python 3.6 or newer and CMake 3.16 or newer installed. Then you run `Build.py` to build the whole code base, with details on the Installation page of the wiki at klayge.org.

That build entry point is unusual enough to be worth examining. A CMake project would normally have you configure and build directly, and KlayGE does have a `CMakeLists.txt` at the root. But the project also ships `CfgBuildDefault.py`, `DeployKlayGE.py` and `Package.py`, which tells you the Python layer is doing configuration, deployment and packaging around CMake rather than existing only as a convenience wrapper. There is a `Build/` directory too, so generated output has a known home.

Continuous integration runs on Azure Pipelines, named in the tree as `azure-pipelines.yml`, and the README badge points at a Visual Studio hosted build with `branchName=develop`. That branch name is the first hint about how this project is developed, and the tree's default branch agrees: `develop` is what GitHub serves by default here, not `master`.

What you do not get from the README is a package manager path. There is no Homebrew formula, no Chocolatey entry and no SDK download mentioned. The engine is built from source, which is normal for a project with a C++ core and third party libraries, but it does mean the first build is a real build rather than an install.

Develop platforms and run platforms are listed separately, and the difference matters

The Platforms section of the README makes a distinction many engines blur. KlayGE can be developed on Windows desktop, macOS and Linux, described as with no limitation. It can be deployed and run on Windows desktop, Windows store, Android, Linux, macOS and iOS.

Then the caveat: some of them do not support all plugins, with a pointer to the Platforms page on the wiki. That single sentence is the most practically important line in the README for anyone porting a title. The engine's architecture is plugin based, which is what makes the wide platform list possible, and it is also what means feature availability varies per platform. A plugin for a rendering backend that does not exist on a target is a gap you discover at integration time rather than at install time.

The repository topics name the rendering backends and audio stack directly: d3d11, d3d12, opengl, opengles, openal, plus graphics, engine, engine3d, cross-platform and python. The presence of Python as a topic is not about scripting the game, it reflects the build system.

The tree supports the plugin picture. `KlayGE/` is the engine itself, `KFL/` is a separate library underneath it, `DXBC2GLSL/` suggests a shader bytecode conversion tool, `glloader/` is an OpenGL loader, `kfont/` is font handling, and `Externals/` is where third party code lives. Those names describe an engine that keeps each subsystem in its own module rather than one large shared library.

What the 4.15 to 4.17 releases reveal about the engineering direction

The three most recent releases are v4.15 from 2019-07-01, v4.16 from 2019-12-31 and v4.17 from 2020-07-01. Read as a sequence, they describe an engine modernising its rendering stack and its build system at the same time.

v4.15 is the architecture change. It switched to a complete entity-component-system architecture, separated shader stage objects, made shader compiling multi-threaded to improve load performance, integrated a depth of field effect into the deferred rendering framework, improved the PBR material system, added a predefined cbuffer to reduce rendering overhead, and improved high-DPI handling. On the engineering side it consolidated everything into one unified CMake project for build speed, brought more third party libraries under git management, enabled Ninja, and re-enforced the coding standard with clang-format.

v4.16 moved the rendering frontier: rendering to multiple viewports in one pass, described as a step for efficient high-quality VR and AR rendering, struct support in fxml for building more complicated effects, motion blur and occlusion map support in the deferred framework, a new skin rendering algorithm with a stated performance five times the original, and a memory allocator that raised D3D12 plugin performance by five percent. It also replaced WRL with cppwinrt and added a `com_ptr` to reduce binary sizes.

v4.17 is smaller and more about the toolchain: a new XInput plugin, GPU generated mipmaps in real time, skinned mesh export from a scene, and a ten percent speedup on the D3D12 plugin from replacing `shared_ptr` with `unique_ptr` where possible plus adding final and noexcept markers. On the build side, all third party libraries can be synced from their original git repositories and patched before building, a C++20 format library was introduced, clangcl became a supported compiler, Boost usage was reduced, and patches were pushed upstream to the libraries' own repositories.

That last pattern is the interesting one. Reducing Boost and pushing patches upstream are the moves of a project trying to lower its own maintenance burden, and they explain the `Externals/` directory and the `LICENSE-External.md` file.

Six years of commits after the last tag

Here is the fact that should shape your expectations. The README badge advertises the latest release as v4.17.0, and the releases page ends at v4.17 from 2020-07-01. The last push to the repository was on 2026-07-17.

So the default branch is receiving commits while no release has been cut since 2020. The v4.17 release notes mention a new `gopy version`-style discipline of engineering work, with dependency syncing and upstream patches, and the snapshot builds used by other projects would be an obvious answer, but the README does not describe a snapshot distribution for KlayGE the way some other engines do. What it does describe is a build from source on `develop`.

This is not a criticism so much as a planning input. If you adopt KlayGE you are adopting a development tip, and the wiki Installation page rather than a binary is the path. You should expect to resolve build issues against third party libraries yourself, since those libraries move underneath a six year old tag.

The project's own framing of why it keeps going is worth noting because it explains the direction. The README says KlayGE has been started since 2003 and states the explicit goal as arming your engine with current technology, providing a framework to make game development, testing and porting as simple as possible. Long-lived engines in that position tend to spend their effort on the toolchain and on removing work from the next person rather than on shipping features for a release.

The commit record supports that reading. The `develop` branch has the Visual Studio CI badge in the README and the wiki has a documented Workflow of Contributing Code that the README asks you to check before submitting a patch, so the project does have a process for outside contributions rather than only for its author.

GPL 2.0 is the licence that decides whether you can ship a game with it

The License section of the README is unusually explicit, and it is worth reading literally. KlayGE's default licence is the GNU General Public License 2.0. In the README's own phrasing, anyone can use it and access its source code, as long as the project which uses KlayGE must be released under GPL 2.0.

That is a copyleft obligation on your game, and it is the reason to read this section before anything else. If you are building a commercial title and cannot release it under GPL 2.0, KlayGE is not a candidate regardless of how good the renderer is. If you are building something internal, or a game you intend to open source, the obligation is the price of admission and applies to the whole project.

Third party code is handled separately and correctly. The README states that KlayGE depends on several external libraries distributed under their own terms, pointing at `LICENSE-External.md` for the list. That is the file to check when your compliance question is about a specific dependency rather than the engine itself, because the engine's GPL 2.0 does not by itself determine what you owe for the third party code compiled into your binary.

The `LICENSE` file at the repository root is the GPL text itself, and the presence of both it and `LICENSE-External.md` is a reasonable sign that the separation is maintained rather than aspirational.

Editorial conclusion

KlayGE is a good fit if you specifically want a modern C++ engine with a plugin per subsystem, a source tree you can read, and a licence that lets you ship a game as long as that game is GPL. It is a poor fit if you need something with a maintained release cadence, because the most recent tagged release is v4.17 from 2020-07-01 while the default branch is `develop` and the last push was on 2026-07-17, which means you are building from an untagged tip. The honest summary is that this is an active but unreleased development line. If you take it on, install Python 3.6 or newer and CMake 3.16 or newer first, run Build.py rather than invoking CMake by hand, and read the platform matrix on the wiki before assuming a plugin such as D3D12 or OpenGL ES exists on your target, because the README states plainly that not every runtime platform supports every plugin.

Frequently asked questions

What is KlayGE and what is it used for?

KlayGE is a cross-platform open source game engine written in C++ with a plugin-based architecture, started in 2003. The README says its goal is to provide a framework that makes game development, testing and porting as simple as possible, across Windows, macOS, Linux, Android and iOS.

How do I build KlayGE from source?

The README says to install Python 3.6 or newer and CMake 3.16 or newer first, then run Build.py to build the whole code base. Further detail is on the Installation page of the wiki at klayge.org, and continuous integration runs on Azure Pipelines against the develop branch.

Can I use KlayGE in a commercial game?

Not unless the game itself is released under GPL 2.0. The README states that anyone can use it and access its source code as long as the project which uses KlayGE must be released under GPL 2.0. Third party libraries are distributed under their own terms, listed in LICENSE-External.md.

What is the latest version of KlayGE?

The most recent tagged release is v4.17, published on 2020-07-01, and the README badge advertises v4.17.0 as the latest release. The default branch is develop rather than master, and the last push to the repository was on 2026-07-17, so a source build follows an untagged tip.

Official sources

  1. gongminmin/KlayGE on GitHub
  2. License: GPL-2.0
  3. Project website
  4. README
  5. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/gongminmin-klayge.svg)](https://hysenlabs.com/projects/gongminmin-klayge)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/gongminmin-klayge.svg)](https://hysenlabs.com/projects/gongminmin-klayge)

Was this useful?