FITS Viewer
Loading an Image
When the FITS viewer is first initalized, you will be presented with three options for loading an image.
The choose file button allows you to load in a FITS file from your local disk. Note that files loaded from your local machine will be uploaded to the ASCOT server in order to preserve gadget state persistence. Depending on the file size, this will cause a delay when loading an image from your hard drive.
FITS files can also be loaded from a URL. When this is done, only the URL is saved to the gadget state, so the FITS image is downloaded from the remote location each time it is viewed.
Finally, images generated with the SciDB gadgets can be retrieved from the scalrr server. Links in the SciDB dropdown box are updated as images are generated with the SciDB gadgets.
After an image with a valid coordinate system (see wcsjs for a list of valid coordinate systems) is loaded, the gadget sends a viewport boundary notification to the dashboard. This allows gadgets like the Data Inquirer to construct a query based on the physical boundaries of the image. For more information about what types of images are supported by the FITS Viewer, see fitsjs.
Panning and Scaling
Images can be panned by clicking and dragging on an empty area of the viewer. Zooming is also possible with the mouse wheel.
The FITS viewer gadget also provides some basic scaling and stretching controls. The scale controls appear below the image, while the stretch options are found under the 'stretch' menu.
Annotations
After an image is loaded, the user can place annotations onto the image from the 'Add Region' menu. After selecting an option from the menu, annotations are created by dragging the mouse on the image. Once an annotation is placed, it can be moved by clicking and dragging it. Additionally, properties of the annotations, such as dimension can be modified by dragging the handles, which are visible once an annotation is highlighted. For more precise editing, the user can double click on an annotation to bring up a properties dialog. From this dialog, the user can edit the values of the position and dimensions of the annotation, in terms of either pixel or wcs coordinates. There is also a 'delete' button, which removes the annotation completely.
If a dataset with spatial information is loaded, the 'Annotations' option from the 'Datasets' menu can be used to overlay a series of circles on the image which correspond to the entries in the dataset. The user must specify which fields in the dataset contain ra and dec values. Once the overlay is created, the annotations associated with it are fixed, since ASCOT datasets are immutable. One can color dataset points with the FITS viewer, much like with other gadgets by using the 'Select Points' option from the 'Datasets' menu. Note that the select points tool only works with dataset points and not user-created annotations.
Note that the properties dialog for the rectangle annotation has an additional button, 'SciDB Query Bounds'. This button will send the boundaries of the rectangle to any SciDB gadgets in order to construct a query.