https://github.com/vscav/gl-app-template
A minimal OpenGL application template.
https://github.com/vscav/gl-app-template
cmake glew glfw glm gltf opengl
Last synced: 8 months ago
JSON representation
A minimal OpenGL application template.
- Host: GitHub
- URL: https://github.com/vscav/gl-app-template
- Owner: vscav
- License: mit
- Created: 2020-11-10T19:35:57.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2020-12-21T17:26:36.000Z (almost 5 years ago)
- Last Synced: 2025-01-04T23:18:37.357Z (9 months ago)
- Topics: cmake, glew, glfw, glm, gltf, opengl
- Language: C++
- Homepage:
- Size: 52.8 MB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# OpenGL application template
> CMake OpenGL application template using GLFW, Glew and glm.
## Table of Contents
* [Get started](#get-started)
* [Repository](#repository)
* [Linux](#linux)
* [Requirements](#requirements)
* [Usage](#usage)
* [Windows and Mac OSX](#windows-and-mac-osx)
* [CLion](#clion)
* [Visual Studio 2019](#visual-studio-2019)
* [Visual Studio Code](#visual-studio-code)
* [Features](#features)
* [Resources](#resources)## Get started
### Repository
The template uses submodules for its main libraries.
So to clone the repository, use the following command:
```
$ git clone --recursive https://github.com/vscav/GL-app-template.git
```Alternatively, if you don't used the --recursive option, you can later run:
```
$ git submodule init
$ git submodule update
```### Linux
You can build the project on linux by using command lines only. In order to do that, you will have to follow some steps.
#### Requirements
First, Update package database:
```
$ sudo apt update
```And install the updates identified previously:
```
$ sudo apt upgrade
```Then, install g++ (a C++ compiler):
```
$ sudo apt install g++
```Finally, install CMake:
```
$ sudo apt install cmake
```#### Usage
In the apllication directory, create the build folder and move into it:
```
$ mkdir build && cd build
```Build and compile the template:
```
$ cmake .. && make -j
```Run the executable by using this pattern:
```
$ ./app
```The template uses Doxygen as its main documentation generator for its engine. If you have previously installed Doxygen, run the following command:
```
$ make doc
```The documentation can be found in `build/doc/doc`. It is generated as html and LaTeX files.
### Windows and Mac OSX
#### CLion
The template can be build on Windows and Mac OSX by using CLion, a C/C++ IDE.
Open CLion and go to `File/Open`. Then, in the search window, select the template directory containing the CMake file.
CLion will detect that the opened project is a CMake project and will generate and build the files.
Then, you just need to check that the app executable is selected in the dropdown menu at the top and run it by clicking on the play button.
To generate the documentation, select the docs executable in the dropdown list and as well run it by clicking on the play button.
#### Visual Studio 2019
Coming soon.
#### Visual Studio Code
Coming soon.
## Features
Coming soon.
## Resources
- [OpenGL](https://www.khronos.org/registry/OpenGL-Refpages/gl4/) - OpenGL documentation
- [GLFW](https://www.glfw.org/documentation.html) - GLFW documentation
- [Doxygen](https://www.doxygen.nl/manual/index.html) - Doxygen documentation
- [CMake](https://cmake.org/cmake/help/v3.19/) - CMake documentation
- [CLion](https://www.jetbrains.com/fr-fr/clion/) - Download CLion IDE
- [Visual Studio 2019](https://visualstudio.microsoft.com/fr/vs/) - Download Visual Studio 2019 IDE
- [Visual Studio Code](https://code.visualstudio.com/) - Download Visual Studio Code