First time here? Check out the FAQ!
answered 2016-05-20 07:14:12 -0600
This isn't a real solution for the problem itself, but somewhere I found a way by using the C API.
cvSaveImage("image.png", &IplImage(mat) );
I don't get any errors and the images save fine in every supported format.