introduced savePNG(), a function for saving png files