fix headers and missing functions for MSVC/MinGW
Merge pull request #19 from alex85k/windows-includes

fix headers and missing functions for MSVC/MinGW