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

gpu_shader_fire_frag.glsl « shaders « gpu « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 3819203bcd9f8f58bbe30df69c1354e69978a36f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17

varying vec3 coords;

uniform sampler3D flame_texture;
uniform sampler1D spectrum_texture;

void main()
{
	float flame = texture3D(flame_texture, coords).r;
	vec4 emission = texture1D(spectrum_texture, flame);

	vec4 color;
	color.rgb = emission.a * emission.rgb;
	color.a = emission.a;

	gl_FragColor = color;
}