Phong bunny and friends

This demo was created specifically to show how you can make a scene with different models (a bunny and Teddy) and different shaders. The big deal with this is really to make a shader active before trying to affect it, a simple thing which is very easy to do wrong.


This includes a C++ version, just adding operator overloading. Updated 2017.

New version 2021: Extending this as a C++ demo: This version demonstrates how to package models with other data (very little since this is a demo, not a general template) with structs, both C-style and C++-style (complete with an example of inheritance). Tested on Mac and Linux. Both give some warnings, but different ones, and both work.

Both versions updated 2022.


This page is maintained by Ingemar Ragnemalm.