projects
/
zefram
/
minetest
/
minetest_engine.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
68e3622
)
Tweak shader randomly a bit
author
Perttu Ahola
<celeron55@gmail.com>
Sun, 2 Dec 2012 21:08:46 +0000
(23:08 +0200)
committer
Perttu Ahola
<celeron55@gmail.com>
Sun, 2 Dec 2012 21:47:53 +0000
(23:47 +0200)
client/shaders/test_shader_1/opengl_vertex.glsl
patch
|
blob
|
history
diff --git
a/client/shaders/test_shader_1/opengl_vertex.glsl
b/client/shaders/test_shader_1/opengl_vertex.glsl
index e24f58c099b254098aa80e25e1510bbdd7203783..3cf1f122b3de9e0a9e30536b2825922a51a9b47b 100644
(file)
--- a/
client/shaders/test_shader_1/opengl_vertex.glsl
+++ b/
client/shaders/test_shader_1/opengl_vertex.glsl
@@
-43,8
+43,12
@@
void main(void)
color.g = rg;
\r
color.b = b;
\r
\r
+ // Make sides and bottom darker than the top
\r
+ color = color * color; // SRGB -> Linear
\r
if(gl_Normal.y <= 0.5)
\r
- color *= 0.7;
\r
+ color *= 0.6;
\r
+ //color *= 0.7;
\r
+ color = sqrt(color); // Linear -> SRGB
\r
\r
color.a = gl_Color.a;
\r
\r