add option for output directory

By default the thumbnail is created in the same folder as the original
file, a specific output directory can be set with - output-dir (path
can be a relative path or absolute path) , if the location does not
exist it will be created.