use new appveyor git tag feature for deployment
handle gamma correction
free memory correctly