ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/px/pdfblur.csh
(Generate patch)

Comparing ray/src/px/pdfblur.csh (file contents):
Revision 2.2 by greg, Fri Sep 15 17:13:54 1995 UTC vs.
Revision 2.6 by greg, Tue Jan 18 01:37:43 2005 UTC

# Line 1 | Line 1
1   #!/bin/csh -f
2 < # SCCSid "$SunId$ LBL"
2 > # RCSid: $Id$
3   #
4 < # Do depth-of-field blurring on picture
4 > # Generate views for depth-of-field blurring on picture
5   #
6 < if ($#argv < 5) then
7 <        echo "Usage: $0 aperture distance nsamp picfile zfile [pinterp opts]" >/dev/tty
6 > if ($#argv != 3) then
7 >        echo "Usage: $0 aperture nsamp viewfile"
8          exit 1
9   endif
10   set a = "$1"
11 < set d = "$2"
12 < set n = "$3"
13 < set pict = "$4"
14 < set zbf = "$5"
15 < set piopt = ($argv[6-]:q)
16 < cnt $n | rcalc -e `vwright i < $pict` \
17 < -e "M:$n/5+1;a:$a/2;d:$d;N:$n;" -e 'tmax:PI*a*(M+1)' \
11 > set n = "$2"
12 > set vf = "$3"
13 > cnt $n | rcalc -e `vwright i < $vf` \
14 > -e "M:$n/5+1;a:$a/2;N:$n;" -e 'tmax:PI*a*(M+1)' \
15   -e 't=tmax/N*($1+rand($1))' \
16   -e 'theta=2*M*PI/(M-1)*(M-sqrt(M*M-(M-1)/(PI*a)*t))' \
17   -e 'r=a*(1-(M-1)/(2*M*M*PI)*theta)' \
# Line 22 | Line 19 | cnt $n | rcalc -e `vwright i < $pict` \
19   -e 'opx=ipx+rcost*ihx+rsint*ivx' \
20   -e 'opy=ipy+rcost*ihy+rsint*ivy' \
21   -e 'opz=ipz+rcost*ihz+rsint*ivz' \
22 < -e 'os=is-rcost/(d*ihn);ol=il-rsint/(d*ivn)' \
23 < -o 'VIEW= -vp ${opx} ${opy} ${opz} -vs ${os} -vl ${ol}' \
27 < | pinterp -vf $pict $piopt -B $pict $zbf
22 > -e 'os=is-rcost/(id*ihn);ol=il-rsint/(id*ivn)' \
23 > -o 'VIEW= -vp ${opx} ${opy} ${opz} -vs ${os} -vl ${ol}'

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines