| 1 |
|
#!/bin/csh -f |
| 2 |
< |
# SCCSid "$SunId$ LBL" |
| 2 |
> |
# RCSid: $Id$ |
| 3 |
|
# |
| 4 |
|
# Display one or more CIE XYZE pictures using ximage |
| 5 |
|
# |
| 48 |
|
endsw |
| 49 |
|
set i=$i1 |
| 50 |
|
end |
| 51 |
+ |
set td=/tmp/xyz$$ |
| 52 |
+ |
set ecode=1 |
| 53 |
|
onintr quit |
| 54 |
+ |
mkdir $td |
| 55 |
|
if ( ! $firstarg ) then |
| 56 |
< |
set rgbfiles=/usr/tmp/stdin.$$ |
| 54 |
< |
ra_xyze -r -u $popt > /usr/tmp/stdin.$$ |
| 56 |
> |
ra_xyze -r -u $popt > $td/stdin |
| 57 |
|
if ( $status ) goto quit |
| 58 |
|
else |
| 57 |
– |
set rgbfiles="" |
| 59 |
|
set i=$firstarg |
| 60 |
|
while ( $i <= $#argv ) |
| 61 |
< |
set rgbfiles=($rgbfiles /usr/tmp/$argv[$i]:t.$$) |
| 61 |
< |
ra_xyze -r -u $popt $argv[$i] /usr/tmp/$argv[$i]:t.$$ |
| 61 |
> |
ra_xyze -r -u $popt $argv[$i] $td/$argv[$i]:t |
| 62 |
|
if ( $status ) goto quit |
| 63 |
|
@ i++ |
| 64 |
|
end |
| 65 |
|
endif |
| 66 |
< |
ximage $xiargs $rgbfiles |
| 66 |
> |
ximage $xiargs $td/* |
| 67 |
> |
set ecode=$status |
| 68 |
|
quit: |
| 69 |
< |
rm -f $rgbfiles |
| 70 |
< |
exit 0 |
| 69 |
> |
rm -rf $td |
| 70 |
> |
exit $ecode |
| 71 |
|
notenough: |
| 72 |
|
echo "Missing arguments for $argv[$i] option" |
| 73 |
|
exit 1 |