Commit Graph

49 Commits

Author SHA1 Message Date
Vincent Lejeune
fd2da4085b Rename some shader to improve their meaning 2014-12-05 00:20:16 +01:00
Vincent Lejeune
f3a637fb99 Fix sun area light 2014-11-21 02:44:27 +01:00
Vincent Lejeune
4a8afd2d40 Implement sun as an disk area light.
Solid angle is defaulted to sun's one.
2014-11-21 01:54:30 +01:00
Vincent Lejeune
c594295288 Tweak shadow blur 2014-11-18 03:44:45 +01:00
Vincent Lejeune
c2859d24ce Improved shadow stability 2014-11-15 21:27:15 +01:00
Vincent Lejeune
92ecd01e61 Make cascade split modifiable 2014-11-04 20:53:32 +01:00
Vincent Lejeune
ddecd23472 Tweak values 2014-11-02 19:07:02 +01:00
Vincent Lejeune
ebe11370a2 Reenable bluring 2014-11-02 16:30:44 +01:00
Vincent Lejeune
c5186e3ab3 Use depth in exp space 2014-11-02 16:26:46 +01:00
Vincent Lejeune
b975b63eea Use proper depth linear value 2014-11-02 16:00:41 +01:00
Vincent Lejeune
9113aa7a39 Implement Exponential Shadow map 2014-11-02 02:36:10 +01:00
Vincent Lejeune
6aed902ae0 Store depth in color buffer instead of depth
This allows for instance to blur it using already existing shaders
2014-11-01 22:38:38 +01:00
Vincent Lejeune
ee687440c7 Increase shadow filtering 2014-10-29 18:57:39 +01:00
Vincent Lejeune
58c094917e Use an header included in every shaders. 2014-08-02 00:50:56 +02:00
hiker
f1c8fcc6d4 Fix 1366. 2014-06-15 22:14:50 +10:00
vlj
55ddffaf54 Another round of big triangle port. 2014-06-03 20:28:42 +02:00
vlj
5e62347d11 Fix attempt for #1308 2014-05-03 17:36:27 +02:00
vlj
2a1623d8ca Use a more efficient screen to view conversion
Also use the opportunity to use UBO where possible.
2014-05-02 18:11:34 +02:00
Vincent Lejeune
84ddd7119e Use glPolygonOffset to remove shadow acne
It's a 2002 trick from M. Kilgard
2014-04-24 21:02:24 +02:00
vlj
85e720a58f Shadow: tweak bias to remove acnee 2014-04-24 18:33:05 +02:00
Vincent Lejeune
d4718df127 Revert "Use some realist order of magnitude of light"
This reverts commit 2aa6676050.
2014-04-22 00:44:08 +02:00
vlj
2aa6676050 Use some realist order of magnitude of light 2014-04-21 19:40:10 +02:00
vlj
e8b36f2490 Fix for shadow acne in chocolate. 2014-04-20 02:20:09 +02:00
vlj
87248b46f3 Tweak shadows CSM split. 2014-04-20 02:01:29 +02:00
vlj
1291d0cc93 Increase shadow fidelity. 2014-04-20 00:21:30 +02:00
vlj
a457b9f423 Shadows: Clean shaders. 2014-04-20 00:04:49 +02:00
vlj
e00ce85d7c Support FresnelSchlick factor. 2014-04-07 21:35:10 +02:00
vlj
79c6424703 Use specularmap as glossiness map. 2014-04-07 21:35:09 +02:00
vlj
cafc07680a Use Blinn Phong model. 2014-04-07 21:35:09 +02:00
Vincent Lejeune
29749d5dbd Merge commit 'f3e2da881a4d394c4ca902548e788f5b4c0bdd81'
* commit 'f3e2da881a4d394c4ca902548e788f5b4c0bdd81':
  Do not build shadow shader without gs support.
  Add a function to query supported glsl ver
  Some drivers dont support const array
2014-03-22 18:54:51 +01:00
Vincent Lejeune
aa39246404 Some drivers dont support const array 2014-03-22 18:36:19 +01:00
Vincent Lejeune
01b88fde9d Factorize DecodeNormal from misc shaders. 2014-03-21 18:17:21 +01:00
Vincent Lejeune
af862cb6c5 #version autoadded to shaders and turn some v120 2014-02-28 17:29:05 +01:00
samuncle
073a049389 Correction of a syntax error 2014-02-17 22:36:00 +01:00
Vincent Lejeune
d5d57bbae0 Shadows: Softer edge and smoother cascade transitions 2014-02-15 20:45:47 +01:00
Vincent Lejeune
0243546e4d Use an openGL 3.3 compatibility context when available. 2014-02-12 22:16:10 +01:00
Vincent Lejeune
70f89a8bce Shadow: Use 4 cascades.
Now that we use GS and textures array it's easier to add a cascade.
4 is still not optimal but I'd like to avoid cascade count inflation as
much as possible ; 4 x 1024x1024 has the bandwidth requirement of the
single 2048x2048 shadowmaps we previously had.
2014-02-11 21:49:46 +01:00
Vincent Lejeune
934d1f10b8 Shadow: Use Geometry Shader for better perfs.
The 3 cascades are now rendered in a single pass, using 2D array texture and
a GS to do the dispatch ("layered rendering").
It's possible to use instancing instead but it requires the AMD_vertex_shader_layer
extension which is oddly part of opengl 4.2.
2014-02-11 21:07:44 +01:00
Vincent Lejeune
c8844486fa Shadow: Tweak bias 2014-02-10 15:58:09 +01:00
Vincent Lejeune
515bcbc750 Shadow: very crude csm support 2014-02-10 15:42:17 +01:00
Vincent Lejeune
19d490a26d Lights: Remove unused export value. 2014-02-09 21:18:15 +01:00
Vincent Lejeune
5d5ac34648 Shadow: soften edge a little 2014-02-09 20:03:54 +01:00
Vincent Lejeune
63db565fd7 Shadow: Better bias. 2014-02-09 19:42:22 +01:00
Vincent Lejeune
f0ef8e9913 Shadow: reenable shadows
It's just plain basic shadowmaps, a lot of tweak is still necessary but
it gives a way to see how light values are affected in some places.
(cave in chocolate for instance)
2014-02-09 19:20:55 +01:00
Vincent Lejeune
859be83074 Explicitly define fragment exported values. 2014-01-19 19:31:00 +01:00
Vincent Lejeune
fb6649eaad texture2D is deprecated, use texture instead 2014-01-19 18:53:35 +01:00
vincentlj
fa068d7810 OGL32CTX: Ask #version 130 for all our shaders
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@14919 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2014-01-05 00:08:00 +00:00
samuncle
063ea38cc6 A new bias (it works better with harvest
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@14594 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-12-01 17:47:30 +00:00
auria
5899a26aad Merge cand's graphical improvements branch!! There are many known issues folks, so don't cry victory just now, this is just the beginning. Especially, shadows do not work correctly at this time
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@14590 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-11-30 21:33:06 +00:00