Image slideshow - Mini project
Course: IS1200 - Computer Hardware Engineering, link
The project was developed on a DE10-Lite Development and Education Board, that has a RISC-V processor.
Me and my lab partner developed an image slideshow that outputs images (320×240 pixels) through VGA. The user is able to to use a settings menu to interact with the program. It is controlled by the toggle switches and the current setting is displayed on the 7-segment displays and printed in the terminal.
The main requirements
- The slideshow supports multiple different images.
- Adjustable image change speed.
- Displaying the current change interval on the 7-segment display.
- Blur images.
- Using interrupts for timer, button and switches.
- Play/pause function.
- Smooth transition between images. Vertical/horizontal scroll effect.
The settings included:
The images are stored in the SDRAM sequentially and each pixel is one byte (3 bits for green, 3 bits for red and 2 bits for blue). The original image is stored first and the blurred version is stored at the memory address directly after. Since each image is 320×240 pixels each image need 320×240 bytes, so the offset between two different non-blur images is 2·320×240 bytes.
- 00 | Play & pause
- 01 | Hold duration, before next image
- 10 | Blur, on/off
- 11 | Scroll direction
The images are stored in the SDRAM sequentially and each pixel is one byte (3 bits for green, 3 bits for red and 2 bits for blue). The original image is stored first and the blurred version is stored at the memory address directly after. Since each image is 320×240 pixels each image need 320×240 bytes, so the offset between two different non-blur images is 2·320×240 bytes.
Blur effect
Blur is implemented by creating blurred versions of the images at the start of program. Depending on the blur radius, the processing takes some time. That's why they were initialized at the beginning and not processed every time the user wants to use blur.
The blur algorithm works by iterating through all pixels and calculating the average color within the given radius. A higher radius results in a stronger blur but takes longer to process.
Blur is implemented by creating blurred versions of the images at the start of program. Depending on the blur radius, the processing takes some time. That's why they were initialized at the beginning and not processed every time the user wants to use blur.
The blur algorithm works by iterating through all pixels and calculating the average color within the given radius. A higher radius results in a stronger blur but takes longer to process.
Note: The school projects described in this portfolio will not be described in detail to comply with KTH's guidelines against plagiarism.