Im still getting used to idl so excuse if I ask something stupid.
Im am using display for my images (http://cosmology.berkeley.edu/group/
cmbanalysis/forecast/idl/display.pro).
To use it with your nice program I added the following:
pro gmwindow::display,image,p1,p2,no_draw=no_draw,_extra=_extra
if ~self.ps then wset,self.pixmap_index
sz=size(image,/dim)
sz_cm=sz/self.ppcm_screen
q=n_elements(sz) eq 3?where(sz ne 3):[0,1]
sz[q]*=self.f
im=rebin(image,sz) ;should manage true colour as well
case (n_elements(p1) gt 0)+(n_elements(p2) gt 0)+(n_elements(p3) gt
0)+self.ps*4 of
;screen cases
0:display,im,_extra=_extra
1:display,im,p1,_extra=_extra
2:display,im,p1*self.f,p2*self.f,_extra=_extra
; 3:display,im,p1*self.f,p2*self.f,p3,_extra=_extra
;ps versions
3:display,im,_extra=_extra
4:display,im,p1,_extra=_extra
5:display,im,p1/self.ppcm_screen,p2/self.ppcm_screen,/
centimeters,xsize=sz_cm[0],ysize=sz_cm[1],_extra=_extra
; 7:display,im,p1/self.ppcm_screen,p2/self.ppcm_screen,p3,/
centimeters,xsize=sz_cm[0],ysize=sz_cm[1],_extra=_extra
endcase
I used just modified the code for gmwindow::tv (since display uses the
tv command).
It seems to work. Or did I do something wrong?
Thanks
|