optimzed image size with lossless compression