Added ability to specificy out directory, to