C++ multimedia and game-development library. Windowing, 2D rendering, and input via a pluggable backend system — no SDL or other intermediary.
Current: Linux · Wayland · OpenGL/EGL
Planned: Windows, X11, Vulkan
# Debian/Ubuntu — Wayland + OpenGL backend
sudo apt install libwayland-dev libdecor-0-dev wayland-protocols \
libgl-dev libegl-dev libepoxy-devmake # builds libtela.a
make examples # builds libtela.a + examplesCMake directly:
cmake -S . -B build -DBUILD_EXAMPLES=ON
cmake --build build --parallelBackend/renderer selection:
| CMake option | Values | Default |
|---|---|---|
PROJECT_PLATFORM |
linux |
linux |
PROJECT_BACKEND |
wayland |
wayland |
PROJECT_RENDERER |
opengl |
opengl |
#include <tela/app.hpp>
#include <tela/input.hpp>
class MyScene : public tela::Scene {
public:
MyScene() { add_child(player_); }
private:
Player player_;
};
int main() {
tela::App app({ .width = 800, .height = 600, .title = "My Game" });
app.run<MyScene>();
}| Type | Purpose |
|---|---|
Node |
Base; override process(float) and draw(Renderer&) |
Scene |
Root of the tree; owned by App |
Timer |
Fires a callback after a duration; start() / stop() |
Node2D |
Positioned node with set_position() / size() / set_rotation() |
Sprite2D |
Renders a texture; constructed from a ResourcePath or a Texture2D |
Assets resolve via tela::Resources::path("assets/foo.png") relative to the binary.
Input goes through the static tela::Input API; see examples/input.
make examplessprite2d and input under examples/, built to build/examples/<name>/<name>.