Added JPEG support