Before starting
This software need a Java virtual machine installed on your computer.
The minimal version needed is 6.
In order to download a Java VM you can go here.
If you want to check the current version running on your system, simply open a console window and type:
java -version
If you get no answer then you have no Java, if the version is bellow 1.6 then you've an inappropriate version of Java for this software.
At last, starting
Keep in mind that this software is still in alpha, so a lot of code may change until first release.
Use mdt.Run class in order to start the project.
java -classpath MetaDataSpr.jar;commons-logging-1.1.1.jar;commons-math-2.0.jar;log4j-1.2.15.jar;org.springframework.asm-3.0.2.RELEASE.jar;org.springframework.beans-3.0.2.RELEASE.jar;org.springframework.context-3.0.2.RELEASE.jar;org.springframework.context.support-3.0.2.RELEASE.jar;org.springframework.core-3.0.2.RELEASE.jar;org.springframework.expression-3.0.2.RELEASE.jar mdt.Run -I:[InPutFileName] -O:[OutPutFileName] -M:[MODE] -GC -T:[X] -W
Jar files are separated by a ';' if you are under Windows, otherwise use ':' (if you are using a Unix like OS).
-I: for input file name. Mandatory, one value only. Can be a file or a directory but WITHOUT spaces.
-O: for ouput file name WITHOUT spaces. If present will put all result in it. If absent each file will create its own result file.
-T will activate multi-thread treatment. The X is the maximum number of thread allowed. Each image will be treated in one thread.
Result on memory usage and processor time consumption may differ, regarding your system and the size of the images you want to analyze.
Of course, this is only useful when you analyze more than one image.
There is no maximum value, as an example, on 600 images I win 10% of time (3 seconds) using -T:32.
-GC will optimize memory usage but will slow down execution.
-W will not start as batch, will launch the main window. If this option is set, only -I will be accepted as an other option.
Where MODE can be one of the following:
- XML: will return an XML file. Note that all values will be in CDDATA in order to avoid errors.
- TXT: will return a simple TXT file.
- HTML: will return an HTML file.
- EXIF: will return a simple TXT file as similar as possible to the ExifTool project.
For examples, using batch mode:
- Will create a file c:/toto.xml as result
java -classpath all jar -I:c:/toto.jpg -O:c:/toto.xml -M:XML
java -classpath all jar -I:c:/toto.jpg -M:XML
java -classpath all jar -I:c:/toto.jpg
- Will create a file c:/toto.txt as result
java -classpath all jar -I:c:/toto.jpg -O:c:/toto.txt -M:EXIF
java -classpath all jar -I:c:/toto.jpg -M:EXIF
java -classpath all jar -I:c:/toto.jpg -M:TXT
- Will create a file c:/toto.html as result
java -classpath all jar -I:c:/toto.jpg -O:c:/toto.html -M:HTML
- Will create a file c:/temp/xx.txt for each JPG in c:/temp as result
java -classpath all jar -I:c:/temp/ -M:EXIF
java -classpath all jar -I:c:/temp/ -M:TXT
- Will create a file c:/temp/xx.txt for each JPG in c:/temp as result, using 4 threads
java -classpath all jar -I:c:/temp/ -M:EXIF -T:4
For examples, using GUI mode:
- Will start GUI
javaw -classpath all jar -W
- Will start GUI and open file toto.jpg
javaw -classpath all jar -I:c:/toto.jpg -W
If you get an out of memory error you can do:
java -Xms128M -Xmx512M -classpath all jar -I:[IN] -O:[OUT] -M:[MODE] -GC -T:[X] -W
Caution to Upper/Lower cases in the Xms and Xmx options.
- Xms: minimum memory that can be used.
- Xmx: maximum memory that can be used (do not put more than 1500 here if you are a Windows user).