Changeset 60578ce in opengl-game for vulkan-game.hpp
- Timestamp:
- Dec 18, 2019, 2:48:28 AM (5 years ago)
- Branches:
- feature/imgui-sdl, master, points-test
- Children:
- a79be34
- Parents:
- 7c929fc
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
vulkan-game.hpp
r7c929fc r60578ce 1 1 #ifndef _VULKAN_GAME_H 2 2 #define _VULKAN_GAME_H 3 4 #define GLM_FORCE_RADIANS 5 #define GLM_FORCE_DEPTH_ZERO_TO_ONE // Since, in Vulkan, the depth range is 0 to 1 instead of -1 to 1 6 #define GLM_FORCE_LEFT_HANDED 3 7 4 8 #include <glm/glm.hpp> … … 57 61 const float NEAR_CLIP = 0.1f; 58 62 const float FAR_CLIP = 100.0f; 59 const float FOV_ANGLE = 67.0f; 63 const float FOV_ANGLE = 67.0f; // means the camera lens goes from -33 deg to 33 def 60 64 61 65 vec3 cam_pos; … … 203 207 vec3 p3 = vertices[i+2].pos; 204 208 205 vec3 normal = normalize(cross(p2 - p1, p3 - p1));206 //normal.z = -normal.z;209 // flip the y axis so that +y points up 210 vec3 normal = -normalize(cross(p2 - p1, p3 - p1)); 207 211 208 212 // Add the same normal for all 3 vertices
Note:
See TracChangeset
for help on using the changeset viewer.