Your first triangle¶
In this tutorial, you write an application that draws a single, colored triangle. It is the "hello world" of graphics programming and introduces the most important concepts of LiteFX along the way:
- The application: create an application with a window and run it with the available backends.
- The device: start a backend, create a graphics device and implement the application loop.
- Render pass and frame buffers: describe where the triangle is drawn.
- Shaders: write the shaders that run on the GPU and compile them as part of your build.
- The render pipeline: describe how the triangle is drawn.
- Drawing: upload the triangle to the GPU and draw it every frame.
The application supports both backends, Vulkan and DirectX 12, from the same code.
Before you start
Set up a project as described in the project setup guide. The tutorial writes the two source
files of that project, main.h and main.cpp.