OpenGL Starting Place, A Template to get started making
opengl projects and assignments, Mostly using
c code in
cpp files
freeglut | glfw |
---|---|
![]() |
![]() |
There is a discussions available for this repo at https://github.com/tztz8/OpenGL-Starting-Place/discussions
When cloning this repo remember use
--recursive
flag (Visual Studio git clone does it by default)
If altered cloned use
git submodule update --init --recursive
I Used EWU Windows computers and My Manjaro
Linux Computer and a
VMware
Windows for testing.
Note the systems have FreeGLUT, GLM, GLEW and, often have DevIL installed
On EWU Windows computers uses Visual Studio 2019
I do add GLSL language integration extension when I use school computer
On My Manjaro Linux computer I use CLion
I do have GLSL Support plugin, but the plugin does crash often but still works
On VMware Windows computers I use Visual Studio 2019
I do have GLSL language integration extension
also in basicFreeGLUT main.cpp
The start of the program and most of the code will be done here.
Has methods to set up cube and draw cube
Vertex Shader (shader.vert)
also in basicFreeGLUT shader.vert
Vertex shader (using GLSL Support Plugin on CLion and GLSL language integration extension on Visual Studio)
Called for each vertex
Fragment Shader (shader.frag)
also in basicFreeGLUT shader.frag
Fragment shader (using GLSL Support Plugin on CLion and GLSL language integration extension on Visual Studio)
Called for each pixel
Main Cmake file CMakeLists.txt
Set up the project, get libraries ready and finally call each excitable CMake File
basicGLFW CMakeLists.txt
Set up the excitable and link it to the libraries.
basicFreeGLUT CMakeLists.txt
Set up the excitable and link it to the libraries.
To use Nvidia GPU insed of integrated GPU on Linux add
__NV_PRIME_RENDER_OFFLOAD=1;
__GLX_VENDOR_LIBRARY_NAME=nvidia;
To environment variables
![]() OpenGL/GLSL |
GLFW | freeGLUT | ![]() cmake |
---|---|---|---|
OpenGL (unofficial) | GLFW | freeGLUT | cmake |
OpenGL (4.5 Reference Pages) | GLUT | ||
OpenGL (opengl45-quick-reference-card)(Not quick) |
Cube | CMake | nvidia | linux | windows | jetbrains | visual-studio | c-programming | cpp | vmware player |
---|---|---|---|---|---|---|---|---|---|
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |