Bchau branch

Maybe look at the `inImage.format` to determine what file extension to use for the file?