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

Comparing ray/src/px/falsecolor.csh (file contents):
Revision 2.3 by greg, Fri Aug 21 15:46:11 1992 UTC vs.
Revision 2.8 by greg, Sat Feb 22 02:07:27 2003 UTC

# Line 1 | Line 1
1 < #!/bin/csh -f
2 < # SCCSid "$SunId$ LBL"
1 > #!/bin/csh -fe
2 > # RCSid: $Id$
3   #
4   # Create false color image with legend
5   #
# Line 15 | Line 15 | set bluv='1-8/3*v'
15   set ndivs=8
16   set picture='-'
17   set cpict=
18 + set loff=0
19   set legwidth=100
20   set legheight=200
21   while ($#argv > 0)
# Line 63 | Line 64 | while ($#argv > 0)
64                  breaksw
65          case -cl:
66                  set docont=a
67 +                set loff=12
68                  breaksw
69          case -cb:
70                  set docont=b
71 +                set loff=13
72                  breaksw
73          case -e:
74                  set doextrem
# Line 139 | Line 142 | if ($?needfile && "$picture" == '-') then
142          cat > $td/picture
143          set picture=$td/picture
144   endif
145 < if ($decades > 0) then
145 > if ("$decades" != "0") then
146          set pc1args=($pc1args -e "map(x)=if(x-10^-$decades,log10(x)/$decades+1,0)")
147          set imap="imap(y)=10^((y-1)*$decades)"
148   else
# Line 150 | Line 153 | pcomb $pc0args -e 'v=(y+.5)/yres;vleft=v;vright=v' \
153                  -x $legwidth -y $legheight > $td/scol.pic
154   ( echo $label; cnt $ndivs \
155                  | rcalc -e '$1='"($scale)*imap(($ndivs-.5-"'$1'")/$ndivs)" \
156 <                -e "$imap" ) \
156 >                -e "$imap" | sed -e 's/\(\.[0-9][0-9][0-9]\)[0-9]*/\1/' ) \
157          | psign -s -.15 -cf 1 1 1 -cb 0 0 0 \
158                  -h `ev "floor($legheight/$ndivs+.5)"` > $td/slab.pic
159   if ( $?doextrem ) then
160          pextrem -o $picture > $td/extrema
161          set minpos=`sed 2d $td/extrema | rcalc -e '$2=$2;$1=$1+'"$legwidth"`
162 <        set minval=`rcalc -e '$1=($3*.3+$4*.59+$5*.11)*'"$mult" $td/extrema | sed -e 2d -e 's/\(.....\).*$/\1/'`
162 >        set minval=`rcalc -e '$1=($3*.27+$4*.67+$5*.06)*'"$mult" $td/extrema | sed -e 2d -e 's/\(\.[0-9][0-9][0-9]\)[0-9]*/\1/'`
163          set maxpos=`sed 1d $td/extrema | rcalc -e '$2=$2;$1=$1+'"$legwidth"`
164 <        set maxval=`rcalc -e '$1=($3*.3+$4*.59+$5*.11)*'"$mult" $td/extrema | sed -e 1d -e 's/\(.....\).*$/\1/'`
164 >        set maxval=`rcalc -e '$1=($3*.27+$4*.67+$5*.06)*'"$mult" $td/extrema | sed -e 1d -e 's/\(\.[0-9][0-9][0-9]\)[0-9]*/\1/'`
165          psign -s -.15 -a 2 -h 16 $minval > $td/minv.pic
166          psign -s -.15 -a 2 -h 16 $maxval > $td/maxv.pic
167          pcomb $pc0args $pc1args $picture $cpict \
168 <                | pcompos $td/scol.pic 0 0 -t .2 $td/slab.pic 0 20 \
168 >                | pcompos $td/scol.pic 0 0 -t .2 $td/slab.pic 0 $loff \
169                    - $legwidth 0 $td/minv.pic $minpos $td/maxv.pic $maxpos
170   else
171          pcomb $pc0args $pc1args $picture $cpict \
172 <                | pcompos $td/scol.pic 0 0 -t .2 $td/slab.pic 0 20 - $legwidth 0
172 >                | pcompos $td/scol.pic 0 0 -t .2 $td/slab.pic 0 $loff - $legwidth 0
173   endif
174   quit:
175   rm -rf $td

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines