This is an Computer graphic class project using glad, glfw, glm
Demo https://www.youtube.com/watch?v=ZYtrCOHmLak&feature=youtu.be
Make sure your have configured glad and glfw to run these code.
Features:
- Import model from files
- Translation, rotation with model
- Control the camera position
- Add spotlights, direction lights and point lights
- Increase or decrease the number of point lights
- Dynamic point lights (point light position can move around)
- Add different material to the model
To import a model into this application is very easy. Users just need to drag a file to this window and a model will be displayed in this window.
• N – Enable transformation shader (press again will disable and set the location of model to default) • Press 1,2,3 to Rotate • Press 4,5,6,7 – to translation
To control the camera, need to enable material shader first, because the code of control camera is in material shader, press Z to enable material shade.
- W – move forward
- S – move backward
- A – move left
- D – move right
- E – move down
- T – move up
- Mouse input
- Z - add material and one light
- M - Bronze material
- P - White plastic material
- C - Ruby Material
- O - Dynamic Material