Malumuth AstroContrib Library

This page is a listing of the entire contents of this library for IDL. This listing is the long version. Viewing the much more compact listing may be handier.

[Go Back to Main IDL Libraries Search Page]


Last modified: Thu Dec 21 21:17:21 2000.

List of Routines


Routine Descriptions

DEL_RAY_WID

[Next Routine] [List of Routines]
                    Delete Cosmic Ray hits in a True Color Image
*NAME:	del_ray_wid.pro

*PURPOSE:  
           Widget tool for zaping pixels in the RED image, the GREEN image or
           the BLUE which has been loaded into TCTOOL


*CATEGORY:  Called by TCTOOL
           

*CALLING SEQUENCE:  del_ray_wid
           

*INPUTS:      NONE
        

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   NONE
           



*EXAMPLES:

*PROCEDURE:
          Pressing the "Edit Pixels button in TCTOOL will call del_ray_wid.
          a small widget called "ZAP PIXEL TOOL" will pop up.
          click on the image that you want to edit. (The red will default
          if no button is pushed).  Enter the size of the Zap Box by
          changing the number in the field (REMEMBER to hit the )
          Press the ZAP PIXELS button, then go into the True Color window.
          Place the cursor on any pixel and press the mouse button, a red,
          green or blue circle will be drawn around the centeral pixel to
          remind you that that pixel has been done.

          When you are finished press the "Done" button, the tool will
          disapear and the images will be redisplayed.

          You may need to do this several times to remove all of the bad
          pixels or to get rid of large Cosmic-Ray trails.
          

*SUPPORT PROCEDURES:
          xyzap - event handler to get the cursor location for del_ray_wid.

*HISTORY:
	6/99	E Malumuth/RITSS
       6/99    E Malumuth/RITSS - added ability to zap pixels using the zoom
                                  window.

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/del_ray_wid.pro)


DISPLAY_BLUE

[Previous Routine] [Next Routine] [List of Routines]
                    Display the blue image in it's window
*NAME:	display_blue.pro

*PURPOSE:  Proceedure to display the blue image in TCTOOL's blue image 
           window with the current stretch and Scaling type.
           


*CATEGORY:  Called by TCTOOL
           

*CALLING SEQUENCE:  display_blue,blue,scale_type,bmin=bmin,bmax=bmax
           

*INPUTS:      blue       - the blue image in TCTOOL.
              scale_type - flag that indicates which scaling type to use
                           0 = linear
                           1 = Log (base 10)
                           2 = square root
                           3 = histogram equalization
        

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   bmin = the minimum value mapped to 0
                       bmax = the maximun value mapped to 255

                       if bmax is missing or equal to 0 display_blue will
                       choose min and max values from the data.
           



*EXAMPLES:

*PROCEDURE:
          TCTOOL calls this procedure when an image is loaded into the blue
          channel using the Read Blue Image button, when any of the 
          Blue Choose Scaling buttons are pushed, the Blue MIN or MAX fields
          are changed of the blue image is edited, trimmed, rotated or shifted.
 
          

*SUPPORT PROCEDURES:  NONE

*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/display_blue.pro)


DISPLAY_GREEN

[Previous Routine] [Next Routine] [List of Routines]
                    Display the green image in it's window
*NAME:	display_green.pro

*PURPOSE:  Proceedure to display the green image in TCTOOL's green image 
           window with the current stretch and Scaling type.
           


*CATEGORY:  Called by TCTOOL
           

*CALLING SEQUENCE:  display_green,green,scale_type,gmin=gmin,gmax=gmax
           

*INPUTS:      green      - the green image in TCTOOL.
              scale_type - flag that indicates which scaling type to use
                           0 = linear
                           1 = Log (base 10)
                           2 = square root
                           3 = histogram equalization
        

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   gmin = the minimum value mapped to 0
                       gmax = the maximun value mapped to 255

                       if gmax is missing or equal to 0 display_green will
                       choose min and max values from the data.
           



*EXAMPLES:

*PROCEDURE:
          TCTOOL calls this procedure when an image is loaded into the green
          channel using the Read Green Image button, when any of the 
          Green Choose Scaling buttons are pushed, the Green MIN or MAX fields
          are changed of the green image is edited, trimmed, rotated or
          shifted.
 
          

*SUPPORT PROCEDURES:  NONE

*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/display_green.pro)


DISPLAY_RED

[Previous Routine] [Next Routine] [List of Routines]
                    Display the red image in it's window
*NAME:	display_red.pro

*PURPOSE:  Proceedure to display the red image in TCTOOL's red image 
           window with the current stretch and Scaling type.
           


*CATEGORY:  Called by TCTOOL
           

*CALLING SEQUENCE:  display_red,red,scale_type,rmin=rmin,rmax=rmax
           

*INPUTS:      red        - the red image in TCTOOL.
              scale_type - flag that indicates which scaling type to use
                           0 = linear
                           1 = Log (base 10)
                           2 = square root
                           3 = histogram equalization
        

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   rmin = the minimum value mapped to 0
                       rmax = the maximun value mapped to 255

                       if rmax is missing or equal to 0 display_red will
                       choose min and max values from the data.
           



*EXAMPLES:

*PROCEDURE:
          TCTOOL calls this procedure when an image is loaded into the red
          channel using the Read Red Image button, when any of the 
          Red Choose Scaling buttons are pushed, the Red MIN or MAX fields
          are changed of the red image is edited, trimmed, rotated or shifted.
 
          

*SUPPORT PROCEDURES:  NONE

*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/display_red.pro)


DISP_TRUE_WID

[Previous Routine] [Next Routine] [List of Routines]
                       Display True Color Image
*NAME:	disp_true_wid.pro

*PURPOSE:  
           Widget tool for displaying the True Color image within TCTOOL


*CATEGORY:  Called by TCTOOL
           

*CALLING SEQUENCE:  disp_true_wid,post
           

*INPUTS:      post - a flag that indicates where the true color image goes.
              
              post=0 ---> display to True Color window in TCTOOL
              post=1 ---> write a postscript file  (idl.ps)
              post=2 ---> write a TIFF file  (idl.tiff)
              post=3 ---> write a JPEG file  (idl.jpeg)

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   NONE
           



*EXAMPLES:

*PROCEDURE:  TCTOOL does all that is needed (post is defined by the
             "WRITE IMAGE" pull down menu).
          

*SUPPORT PROCEDURES:  NONE


*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/disp_true_wid.pro)


DISP_TRUE_ZOOM

[Previous Routine] [Next Routine] [List of Routines]
                      Zoom True Color Image
*NAME:	disp_true_zoom.pro

*PURPOSE:  
           Widget tool for displaying the True Color image within 
           the TCTOOL zoom window


*CATEGORY:  Called by ZOOMWIND
           

*CALLING SEQUENCE:  disp_true_zoom,zoomfact
           

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   NONE
           



*EXAMPLES:

*PROCEDURE:  TCTOOL does all that is needed ;          

*SUPPORT PROCEDURES:  NONE


*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/disp_true_zoom.pro)


EDIT_IMAGE_WID

[Previous Routine] [Next Routine] [List of Routines]
                           Edit Image Tool
*NAME:	edit_image_wid.pro

*PURPOSE:  
           Widget tool for trimming or otherwise editing the RED image, the 
           GREEN image or the BLUE which has been loaded into TCTOOL.

           At present only trimming and subtracting sky.


*CATEGORY:  Called by TCTOOL
           

*CALLING SEQUENCE:  edit_image_wid
           

*INPUTS:      NONE
        

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   NONE
           

*EXAMPLES:

*PROCEDURE:
          Pressing the "Edit Images button in TCTOOL will call edit_image_wid.
          a small widget called "EDIT IMAGE TOOL" will pop up.
          click on the image that you want to edit. (The red will default
          if no button is pushed).  

          To Trim an image: Enter the X-SIZE and Y-SIZE (it's best if they are 
          the same) of the trimmed image (REMEMBER to hit the ).  You
          may enter the X-CENTER and Y-CENTER or use the cursor in the
          True Color window by first pressing the "USE CURSOR TO SET THE 
          CENTER" button.

          This can be useful if you have images which are the same scale
          but not the same size, or if there is a large shift between them.
          Choose the red image, click of an object near the center and trim
          the image.  Then use the same X-SIZE and Y-SIZE but click on the
          same object in the green image and then the blue image.

          Press the "TRIM" button once the image is selected and the size
          and centering are entered.

          Pressing the "SUBTRACT SKY" button will run the SKY proceedure
          and subtract the resulting sky value from the image.

          When you are finished press the "Done" button.         

*SUPPORT PROCEDURES:
          xytrim - event handler to get the cursor location for edit_image_wid.
          sky    - determins the median sky value.

*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/edit_image_wid.pro)


FSHIFT

[Previous Routine] [Next Routine] [List of Routines]
			fshift

 Routine to shift an image by non-integer values

 CALLING SEQUENCE:
	results = fshift(image,delx,dely)

 INPUTS:
	image - 2D image to be shifted
	delx - shift in x (same direction as IDL SHIFT function)
	dely - shift in y

 OUTPUTS:
	shifted image is returned as the function results

 HISTORY:
	version 2  D. Lindler  May, 1992 - rewritten for IDL version 2
	19-may-1992	JKF/ACC		- move to GHRS DAF.

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/fshift.pro)


ROTAT_WID

[Previous Routine] [Next Routine] [List of Routines]
                           Rotate Image Tool
*NAME:	rotat_wid.pro

*PURPOSE:  
           Widget tool for rotating, magnifying or demagnifying the RED 
           image, the GREEN image or the BLUE which has been loaded into 
           TCTOOL.

           It's a wrapper for a call to the IDL library function ROT.


*CATEGORY:  Called by TCTOOL
           

*CALLING SEQUENCE:  rotat_wid
           

*INPUTS:      NONE
        

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   NONE
           

*EXAMPLES:

*PROCEDURE:
          Pressing the "Rotate Images button in TCTOOL will call rotat_wid.
          a small widget called "ROTATE TOOL" will pop up.
          click on the image that you want to rotate, magnify or demagnify. 
          (The red will default if no button is pushed).  

          Enter the angle to rotate by (positive is clockwise - negative 
          is counter-clockwise), the magnification ( > 1.0 - magnify, < 1.0
          will demagnify), and the pixel X-CENTER and Y-CENTER to rotate
          about (this pixel will be used as the pivot point.)  You
          may enter the X-CENTER and Y-CENTER or use the cursor in the
          True Color window by first pressing the "USE CURSOR" button.

          This can be useful if you have images which are not the same scale,
          or if there is a rotation between them (i.e. 2 HST image taken at
          different time or with different camera - WFPC2 and STIS).

          Press the "ROTATE" button once the image is selected and the 
          other information is entered.  REMEMBER to Press the  when
          changing a value in and field.

          When you are finished press the "Done" button.         

*SUPPORT PROCEDURES:
          xycenter - event handler to get the cursor location for rotat_wid.

*SUPPORT FUNCTIONS:
          rot      - rotates the image.

*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/rotat_wid.pro)


TCTOOL

[Previous Routine] [Next Routine] [List of Routines]
                          TRUE COLOR IMAGE TOOL
*NAME:	tctool.pro

*PURPOSE:  
           Widget tool for combining a RED image, a GREEN image and a BLUE
           image into a pseudo true color image.  

           This routine draws all of the Widget buttons, sliders, windows, etc.
           It handles all of the widget events and calls the various other
           routines that do the plotting, etc.
    
           NOTE ;

*CATEGORY:  
           WIDGET

*CALLING SEQUENCE:  
           tctool,red1=red_image,green1=green_image,blue1=blue_image

*INPUTS:  
           NONE

*OUTPUTS: 
           NONE

*KEYWORD PARAMETERS: 
           RED1:   If set equal to the red image there is no need to
                   read the red image in.  This is useful if the red image
                   isn't a fits image or if you need to process the red image
                   before using as part of a true color image.

           GREEN1: If set equal to the green image there is no need to
                   read the green image in.  This is useful if the green image
                   isn't a fits image or if you need to process the green image
                   before using as part of a true color image.

           BLUE1:  If set equal to the blue image there is no need to
                   read the blue image in.  This is useful if the blue image
                   isn't a fits image or if you need to process the blue image
                   before using as part of a true color image.


*NOTES:
          TO RUN THIS WIDGET YOU MUST ENTER 24BIT MODE BEFORE ENTERING IDL.


*EXAMPLES:

*PROCEDURE:
          Enter 24bit mode in a XTERM window by typing 24bit.
          Enter IDL, then type tctool.
          When the WIDGET appears, use the "Read Red Image", "Read Green Image"
          and "Read Blue Image" buttons to load 3 FITS images of the same field
          taken in different bands into the red, green, and blue images in
          the program.  Note: these image need not be at the same resolution,
          orientations or field of view, you will be able to manipulate the
          size, magnification and roll of each image.

          When each image is loaded it will be displayed in it's own small
          window (200x200) with a linear stretch.  You can change the stretch
          by entering the new min or max value in the appropriate field and
          hitting a .  You must do the  to get the new value.

          You may also change the kind of stretch to logarithmic (base 10),
          square root, or histogram equalization.  Each image works independent
          of the others.  

          NOTE: the automatic display of the linear stretch works only with
          images read in using the buttons.  For images input on the command
          line you must push on the the "Choose Scaling" buttons. 

          Once all 3 images are loaded and displayed the "Make True Color",
          "Edit Pixels", "Edit Images", "Rotate" buttons and "WRITE IMAGE" 
          menu will become unghosted.

          Push the "Make True Color" button to see the true color image
          displayed in the large window (600x600).

          NOTE: The nature of a 24bit IDL session is that to see the correct
          color of displayed image the cursor must be in one of the display
          windows.  This makes seeing the buttons difficult.  You get one or
          the other.

          Once the True Color image is displayed you can shift any of the
          images using the "Shift" size field and direction buttons.  Enter
          the size of the shift that you want and then press the direction.
          DO NOT FORGET to PRESS the  or the new size will not register.
          You can also rotate any image and magnify or demagnify the image
          Using the "Rotate" button.  This pops up a new widget with will
          ask for the input values for a call to the IDL library procedure 
          ROT.  You can also trim any image to any size using the "EDIT IMAGES"
          button.  This pop up widget will also let you subtract a sky 
          background.

          The "EDIT PIXELS" button will pop up a widget that lets you replace
          the values in a box of the size you specify with the median value
          of the surrounding pixels.  You click on the True Color image on the
          pixel at the center of the box that you want to replace.

          NOTE: some of these action will automatically refresh the True Color
          image while others will not.  Pressing the "Make True Color" button
          will always refresh the True Color image.

          Finally you may write a postscript file, a TIFF file or a JPEG
          file of the True Color image, or write out the processed red, green
          or blue image using the "WRITE IMAGE" pull down menu.

*SUPPORT PROCEDURES:
          del_ray_wid - for editing the pixels in a box.
          disp_true_wid - for making the true color image and displaying it
                          to the window or writing it out.
          display_blue - displays the blue image
          display_green - displays the green image
          display_red - displays the red image
          edit_image_wid - trims the image
          rotat_wid - rotates the image
          xycenter - event handler to get the cursor location for rotat_wid
          xytrim - event handler to get the cursor location for edit_image_wid
          xyzap - event handler to get the cursor location for del_ray_wid.

*HISTORY:
	6/99	E Malumuth/RITSS
       6/99    E Malumuth/RITSS - bug fixed, zoom window feature added


(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/tctool.pro)


XYCENTER

[Previous Routine] [Next Routine] [List of Routines]
                           
*NAME:	xycenter.pro

*PURPOSE:  
           Event handler for events in TCTOOLs TRUE COLOR window while in
           proceedure rotat_wid.


*CATEGORY:  Called by Rotat_wid
           

*CALLING SEQUENCE:  xycenter
           

*INPUTS:      NONE
        

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   NONE
           

*EXAMPLES:

*PROCEDURE:
           Remeber to press the "USE CURSOR" button in rotat_wid before
           clicking in the True Color window.  Failure to do may crash
           TCTOOL.  HOWEVER, YOU CAN RECOVER BY TYPING "RETURN" (not retall)
           in the idl window that launched TCTOOL.      

*SUPPORT PROCEDURES: NONE


*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/xycenter.pro)


XYTRIM

[Previous Routine] [Next Routine] [List of Routines]
                           
*NAME:	xytrim.pro

*PURPOSE:  
           Event handler for events in TCTOOLs TRUE COLOR window while in
           proceedure edit_image_wid.


*CATEGORY:  Called by edit_image_wid
           

*CALLING SEQUENCE:  xytrim
           

*INPUTS:      NONE
        

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   NONE
           

*EXAMPLES:

*PROCEDURE:
           Remeber to press the "USE CURSOR TO SET THE CENTER" button in 
           edit_image_wid before clicking in the True Color window.  Failure 
           to do so may crash TCTOOL.  YOU CAN RECOVER BY TYPING "RETURN" 
           (not retall) in the idl window that launched TCTOOL.      

*SUPPORT PROCEDURES: NONE


*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/xytrim.pro)


XYZAP

[Previous Routine] [Next Routine] [List of Routines]
                           
*NAME:	xyzap.pro

*PURPOSE:  
           Event handler for events in TCTOOLs TRUE COLOR window while in
           proceedure del_ray_wid.


*CATEGORY:  Called by del_ray_wid
           

*CALLING SEQUENCE:  xyzap
           

*INPUTS:      NONE
        

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   NONE
           

*EXAMPLES:

*PROCEDURE:
           Remeber to press the "ZAP PIXELS" button in del_ray_wid before
           clicking in the True Color window.  Failure to do may crash
           TCTOOL.  HOWEVER, YOU CAN RECOVER BY TYPING "RETURN" (not retall)
           in the idl window that launched TCTOOL.      

*SUPPORT PROCEDURES: NONE


*HISTORY:
	6/99	E Malumuth/RITSS
       6/99    E Malumuth/RITSS - Now handels events in True Color Window
                                  and/or the zoom window.

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/xyzap.pro)


ZOOMWIND

[Previous Routine] [List of Routines]
                      Zoom Tool
*NAME:	zoomwind

*PURPOSE:  
           Widget tool to pop up a True Color zoom window within TCTOOL


*CATEGORY:  Called by TCTOOL
           

*CALLING SEQUENCE:  zoomwind
           

*OUTPUTS:     NONE
       

*KEYWORD PARAMETERS:   NONE
           



*EXAMPLES:

*PROCEDURE:  set the slide bar to the desired zoom factor then press the 
             Display button
          

*SUPPORT PROCEDURES:  NONE


*HISTORY:
	6/99	E Malumuth/RITSS

(See /host/bluemoon/usr2/idllib/astron/contrib/malumuth/zoomwind.pro)