pro create_image,iono_data,state,view=oView, model=oModel, image=oImage ; color - can serve as the background color for the graphic scene. ; - the color property of the object to the RGB value of white ; = [255,255,255] obj_destroy, state.obj.oModel obj_destroy, state.obj.oImage state.obj.oModel = obj_new('IDLgrModel') state.obj.oView -> Add, state.obj.oModel state.obj.oImage = obj_new('IDLgrImage', $ palette = state.obj.oPalette, $ iono_data ) state.obj.oModel -> Add, state.obj.oImage freqmhz = [ 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20 ,22, 24, 26, 28, 30] labelx1 = objarr(16) xlast = -1 xvalues = state.data.time_iono_data[0:state.data.xmax-1] for i=0,15 do begin x1 = where (xvalues ge freqmhz[i],cnt1) x2 = where (xvalues le freqmhz[i],cnt2) if x1(0) ge 0 and x2(0) ge 0 then begin xpos = cnt2 xlabel = string(format='(i2)',freqmhz[i]) xlast=xlast+1 labelx1(xlast) = obj_new('IDLgrText', $ xlabel, $ location=[xpos,-10], $ alignment=0.5, $ font=state.obj.oFont, $ color=[0,0,0] ) endif endfor if xlast ge 0 then state.obj.oModel -> Add,labelx1[0:xlast] xcenter = state.data.xmax * 0.5 Row1Text = obj_new('IDLgrText', $ 'TIME AFTER FRAME SYNC (sec)', $ location=[xcenter,-20], $ alignment=0.5, $ font=state.obj.oFont, $ color=[0,0,0]) state.obj.oModel -> Add, Row1Text framesync = [ 0.1, 0.5, 1.0, 1.5, 2.0, 3.0, 4.0, 5.0, $ 8.0, 10.0, 12.0, 14.0, 16.0, 18.0, 20.0, $ 22.0, 24.0, 26.0, 28.0, 30.0 ] xfreq=state.data.freq_iono_data[0:state.data.xmax-1] xfirst = xfreq(0) xsecond = xfreq(40) if xfirst eq xsecond then begin xlabel = string(format='(f6.2)',xfirst) if xfirst lt 0.0 then xlabel = '-1.0' label1st = obj_new('IDLgrText', $ xlabel, $ location=[10,-30], $ alignment=0.5, $ font=state.obj.oFont, $ color=[0,0,0] ) state.obj.oModel -> Add, label1st for i=0,state.data.xmax-1 do begin if xfirst eq xfreq(i) then xfreq(i)=0.0 else goto, jump1 endfor jump1: endif labelx2 = objarr(20) xlast = -1 ix = n_elements(xfreq)-1 for i=0,19 do begin ; x1 = where (xfreq ge framesync[i],cnt1) ; x2 = where (xfreq le framesync[i],cnt2) ; if x1(0) ge 0 and x2(0) ge 0 then begin cnt = -1 for k=40,ix-1 do begin if xfreq(k) gt 0.0 then begin if (framesync[i] ge xfreq(k) and framesync[i] lt xfreq(k+1)) then cnt=k endif endfor if cnt ge 0 then begin ; xpos = cnt2 xpos=cnt xlabel = string(format='(f4.1)',framesync[i]) xlast=xlast+1 labelx2(xlast) = obj_new('IDLgrText', $ xlabel, $ location=[xpos,-30], $ alignment=0.5, $ font=state.obj.oFont, $ color=[0,0,0] ) endif endfor if xlast ge 0 then state.obj.oModel -> Add,labelx2[0:xlast] Row2Text = obj_new('IDLgrText', $ 'FREQUENCY (MHz)', $ location=[xcenter,-40], $ alignment=0.5, $ font=state.obj.oFont, $ color=[0,0,0]) state.obj.oModel -> Add, Row2Text apparange = [ 5000, 4500, 4000, 3500, 3000, 2500, 2000, 1500, 1000, 500, 0 ] labely1 = objarr(11) for i=0,10 do begin y1 = where (state.data.appar_range_data le apparange[i],cnt1) y2 = where (state.data.appar_range_data ge apparange[i],cnt2) if y1(0) ge 0 and y2(0) ge 0 then begin ypos = cnt2 ylabel = string(format='(i4)',apparange[i]) labely1(i) = obj_new('IDLgrText', $ ylabel, $ location=[-5,ypos-2], $ alignment=1.0, $ font=state.obj.oFont, $ color=[0,0,0] ) state.obj.oModel -> Add,labely1(i) endif endfor ; state.obj.oModel -> Add,labely1 oYModel = obj_new('IDLgrModel') state.obj.oModel -> Add, oYModel oYModel -> Rotate,[0,0,1],90 ycenter = state.data.ymax * 0.5 Col1Text = obj_new('IDLgrText', $ 'APPARENT RANGE (km)', $ location=[ycenter,50], $ alignment=0.5, $ font=state.obj.oFont, $ color=[0,0,0]) oYModel -> Add,Col1Text Col2Text = obj_new('IDLgrText', $ 'TIME DELAY (ms)', $ location=[ycenter,- state.data.xmax-40], $ alignment=0.5, $ font=state.obj.oFont, $ color=[0,0,0]) oYModel -> Add,Col2Text timerange = [ 30, 25, 20, 15, 10, 5, 0 ] labely2 = objarr(7) for i=0,6 do begin y1 = where (state.data.time_range_data le timerange[i],cnt1) y2 = where (state.data.time_range_data ge timerange[i],cnt2) if y1(0) ge 0 and y2(0) ge 0 then begin ypos = cnt2 ylabel = string(format='(i2)',timerange[i]) labely2(i) = obj_new('IDLgrText', $ ylabel, $ location=[state.data.xmax+5,ypos-2], $ alignment=0.0, $ font=state.obj.oFont, $ color=[0,0,0] ) state.obj.oModel -> Add,labely2(i) endif endfor ; state.obj.oModel -> Add,labely2 TopText = obj_new('IDLgrText', $ state.data.filecdf, $ ; location=[0,state.data.ymax+10], $ location=[-50,-82], $ font=state.obj.oFontL, $ color=[0,0,0] ) state.obj.oModel -> Add,TopText SysTimeText = obj_new('IDLgrText', $ systime(0), $ ; location=[0,state.data.ymax+10], $ location=[600,-82], $ alignment=0.0, $ font=state.obj.oFontL, $ color=[0,0,0] ) state.obj.oModel -> Add,SysTimeText irange1=0 irange2=255 WIDGET_CONTROL,state.frange1,SET_VALUE=irange1 WIDGET_CONTROL,state.frange2,SET_VALUE=irange2 ; WIDGET_CONTROL,state.frange1,GET_VALUE=val ; irange1=val ; WIDGET_CONTROL,state.frange2,GET_VALUE=val ; irange2=val xrange=strtrim('amplitude range:'+ $ string(format='(i4)',irange1)+'-'+ $ string(format='(i4)',irange2)+' ' $ ,2) obj_destroy, state.obj.oAmpText state.obj.oAmpText = obj_new('IDLgrText', $ xrange, $ location=[state.data.xmax,state.data.ymax+10], $ alignment=1.0, $ font=state.obj.oFont, $ color=[0,0,0] ) state.obj.oModel -> Add,state.obj.oAmpText return end