Please review changes to image file exporter

Here is a short description on major changes: 

1) Added routines export_png() and export_jpg() in the image renderer
2) The routine detect() now returns the file type (extension) if found instead of a bool, if found. I need to know filetype 
in