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:
Diffstat (limited to 'source/blender/gpu/shaders/gpu_shader_fire_frag.glsl')
-rw-r--r--source/blender/gpu/shaders/gpu_shader_fire_frag.glsl12
1 files changed, 10 insertions, 2 deletions
diff --git a/source/blender/gpu/shaders/gpu_shader_fire_frag.glsl b/source/blender/gpu/shaders/gpu_shader_fire_frag.glsl
index 3819203bcd9..45f86e036a1 100644
--- a/source/blender/gpu/shaders/gpu_shader_fire_frag.glsl
+++ b/source/blender/gpu/shaders/gpu_shader_fire_frag.glsl
@@ -1,5 +1,13 @@
-varying vec3 coords;
+#if __VERSION__ == 120
+ varying vec3 coords;
+ #define fragColor gl_FragColor
+#else
+ in vec3 coords;
+ out vec4 fragColor;
+ #define texture1D texture
+ #define texture3D texture
+#endif
uniform sampler3D flame_texture;
uniform sampler1D spectrum_texture;
@@ -13,5 +21,5 @@ void main()
color.rgb = emission.a * emission.rgb;
color.a = emission.a;
- gl_FragColor = color;
+ fragColor = color;
}