Added missing header file for std::min.
Also organized projects when using Visual Studio.