Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Erwin <significant.bit@gmail.com>2016-08-16 21:58:53 +0300
committerMike Erwin <significant.bit@gmail.com>2016-08-16 21:58:53 +0300
commitb8f27b25145b23ebaa402aa6873ebfcbadc3491f (patch)
tree6d73177e77c0c5165552937d32d37eaa35e92b02 /source/blender/gpu/shaders/gpu_shader_uniform_color_frag.glsl
parent8619e091072c57a2b1c4d471c3c7823063a2d848 (diff)
OpenGL: shaders for simple 3D drawing
These are intended for very simple drawing. No lighting etc. Shares some fragment code with the 2D shaders. Similar to their 2D counterparts, but are not combined because of future plans for separate 2D & 3D matrix stacks.
Diffstat (limited to 'source/blender/gpu/shaders/gpu_shader_uniform_color_frag.glsl')
-rw-r--r--source/blender/gpu/shaders/gpu_shader_uniform_color_frag.glsl13
1 files changed, 13 insertions, 0 deletions
diff --git a/source/blender/gpu/shaders/gpu_shader_uniform_color_frag.glsl b/source/blender/gpu/shaders/gpu_shader_uniform_color_frag.glsl
new file mode 100644
index 00000000000..af200bf8661
--- /dev/null
+++ b/source/blender/gpu/shaders/gpu_shader_uniform_color_frag.glsl
@@ -0,0 +1,13 @@
+
+uniform vec4 color;
+
+#if __VERSION__ == 120
+ #define fragColor gl_FragColor
+#else
+ out vec4 fragColor;
+#endif
+
+void main()
+{
+ fragColor = color;
+}