trim 24 bytes to make it a JPG