Main window: split into two halves of the same size (both halves should have the same size after resizing the window as well)
Status bar
Over the status bar: a panel containing three track bars and a corresponding text label (which provides the values selected on the track bars), and a progress bar, with a corresponding label as well
Functionality and features:
In each of the halves there is a scrollable panel containing a picture box
After an image file is opened (use a common dialog for opening the files), it appears in both halves. Later, the left half will contain the original image, while the right will contain its quantized version
When one of the panels is being scrolled, the other panel scrolls automatically in the similar way (see hints)
The status bar contains a description of the opened file: size (X x Y), total number of pixels, file name and path
Bitmap quantisation:
The quantisation is obtained in the following way: for the n-th level of quantisation of one of the colours, we take the value of the colour, and change its n least significant bits to: 0 on (n-1)th position, and 1 on all remaining positions
Example: The RGB values of the original colour of some pixel are: 01101010, 10010010, 11100001. If we switch the quantisation levels to: 3 for R, 2 for G and 5 for B, the quanitsation result will be the following: 01101011, 10010001, 11101111
There can be 4 levels of quantisation instead of 8 for each of the colours (red, green and blue), to make the evaluation shorter and less memory consuming; in this case the quantisation levels change with 2-bit steps
The quantisation starts as soon as the file is opened
All of the quantised bitmaps (there should be a separate bitmap for every distinct selection of quantisation levels for each of the RGB colours) should be evaluated in the separate thread(s). The evaluations of each quantised bitmaps are running one after another.
The level of quantisation is selected by the track bars (one track bar for each RGB colour). If there is already a bitmap for selected level, it appears in the right half of the window immediately after the track bars are scrolled; if not, the information saying that its not yet evaluated should appear there; the (0,0,0) level of quantisation is the same as the original bitmap so we assume that we have it already at the start and can show it in the right half of the window at start, when a new file is opened
During the evaluation of each of the levels, the progress bar shows its progress, and the label corresponding to it shows the percent progress with the information saying which of the levels is being evaluated at the moment
Further requirements
Use ErrorProvider for notificaton of non-image file
Keys: Scrolling the bitmap panels and the track bars should be also accesible by keyboard: arrow or NumPad keys for panels, and R, G, B (with Ctrl in case of scrolling down) for scrolling the track bars.
Technical requirements:
Catch all exceptions
Make sure the quantisation evaluation thread is not running when the program ends
Hints:
ProgressBar, TrackBar, OpenFileDialog controls
ScrollableControl.AutoScrollPosition method (MSDN link, take notice at the 'Note')