pro plot_save_sweep,radar,org_file_base,img_file,field,like_field,isweep,maxrng,$ SCAN_TYPE=scan_type,LOCALE=local,POSTSCRIPT=postscript COMMON dirs,img_dir,uf_dir,hid_img_dir,hid_dir,dsd_dir COMMON misc,TRUE,FALSE COMMON graphics,USE_Z_BUFFER,TC,XS,YS COMMON graphic_parms,scale,bottom,ncolors COMMON my_colors,black,purple,blue,cyan,green,yellow,orange,red,white COMMON symbols,plot,asterisk,dot,diamond,triangle,square,exx COMMON linestyles,solid,dotted,dashed,dashdot,dashdotdot,longdash !QUIET=1 if(NOT KEYWORD_SET(POSTSCRIPT)) then postscript=FALSE if(NOT KEYWORD_SET(LOCALE)) then locale='WALLOPS' date_time = rsl_datetime(radar,jdate=jdate) year = strmid(date_time,0,4) month = strmid(date_time,4,2) day = strmid(date_time,6,2) xs=599 & ys=599 ; ; *** Set min/max values, unless this is HID, the use optional ; *** rsl_plotsweep_from_radar modified by CSU. ; ; *** NOTE: Call PPS's PPIs for web display. ; image_scan_type = strupcase(scan_type) if(strupcase(scan_type) eq 'PPI SECTOR') then image_scan_type = 'PPI' img_base = img_dir + org_file_base + '.' + image_scan_type + '_' + field CASE field of 'FH': BEGIN setup_graphics,img_base,img_file,postscript=postscript,$ cols=cols,rows=rows,CHARSIZE=1.0,colortable=0 rsl_plotsweep_from_radar_fh,radar,field=field,like_field=like_field, $ maxrange=maxrng,maxheight=maxhgt,sweep_index=isweep,/horizontal END 'VR': BEGIN setup_graphics,img_base,img_file,postscript=postscript,$ cols=cols,rows=rows,CHARSIZE=1.0 rsl_plotsweep_from_radar_fh,radar,field=field,like_field=like_field, $ maxrange=maxrng,maxheight=maxhgt,sweep_index=isweep,/horizontal END 'RR': BEGIN setup_graphics,img_base,img_file,postscript=postscript,$ cols=cols,rows=rows,CHARSIZE=1.0 rsl_plotsweep_from_radar_fh,radar,field=field,like_field='RR', $ maxrange=maxrng,maxheight=maxhgt,sweep_index=isweep,/horizontal END 'RP': BEGIN setup_graphics,img_base,img_file,postscript=postscript,$ cols=cols,rows=rows,CHARSIZE=1.0 rsl_plotsweep_from_radar_fh,radar,field=field,like_field='RR', $ maxrange=maxrng,maxheight=maxhgt,sweep_index=isweep,/horizontal END ELSE: BEGIN get_plot_parms,field,minval,maxval, $ CB_FORMAT=cb_format, CB_DIVISIONS=cb_divisions, $ CB_CTABLE=cb_ctable, CB_BOTTOM=cb_bottom, $ CB_TITLE=cb_title, CB_POSITION=cb_position, $ CB_NCOLORS=cb_ncolors, CB_MINOR=cb_minorformat setup_graphics,img_base,img_file,postscript=postscript,$ cols=cols,rows=rows,CHARSIZE=1.0,colortable=cb_ctable rsl_plotsweep_from_radar_fh,radar,field=field,like_field=like_field, $ maxrange=maxrng,maxheight=maxhgt,sweep_index=isweep, $ minval=minval,maxval=maxval,bottom=48,/horizontal, $ cb_position=cb_position,/noloadct,divisions=cb_divisions, $ format=cb_format END ENDCASE ; ; *** Plot site locations ; plot_site_locations,LOCALE=locale ; ; *** Save the image to a file ; if(postscript) then begin device,/close fileb = file_basename(img_file,'.ps') new_png = img_dir + fileb + '.png' c = 'convert -density 100 -background white -flatten ' + img_file + ' ' + new_png spawn,c print,' ' + new_png spawn,'rm ' + img_file ; Remove postscript version img_file = new_png endif else begin if(!D.name ne 'X') then pngit,img_file pngit,img_file endelse return end