Scanning for images

Add images to the database

Get A Mosaic is a command line program. So the first step is to open a command line window.
  • Press the windows button on your keyboard. And go to "Execute...". Then enter "cmd.exe"
  • Then enter "cd c:\program files\GetAMosaic"
Now your are in the folder where everything happens. The next step is to create a database where all the small images are stored. In this step all your images (in jpeg format) will be scanned and the thumbnails will be stored in the database.
In the database only the maximum square portion of the image is taken into account. And to save storage capacity the image is downscaled to NxN pixels. N can be configured with the command line option -p N

Enter: GetAMosaic.exe -s d:\images -p 512

Note here that a higher number will increase your database size. If you plan to use only pixel image sizes of 200 pixels then it makes no sense to enter 512 here.

Now all images are in the database. The database is called "characteristics.db". This is a sqlite database. If you like you can use "SQLITE"
to view and alter the data.

Only for advanced users: Remove images from the database

Note: Normally you just delete the file characteristics.db and rescan the images. So this steps are normally not needed. I put it here just in case you are interested in it.

Sometimes it happens that you want to remove data from the database to make it smaller. This is currently not possible with GetAMosaic but you can remove data with sqlite. To do so download sqlite and place sqlite3.exe in the same folder where your database file stayes. Then enter:

sqlite3.exe characteristics.db

Here are the most improtant SQL statements.

To view the content of the database enter:

SELECT id, fname FROM ch;

To filter for a portion of the path you can use:

SELECT id, fname FROM ch WHERE fname LIKE '%holliday2009%';

Next you want to delete the data. This can be done this way.

DELETE FROM blobdata WHERE chid IN (select id from ch WHERE fname LIKE '%holliday2009%');

DELETE FROM ch WHERE fname LIKE '%holliday2009%';

The size of the databasefile will decrease when you run a vacuum on the database:

VACUUM;