--- ray/src/px/psquish.csh 2003/02/22 02:07:27 3.2 +++ ray/src/px/psquish.csh 2005/02/16 05:40:11 3.4 @@ -1,11 +1,11 @@ #!/bin/csh -f -# RCSid: $Id: psquish.csh,v 3.2 2003/02/22 02:07:27 greg Exp $ +# RCSid: $Id: psquish.csh,v 3.4 2005/02/16 05:40:11 greg Exp $ set Lmin=.0001 # minimum visible world luminance set Ldmin=1 # minimum display luminance set Ldmax=100 # maximum display luminance set nsteps=100 # number of steps in perceptual histogram set cvratio=0.05 # fraction of pixels to ignore in envelope clipping -set td=/usr/tmp +set td=/tmp set tf0=$td/tf$$ set tf1=$td/hist$$ set tf1b=$td/hist$$.diff @@ -100,7 +100,7 @@ set margin=`ev "floor($totcount*$cvratio+.5)"` while ( 1 ) # Compute mapping function sed 's/^.*[ ]//' $tf1 | total -1 -r \ - | rcalc -e '$1=$1/'$totcount | lam $tf1 - \ + | rcalc -e '$1=$1/'$totcount | rlam $tf1 - \ | tabfunc -i 0 cf > $tf4 # Compute difference with visible envelope rcalc -f $tf4 -f $tf3 -e "T:$totcount*Stepsiz" \ @@ -149,7 +149,7 @@ while ( 1 ) endif end # Mung histogram - echo $diffs | tr ' ' '\012' | lam $tf1 - \ + echo $diffs | tr ' ' '\012' | rlam $tf1 - \ | rcalc -f $tf4 -f $tf3 -e "T:$totcount*Stepsiz" \ -e 'clfq=floor(T*clamp(Lb($1))+.5)' \ -e '$1=$1;$2=$3+clfq' > $tf1b