How do you handle errors when using Gdiplus::Image::FromFile()? I purposely had it try to read a file that didn’t exist.
It didn’t throw any exception, or return NULL.
I could check if the file exists before hand, but what if the file is not a valid image file, or something else goes wrong.
In examples to GDI+: http://msdn.microsoft.com/en-us/library/windows/desktop/ms535371%28v=vs.85%29.aspx so, you should verify that Image::GetLastStatus() == OK http://msdn.microsoft.com/en-us/library/windows/desktop/ms535383%28v=vs.85%29.aspx