Implementing SaveAsPng for Windows.
Implementing SaveAsPng for Windows