Skip to content

Starter code for OpenGL C++ projects using modern CMake.

License

Notifications You must be signed in to change notification settings

mfl28/opengl-cpp-starter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenGL Cpp Starter

Build Status CMake Version GitHub

OS Build Status
Linux Build Status
MacOS Build Status
Windows Build Status

This repo provides easy to use starter code for OpenGL C++ projects using modern CMake. The included CMake scripts automatically fetch and link glfw, glad, glm and stb_image. Optionally, you can also fetch and link assimp (see Generating build system). The sample OpenGL code is based on learnopengl.com and currently just opens a blank window.

Getting started

Requirements

  • CMake (minimum version 3.18.0)

Clone

git clone https://github.com/mfl28/opengl-cpp-starter.git
cd opengl-cpp-starter

Generate build system

# Useful options:
# -D USE_ASSIMP=(YES|NO) (fetch and link assimp library, default: NO)
cmake -B build

Build

# Useful options:
# --parallel <max-processor-number> (build in parallel)
cmake --build build

Run

Linux / MacOS

cd build
./starter

Windows

# When using Visual Studio as generator:
cd build\(Debug|Release)
.\starter

License

This repository is licensed under MIT, see LICENSE.

About

Starter code for OpenGL C++ projects using modern CMake.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published