Envi classification

Hi Thomas.  This patch allows ENVI class maps to be saved.  I split some code in save_image() into another function because it was getting kinda long after my additions.