(#498) Picking and displaying well log channel unit from LAS files

This commit is contained in:
Pål Hagen
2015-09-21 10:10:25 +02:00
parent 22d033669d
commit 5e8a6d90cd
7 changed files with 62 additions and 1 deletions

View File

@@ -172,3 +172,25 @@ QString RigWellLogFile::depthUnit() const
return unit;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
QString RigWellLogFile::wellLogChannelUnit(const QString& wellLogChannelName) const
{
QString unit;
NRLib::LasWell* lasWell = dynamic_cast<NRLib::LasWell*>(m_wellLogFile);
if (lasWell)
{
unit = QString::fromStdString(lasWell->unitName(wellLogChannelName.toStdString()));
}
// Special handling of depth unit - we convert depth to meter
if (unit == depthUnit())
{
return "m";
}
return unit;
}

View File

@@ -49,6 +49,7 @@ public:
std::vector<double> values(const QString& name) const;
QString depthUnit() const;
QString wellLogChannelUnit(const QString& wellLogChannelName) const;
private:
void close();