diff --git a/ApplicationLibCode/ReservoirDataModel/RigLasFileExporter.cpp b/ApplicationLibCode/ReservoirDataModel/RigLasFileExporter.cpp index 6348ac9980..64f33db843 100644 --- a/ApplicationLibCode/ReservoirDataModel/RigLasFileExporter.cpp +++ b/ApplicationLibCode/ReservoirDataModel/RigLasFileExporter.cpp @@ -188,25 +188,21 @@ public: if ( !firstCurveData.depths( RiaDefines::DepthType::TRUE_VERTICAL_DEPTH ).empty() ) { + std::string tvdUnit; + std::string tvdComment = "True vertical depth"; if ( firstCurveData.depthUnit() == RiaDefines::DepthUnitType::UNIT_METER ) { - lasFile->AddLog( "TVDMSL", - "M", - "True vertical depth in meters", - firstCurveData.depths( RiaDefines::DepthType::TRUE_VERTICAL_DEPTH ) ); + tvdUnit = "M"; + tvdComment += " in meters"; } else if ( firstCurveData.depthUnit() == RiaDefines::DepthUnitType::UNIT_FEET ) { - lasFile->AddLog( "TVDMSL", - "FT", - "True vertical depth in feet", - firstCurveData.depths( RiaDefines::DepthType::TRUE_VERTICAL_DEPTH ) ); - } - else if ( firstCurveData.depthUnit() == RiaDefines::DepthUnitType::UNIT_NONE ) - { - lasFile->AddLog( "TVDMSL", "", "True vertical depth", firstCurveData.depths( RiaDefines::DepthType::TRUE_VERTICAL_DEPTH ) ); + tvdUnit = "FT"; + tvdComment += " in feet"; } + lasFile->AddLog( "TVDMSL", tvdUnit, tvdComment, firstCurveData.depths( RiaDefines::DepthType::TRUE_VERTICAL_DEPTH ) ); + if ( m_exportTvdrkb && m_rkbDiff != -1.0 ) { // Export True Vertical Depth Rotary Kelly Bushing - TVDRKB