This week the programming of the project is under-way. I received one of the end laptops that the project is aimed to be used on. To start I took the small test samples that I created for testing animations, image generation and sound and ran them separately on the device.
I found that the animations, images and music play okay - there are a few pauses at the beginning of the animation and the music as the programs load. I also tested the most intensive part of the program which is the alignment of the sequences. I found this to quite a major problem as the RAM is not large enough for processing the task. I increased the Java virtual machine heap space to a gigabyte and the problem was solved how ever it too a few minutes for the task to be completed.
I started work on the GUI of the program. This I chose as the starting point for the program as I could test how the system would handles a GUI and processing the sequences. With the result looking like this.
I found that the animations, images and music play okay - there are a few pauses at the beginning of the animation and the music as the programs load. I also tested the most intensive part of the program which is the alignment of the sequences. I found this to quite a major problem as the RAM is not large enough for processing the task. I increased the Java virtual machine heap space to a gigabyte and the problem was solved how ever it too a few minutes for the task to be completed.
I started work on the GUI of the program. This I chose as the starting point for the program as I could test how the system would handles a GUI and processing the sequences. With the result looking like this.
I added buttons to allow me open the Java file chooser and select one sequence and then the other to select the second. Here I encountered my second problem related to the alignment. Since it was taking a few minutes to align the sequences, good HCI would dictate giving the user a sign that the program is busy, so I tried different methods to notify the user.
At first I used a dialog box running in the background but found that it paused the whole program. I tested this using both swing worker and multi-threading techniques. Eventually I decided to change the start button to tell the user that the program will align and change the mouse icon to display the computers default loading icon, and when the task is complete change the start button back.
At first I used a dialog box running in the background but found that it paused the whole program. I tested this using both swing worker and multi-threading techniques. Eventually I decided to change the start button to tell the user that the program will align and change the mouse icon to display the computers default loading icon, and when the task is complete change the start button back.
After which I decided to implement the most complex display method the animation. I hard coded the Animation to play the first sequence and to start after the sequences had aligned and found that it worked well. I later added the second image and ran it off of the second sequence which started to cause flashing and de-align the two sequences. I later ran each in a separate thread and this seemed to solve the problem.