Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/pure-cfg/test/vr-kcomp.diderot
ViewVC logotype

Diff of /branches/pure-cfg/test/vr-kcomp.diderot

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 779, Thu Apr 7 22:38:07 2011 UTC revision 791, Fri Apr 8 20:36:22 2011 UTC
# Line 53  Line 53 
53         if (inside (rayPos,Fc1)) {         if (inside (rayPos,Fc1)) {
54            // ########## BEGIN per-sample code            // ########## BEGIN per-sample code
55            real val = 0.0;            real val = 0.0;
56            vec3 grad = [0.0,0.0,0.0];            vec3 norm = [0.0,0.0,0.0];
57            // HEY (scoping BUG): the strand parameters (e.g. ui, vi) can't            // HEY (scoping BUG): the strand parameters (e.g. ui, vi) can't
58            // appear in conditionals            // appear in conditionals
59            if (myui + myvi < imgResU) {            if (myui + myvi < imgResU) {
60               val = Fc0@rayPos;               val = Fc0@rayPos;
61               grad = ∇Fc0@rayPos;               norm = normalize(-∇Fc0@rayPos);
62            } else {            } else {
63               val = Fc1@rayPos;               val = Fc1@rayPos;
64               grad = ∇Fc1@rayPos;               norm = normalize(-∇Fc1@rayPos);
65            }            }
           vec3 norm = normalize(-grad);  
66            if (val > valOpacMin) {  // we have some opacity            if (val > valOpacMin) {  // we have some opacity
67                real opac = min(1.0, lerp(0.0, 1.0, valOpacMin, val, valOpacMax));                real opac = min(1.0, lerp(0.0, 1.0, valOpacMin, val, valOpacMax));
68                real ld = lightDir • norm;                real ld = lightDir • norm;

Legend:
Removed from v.779  
changed lines
  Added in v.791

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0