This file outlines the steps necessary for the creation of this project repository.
- Create an empty repository on GitHub
- Create an empty C++ project with Visual Studio
- Ensure that "place solution and project in the same directory" is checked
- Configure local Git repository within project directory
git init - Link local repository to remote GitHub repository
git remote add origin <GitHub repo URL> git remote -v - Create four directories named
/src,/include,/lib, and/dll/srcwill contain source code files for the project/includewill contain header files and header-only libraries/libwill contain library files and implementation files/dllwill contain dynamic-link library files
- Configure propject properties in Visual Studio
- Output files
Project > Properties > Configuration Properties > GeneralOutput Directory: $(SolutionDir)bin\$(Platform)\$(Configuration)\ Intermediate Directory: $(SolutionDir)bin\intermediates\$(Platform)\$(Configuration)\ - Locate include files
Project > Properties > Configuration Properties > C/C++ > GeneralAdditional Include Directories: $(SolutionDir)include\ - Locate library files
Project > Properties > Configuration Properties > Linker > GeneralAdditional Library Directories: $(SolutionDir)lib\ - Locate dynamic-link library files
Project > Properties > Configuration Properties > DebuggingEnvironment: PATH=$(SolutionDir)dll\ - Specify dependencies
Project > Properties > Configuration Properties > Linker > InputAdditional Dependencies: $(CoreLibraryDependencies);%(AdditionalDependencies)
- Output files
- Create basic project configuration files
- README.md
- .gitignore
# output binaries bin/ # Visual Studio .vs/ *.sln *.vcxproj* # other files as necessary ...
- Create a simple "Hello, world!" program to ensure project is properly configured
- Download and decompress the latest version of GLFW from https://www.glfw.org/
- This project uses the 64-bit Window binaries
- In the downloaded folder:
- Find the
/includedirectory and copy the/GLFWfolder to the project's/includedirectory - Find
glfw3.libfor the desired Visual Studio version and add it to/lib
- Find the
- Download GLAD from the generator at https://glad.dav1d.de/
- Set the language to
C/C++ - Set the speficication to
OpenGL - Set the profile to
Core - Set the version to 3.3 for GL under the API section
- Ensure "generate a loader" is selected
- Click generate
- Download and decompress the zip file containing two include directories,
/gladand/KHR, as well as a source file,glad.c
- Set the language to
- Add
/gladand/KHRto/include - Add
glad.cto/lib
- Add
glfw3.libandopengl32.libto linker dependencies
Project > Properties > Configuration Properties > Linker > InputAdditional Dependencies: glfw3.lib;opengl32.lib;$(CoreLibraryDependencies);%(AdditionalDependencies) - Create an OpenGL program that renders a window to ensure OpenGL is working
- Download GLM from https://glm.g-truc.net/
- Add the root directory,
/glm, to/include
- Download
stb_image.hfrom https://github.com/nothings/stb/blob/master/stb_image.h - Add
stb_image.hto/include