Image-Independent Processing Interfaces and View Selection Lists



::Index  <Prev  >Next

Abstract Interfaces

View Selection Lists



Abstract Interfaces

Processing windows are image-independent processing interfaces in PixInsight. Being a strongly object-oriented environment, PixInsight not only encapsulates data and functionality of processes, but it gives you an abstract interface for each process.

The practical meaning of this level of abstraction is that, generally speaking, you don't need an image to define a process in PixInsight. In other words, you can manage processes independently of images.

From the software developer perspective, image-independent interfaces can be quite easily built for many processes. For example, consider the MedianFilter process. There is absolutely nothing in MedianFilter that makes it dependent on any characteristic of a particular image. So the standard interface for this process, namely the Median Filter window, behaves exactly the same way whether an image is available or not:

MedianFilter is a good example of those processes that are image-independent by nature, in a smoothly easy and simple way.


View Selection Lists

There are other processes, however, for which things are not so obvious. Resample is one of them. We can define a resampling interface in purely abstract terms, of course, but then we lose some nice functionality. In particular, we love to see how if we change an image's width, its height is automatically updated to preserve the original aspect ratio. Or changing an image's size in bytes and obtaining the corresponding rescaled dimensions in pixels, centimeters and inches, taking into account the image's resolution, also automatically.

In such cases, our goal has been to account for all these desiderata and achieve an abstract process interface at the same time. For this purpose, we have implemented view selection lists in many processing windows. As an example, consider the Resample window:

The view selection list, in this case, contains all of the image windows currently open. Here is an example of how the above view selection list looks like when pulled down:

In the case of the Resample window, when an image is selected from the view selection list, its dimensions are loaded in the window and used to simulate how things would go if we applied the resampling process to that particular image. For example, we can define a resampling operation in terms of relative resizing, say to the 80% of the original dimensions, and then check how it would perform for each open image, by simply selecting them in sequence.

Regarding view selection lists, please realize that:

  1. When you select an image or a preview from a view selection list on a processing window, it does not mean that the selected image or preview will be affected necessarily when you click any of the Apply or Preview buttons. Selected views in processing windows are used for simulation and/or sampling purposes exclusively.

  2. When an image or preview is selected on a processing window, changes made to that image or preview force an automatic update of all involved interface elements. For example, if you have a view selected on the Histograms window, and you change a pixel of that view, its histogram functions will be automatically recalculated and redrawn.


    ::Index  <Prev  >Next