Pretty print JSON output.
cleanup.
mediaCwd option added. Allows relative path to be output in JSON if different from mediaOut path.