Commit 9f9d21bc authored by Lorenz Meier's avatar Lorenz Meier

Merge pull request #757 from Kynos/master

Remove isnan() and isinf() templates from QGC.h for Windows builds
parents 1f7e986d 9a8ca091
......@@ -137,8 +137,9 @@ Only compilation using Visual Studio 2010, 2012, and 2013 are supported.
* If installing VS2010, make sure to install Service Pack 1, which fixes a linking error: <http://www.microsoft.com/en-us/download/details.aspx?id=23691>.
2. Download and install the Qt 5.3 libraries for your version of Visual Studio from here: <http://download.qt-project.org/official_releases/qt/5.3/5.3.1>
* The Qt variant should be 32 bit (not 64) and include opengl. For Visual Studio 2013, this could be qt-opensource-windows-x86-msvc2013_opengl-5.3.1.exe for example.
3. **[OPTIONAL]** Go to the QGroundControl folder and then to thirdParty/libxbee and build it following the instructions in win32.README
3. **[OPTIONAL]** Go to the QGroundControl folder and then to libs/thirdParty/libxbee and build it following the instructions in win32.README.txt
4. Open the Qt Command Prompt program from the Start Menu, navigate to the source folder of QGroundControl, and create the Visual Studio project by typing `qmake -tp vc qgroundcontrol.pro`
......
......@@ -33,13 +33,14 @@
/* Windows fixes */
#ifdef _MSC_VER
#if (_MSC_VER < 1800) /* only PRIOR to Visual Studio 2013 */
/* Needed define for Eigen */
//#define NOMINMAX
#include <limits>
template<typename T>
inline bool isnan(T value)
{
return value != value;
return value != value;
}
......@@ -47,8 +48,9 @@ inline bool isnan(T value)
template<typename T>
inline bool isinf(T value)
{
return (value == std::numeric_limits<T>::infinity() || (-1*value) == std::numeric_limits<T>::infinity()) && std::numeric_limits<T>::has_infinity;
return (value == std::numeric_limits<T>::infinity() || (-1 * value) == std::numeric_limits<T>::infinity()) && std::numeric_limits<T>::has_infinity;
}
#endif
#elif defined __APPLE__
#include <cmath>
#ifndef isnan
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment