Apple Mac Project

Intel Mac Project

Learn OpenGL web site

In the next few lectures I am going to be showing examples from the Learn OpenGL web site. This web site hosts a large set of tutorials and provides example code for a wide range of OpenGL examples.

Follow the appropriate instructions below to get set up with the example code for today's example.

Windows instructions

You will want to start by downloading the code examples from the web site.

Start by clicking this link to go to the Learn OpenGL github page. Click the green Code button and select the option to download the zip archive with the complete example code. Expand the archive.

Next, start up Visual Studio and select the option "Open local folder" in the start up screen. Open the folder with the example code. The build system used to build the examples is CMake: Visual Studio will automatically sense that this is a CMake project, and will automatically run a process to set up the project for Visual Studio. Once this process completes, go to the Solution Explorer and click the Solution View button just to the right of the home button to switch a folder view.

Click on CMake Targets View and press enter to see a list of all of the subprojects in the folder. Today we are going to be working with the 3.model_loading subproject. To compile and run the project, right-click on it and select the Debug command.

Mac instructions

The example code provided by the web site is not well suited for use on modern Mac computers. To compensate for this I have constructed XCode projects containing example code for the project we are going to be working with today. Click the appropriate button at the top of these notes to download the version of the XCode project that is appropriate for your Mac.

Before you try compiling and running the project, you will need to install a couple of libraries on your Mac. Open a terminal window and run the command

brew install assimp freetype

The model loading example

The example we are going to cover today is the Learn OpenGL model loading example. Click the link to go to the notes on the Learn OpenGL web site that cover the use of the Assimp library, the Mesh class, and the Model class.