OpenGL-Grid is a repository that aims to act as a beginners guide to creating a grid in OpenGL using shaders.
There will be a complete explanation for each part of the code and I will try to make it as easy as possible to follow along.
On linux simply use your package manager of choice and install the libraries:
sudo apt install glfw3 glm
On windows I highly recommend using the Vcpkg to easily install
the dependencies:
vcpkg install glfw3 glm
and use their toolchain to easily configure cmake:
cmake . -DCMAKE_TOOLCHAIN_FILE=D:\src\vcpkg\scripts\buildsystems\vcpkg.cmake
You can read more here.
- Clone this repository:
git clone https://github.com/ceranco/OpenGL-Grid.git
cd OpenGL-Grid
- Generate project using CMake:
cmake .
- Build using your build system.
This section will try to explain with relative simplicity how the program works.
Basic knowledge of OpenGL such as what are VAOs, VBOs and Shaders is expected.
If you don't possess this knowledge, I recommend the excellent tutorial over at learnopengl.