m_one.pro

pro m_one,nn
openr,1,'fan.128_ascii'
openw,2,'temp.dat'
if (nn lt 10) then printf,2,format='(i1)',nn
if (nn ge 10) then printf,2,format='(i2)',nn
close,2
openr,2,'temp.dat'
mm=string('')
readf,2,mm
pp="fan"+mm+".byt"
window,0,xsize=200,ysize=50,xpos=100,ypos=400
xyouts,10,30,pp,/device,size=1.3
close,2
openw,3,pp
p=assoc(3,bytarr(256,256))
window,1,xsize=256,ysize=256,xpos=100,ypos=100
for i=1,nn do begin
c=intarr(128,128)
readf,1,c
b=rebin(c,256,256)
tvscl,b
empty
endfor
p(0)=tvrd(0,0,256,256)
close,1
close,2
close,3
spawn,'rm temp.dat'
return
end