Commit Graph

67 Commits

Author SHA1 Message Date
Peder Bergebakken Sundt e97dfefc96 Add grain to post-shader 2019-04-01 13:09:09 +02:00
Peder Bergebakken Sundt 2857b5a31c Add chromatic abberation to post shader 2019-04-01 13:08:28 +02:00
Peder Bergebakken Sundt e7a0d74312 Add vignette to post shader 2019-04-01 13:07:39 +02:00
Peder Bergebakken Sundt c695d96158 Add depth of field to post shader 2019-04-01 13:06:56 +02:00
Peder Bergebakken Sundt 8a48b59c0b Calculate the focus factor z in the post shader 2019-04-01 13:05:12 +02:00
Peder Bergebakken Sundt f275aef0b0 Add a framebuffer which the scene is rendered to. Render this framebuffer to screen afterwards 2019-03-31 23:47:16 +02:00
Peder Bergebakken Sundt fb9ff7c829 Slightly tweak camera in scene 2019-03-31 23:41:13 +02:00
Peder Bergebakken Sundt d8c56edc93 Add glutil helper for making the post-prosessing shader mesh 2019-03-31 23:40:10 +02:00
Peder Bergebakken Sundt 5d07aba7c4 Add some time usage statistics and minor cleanup and formatting 2019-03-31 23:39:34 +02:00
Peder Bergebakken Sundt b29537273b Add backlights to car, and point components to frontlights 2019-03-29 10:41:33 +01:00
Peder Bergebakken Sundt 0f702ea259 Hide trees and grass in the path of the car 2019-03-29 10:12:31 +01:00
Peder Bergebakken Sundt 213ef68757 Prettify some of the vector math in scene.cpp 2019-03-29 10:10:56 +01:00
Peder Bergebakken Sundt 7f973533e3 Change the scene into a night scene with the car driving along the hill 2019-03-28 09:41:33 +01:00
Peder Bergebakken Sundt faa69754f8 Make the first light color affect the emissive colors, and fix bilinear filtering in PNGImage 2019-03-28 09:40:40 +01:00
Peder Bergebakken Sundt 6c7e6de5a8 fix how reflexiveness is applied to materials and scenenodes 2019-03-28 09:39:38 +01:00
Peder Bergebakken Sundt 199765e112 Add support for spot lights with a fixed direction in model space 2019-03-28 09:38:16 +01:00
Peder Bergebakken Sundt 383d5d3f62 Further separate the render logic and the scene logic
With some cleanup
2019-03-28 09:36:49 +01:00
Peder Bergebakken Sundt 74ffe23551 Add support for rim backlights 2019-03-28 09:35:22 +01:00
Peder Bergebakken Sundt 86118a34f4 Add capabilities to read values from PNGImage as if they where textures 2019-03-22 23:52:21 +01:00
Peder Bergebakken Sundt 2164551e25 Cleanup in the shaders, making them look prettier and a bit more optimized 2019-03-22 23:50:03 +01:00
Peder Bergebakken Sundt 84cbd5e5c7 Fix transparancy check for nodes
The previous method tried to read from meshes which had been freed from memory
2019-03-22 18:02:29 +01:00
Peder Bergebakken Sundt b4e66809cb Performance optimizations, caching uniforms and bound textures and avoiding uploding them if they're already set. 2019-03-22 17:07:41 +01:00
Peder Bergebakken Sundt 2cac6e1766 Remove noise from timeutils.cpp 2019-03-22 00:08:03 +01:00
Peder Bergebakken Sundt 0475f17110 Small optimization, no having to recompute a matrix for all objects 2019-03-22 00:05:50 +01:00
Peder Bergebakken Sundt a5bfa4c237 rtags json compile commands export 2019-03-22 00:05:16 +01:00
Peder Bergebakken Sundt 97adb2fd3b Add support for transparent mesh sorting 2019-03-22 00:04:50 +01:00
Peder Bergebakken Sundt 2ade6919d1 Add texture support for models 2019-03-22 00:01:14 +01:00
Peder Bergebakken Sundt 8f7f0313f5 Prettify and embetter the mouse callback in scene.cpp 2019-03-21 23:58:28 +01:00
Peder Bergebakken Sundt 8801414e34 rename gamelogic into renderlogic 2019-03-21 08:41:24 +01:00
Peder Bergebakken Sundt e0253940bd Move the scene out of gamelogic into scene.cpp 2019-03-21 01:11:59 +01:00
Peder Bergebakken Sundt d7df5e5ab1 Minor cleanups and fix spotlights 2019-03-20 00:21:51 +01:00
Peder Bergebakken Sundt 4fbf2f296c Move implementation of function from scenenode hpp file to cpp file 2019-03-19 20:25:23 +01:00
Peder Bergebakken Sundt 1d7c297257 Minor modifications to the scene 2019-03-19 20:24:59 +01:00
Peder Bergebakken Sundt da4d088d9d Add texture coordinates to spheres 2019-03-19 20:23:16 +01:00
Peder Bergebakken Sundt 5518d8e7ee Add reflection mapping 2019-03-19 20:23:16 +01:00
Peder Bergebakken Sundt 8fc773e0f8 Add material struct, making it easier to apply properties thoughout the scene 2019-03-19 20:22:58 +01:00
Peder Bergebakken Sundt 3a6181f239 Revamp color system, again. Moving color components to scene objects instead 2019-03-19 20:11:52 +01:00
Peder Bergebakken Sundt 50e3b60c28 Add model loader, modify scene to load a car 2019-03-18 11:50:25 +01:00
Peder Bergebakken Sundt 29defbaba9 Add vertex color array 2019-03-18 11:48:11 +01:00
Peder Bergebakken Sundt 86f339ef56 Fix CRLF to LF 2019-03-17 15:30:21 +01:00
Peder Bergebakken Sundt 54cd22ff57 Add changes to the scene, using the displacement map
in addition: fix the normals of the cube generator
2019-03-17 15:25:37 +01:00
Peder Bergebakken Sundt c9e4332a65 Add displacement mapping with TBN being affected 2019-03-17 15:17:44 +01:00
Peder Bergebakken Sundt 15dfce421e Fix specular light component
account for the component being negative, and fix a typo
2019-03-16 20:50:39 +01:00
Peder Bergebakken Sundt 02ab58ecc9 Add in new stuff to the scene 2019-03-16 20:14:24 +01:00
Peder Bergebakken Sundt 7135ebab6b Revamp the shader and lighting system 2019-03-16 20:12:35 +01:00
Peder Bergebakken Sundt 74d65ee092 Remove old scene 2019-03-16 20:09:17 +01:00
Peder Bergebakken Sundt 66458551c6 Add a plain to look at 2019-03-16 18:03:41 +01:00
Peder Bergebakken Sundt c699330ab5 Move hudNode out of root node, remove HUD node type, make main loop fetch window size and propagate it though update and render calls 2019-03-16 18:01:10 +01:00
Peder Bergebakken Sundt ce277dfce5 Chang the custom node shaders to be inherited by the children if left to nullptr 2019-03-16 16:48:06 +01:00
Peder Bergebakken Sundt 32ee578082 Fix insert to normals in generateSegmentedPlane using wrong end iterator 2019-03-16 16:35:13 +01:00