- Makefile - makefile for easy compilation
- apple.obj - apple model
- apple.png - apple texture
- cylinder.obj - snake body fragment model
- floor.h - floor vertices, normals and texture coordinates
- head.png - snake head texture
- inverted_fs.glsl - fragment shader implementing Lambertian shading with inverted texture coordinates
- inverted_vs.glsl - vertex shader implementing Lambertian shading with inverted texture coordinates
- libs.cpp, libs.h - definitions for all classes and libraries used in project
- lodepng.cpp, lodepng.h - library for loading images into GPU
- main_file - compiled binary file of the source code (under Linux)
- main_file.cpp - main application source code
- objloader.cpp, objloader.h - library for converting OBJ files into OpenGL format
- phong_fs.glsl - fragment shader implementing Phong shading
- phong_vs.glsl - vertex shader implementing Phong shading
- shderprogram.cpp, shaderprogram.h - shader program definition
- snake.png - snake skin texture
- snake_head.obj - snake's head model (currently unused due to absence of normals)
- standard_fs.glsl - fragment shader implementing Lambertian shading
- standard_vs.glsl - vertex shader implementing Lambertian shading
- steel.png - steel texture for borders
- wood.png - floor texture
- Using Makefile:
$ make
$ ./main_file
- Manually:
$ g++ *.cpp *.h -lGL -lglfw -lGLEW -I .
$ ./a.out
- Without compilation (works only on Linux):
$ ./main_file
If you want to contribute to this repository, fork it and adapt it to your needs. This repository is mainly for educational purposes so it probably won't be updated. But if you see some glazing error in the code, feel free to submit pull request and it will be merged (if it will be logical). Don't expect Issue tickets to be solved though.
- PUT IiT sources - Witold Andrzejewski, PhD. - for Shader Program
- LodePNG - for loading texture images to GPU
- Suraj Sharma - for OBJ loader
- OpenGL Tutorials - for OpenGL basics
- 3dfood - for apple model
- nudelkopf - for snake body model
- glm - for simplifying model calculations
- wallpaperflare - for snake head texture
- wallpaper-house - for snake skin texture