An open API service indexing awesome lists of open source software.

https://github.com/ivan-hart/opengl-template

This project is intended as a template for personal use
https://github.com/ivan-hart/opengl-template

3d c cmake cpp graphics graphics-programming opengl

Last synced: 2 months ago
JSON representation

This project is intended as a template for personal use

Awesome Lists containing this project

README

          

# A Simple Cube With Lighting Intended as a Template

![Example image of the template code](https://github.com/ivan-hart/opengl-template/blob/master/repo_image.png)

### Dependencies
> [SDL2](https://github.com/libsdl-org/SDL)

> [GLM](https://github.com/g-truc/glm)

> [GLAD (Included)](https://github.com/Dav1dde/glad)

> [Cmake (Makefile Generator)](https://cmake.org/)

> [GNU Make](https://www.gnu.org/software/make/)

### To Run
> $ md build && cd build

> $ cmake ..

> $ make

> $ ./opengl-template

### Camera Controls
> W to raise the Y position of the camera

> S to lower the Y position of the camera

> A to rotate the camera to the left

> D to rotate the camera to the right

### Cube Controls
> Up Arrow to rotate the X rotation of the cube up

> Down Arrow to rotate the X rotation of the cube down

> Left Arrow to rotate the cube to the left

> Right Arrow to rotate the cube to the right