Linux fixes

This commit is contained in:
Magne Sjaastad 2015-10-05 17:36:19 +02:00
parent 63d401b6e6
commit 05a71b79c9
2 changed files with 6 additions and 1 deletions

View File

@ -19,8 +19,12 @@
#include "RimWellLogExtractionCurveImpl.h" #include "RimWellLogExtractionCurveImpl.h"
#include "cvfBase.h"
#include "cvfMath.h"
#include "cvfAssert.h" #include "cvfAssert.h"
#include <cmath> // Needed for HUGE_VAL on Linux
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------
/// ///
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------
@ -99,7 +103,7 @@ void RimWellLogExtractionCurveImpl::validDepthValuesIntervals(const std::vector<
size_t intStartIdx = startIdx; size_t intStartIdx = startIdx;
for (size_t vIdx = startIdx + 1; vIdx < stopIdx; vIdx += 2) for (size_t vIdx = startIdx + 1; vIdx < stopIdx; vIdx += 2)
{ {
if (abs(depthValues[vIdx + 1] - depthValues[vIdx]) > depthDiffTolerance) if (cvf::Math::abs(depthValues[vIdx + 1] - depthValues[vIdx]) > depthDiffTolerance)
{ {
intervals.push_back(std::make_pair(intStartIdx, vIdx)); intervals.push_back(std::make_pair(intStartIdx, vIdx));
intStartIdx = vIdx + 1; intStartIdx = vIdx + 1;

View File

@ -20,6 +20,7 @@
#pragma once #pragma once
#include <vector> #include <vector>
#include <cstddef>
//================================================================================================== //==================================================================================================