The image of the bookshelf that has to be displayed on the Kindle has to be composed of different spine images of books rather than the front covers. Spine images are really hard to get, so I had to take photographs of spines of books that I wanted on the image, scan some books and download some already scanned images from the internet.
For composing the basic image on the display I used ImageMagick commands in shell scripts running on the server. Spine images of books were collected by photographs and other online resources. The images were first appended to each other. This step assumes that all the spines are off comparable dimensions. So it just puts together all the spine images into a single image. The resolution of the Kindle Paperwhite is 1024X768 and it can display only Grayscale images. So the resolution of the composed image is modified accordingly using the resize command to fit the screen. For the Grayscale conversion, the convert command is used. So, now the composed imaged is altered to display on a single paperwhite 2.
After the image is composed, the script on the kindle just pulls it up and displays it. When a new book has to be added, the spine image of the book is first loaded on the server and then the script is executed again to include this new image in composing the bigger picture. The new spine images are stored in a particular name format so all the names associated with a particular naming vocabulary is extracted to compose the picture.
This is the basic version of image composition and does not take into picture the size, height and width of books. These are considered as the project advances.
No comments:
Post a Comment