glviewvol
diff sdr/fast.p.glsl @ 4:04330eb80b36
lots of stuff
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Mon, 29 Dec 2014 05:41:36 +0200 |
parents | |
children | fb6d93471352 |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/sdr/fast.p.glsl Mon Dec 29 05:41:36 2014 +0200 1.3 @@ -0,0 +1,11 @@ 1.4 +uniform sampler3D vol_tex; 1.5 +uniform sampler1D xfer_tex; 1.6 + 1.7 +void main() 1.8 +{ 1.9 + vec4 voxel = texture3D(vol_tex, gl_TexCoord[0].xyz); 1.10 + vec4 color = texture1D(xfer_tex, voxel.a); 1.11 + 1.12 + gl_FragColor.rgb = color.rgb; 1.13 + gl_FragColor.a = 1.0; 1.14 +}