ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/libgender/material.C
(Generate patch)

Comparing libgender/material.C (file contents):
Revision 1.49 by root, Sun Nov 7 22:07:05 2004 UTC vs.
Revision 1.50 by root, Sun Nov 7 22:40:58 2004 UTC

90 { 90 {
91 using namespace shader::compile; 91 using namespace shader::compile;
92 92
93 temp_1f lz; 93 temp_1f lz;
94 94
95 // TODO: negative z is not calculated in an acceptable way 95 // TODO: negative z is not calculated in an acceptable way, clipping does horrible things(?)
96 lz = z (vout.position); 96 lz = z (vout.position);
97 z (vout.position) = (ifelse (lz < 0, lz, log (lz) * (2 / log (1e10))) - 1) * w (vout.position); 97 z (vout.position) = (ifelse (
98 lz < 0,
99 lz,
100 log (lz) * (2 / log (1e10))
101 ) - 1) * w (vout.position);
98 } 102 }
99 103
100 vsh_src = shader::shader_builder::stop (); 104 vsh_src = shader::shader_builder::stop ();
101 105
102 shader::shader_builder::start (); 106 shader::shader_builder::start ();

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines