mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-30 17:10:19 -05:00
Refactor import of radial grid
* Add radial display mode to preferences * Adds isRadial to grid * Improve mesh lines for radial cells For temporary radial LGRs, show mesh outline based on the aggregated geometry of all LGRs of the parent cell clicked on. * Improve warning message * Modify cell selection in pick event handler
This commit is contained in:
1 parent
4421536349
commit
6b7d93e2da
25 files changed
+399
-241
No files matched your search
@@ -77,6 +77,22 @@ std::string RigGridBase::gridName() const
|
||||
return m_gridName;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RigGridBase::isRadial() const
|
||||
{
|
||||
return m_isRadial;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RigGridBase::setIsRadial( bool isRadial )
|
||||
{
|
||||
m_isRadial = isRadial;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -51,6 +51,9 @@ public:
|
||||
cvf::Vec3st cellCounts() const { return m_cellCounts; }
|
||||
virtual size_t cellCount() const { return m_cellCountIJK; }
|
||||
|
||||
bool isRadial() const;
|
||||
void setIsRadial( bool isRadial );
|
||||
|
||||
virtual RigCell& cell( size_t gridLocalCellIndex );
|
||||
virtual const RigCell& cell( size_t gridLocalCellIndex ) const;
|
||||
|
||||
@@ -128,6 +131,7 @@ private:
|
||||
int m_gridId; ///< The LGR id of this grid. Main grid has id 0.
|
||||
RigMainGrid* m_mainGrid;
|
||||
cvf::BoundingBox m_boundingBox;
|
||||
bool m_isRadial = false;
|
||||
|
||||
std::vector<std::array<size_t, 6>> m_coarseningBoxInfo;
|
||||
};
|
||||
|
||||
@@ -108,26 +108,6 @@ QString RigReservoirGridTools::gridName( RimCase* rimCase, int gridIndex )
|
||||
return "";
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RigReservoirGridTools::isRadialGrid( RimCase* rimCase )
|
||||
{
|
||||
RimEclipseResultCase* eclipseResultCase = dynamic_cast<RimEclipseResultCase*>( rimCase );
|
||||
if ( !eclipseResultCase ) return false;
|
||||
|
||||
auto eclipseCaseData = eclipseResultCase->eclipseCaseData();
|
||||
if ( !eclipseCaseData ) return false;
|
||||
|
||||
auto results = eclipseCaseData->results( RiaDefines::PorosityModelType::MATRIX_MODEL );
|
||||
if ( !results ) return false;
|
||||
|
||||
auto readerInterface = results->readerInterface();
|
||||
if ( !readerInterface ) return false;
|
||||
|
||||
return readerInterface->isRadialGrid();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -47,7 +47,6 @@ public:
|
||||
static const cvf::StructGridInterface* mainGrid( RimCase* rimCase );
|
||||
static const cvf::StructGridInterface* gridByIndex( RimCase* rimCase, int gridIndex );
|
||||
static QString gridName( RimCase* rimCase, int gridIndex );
|
||||
static bool isRadialGrid( RimCase* rimCase );
|
||||
|
||||
static const RigActiveCellInfo* activeCellInfo( Rim3dView* rimView );
|
||||
|
||||
|
||||
Reference in new issue
Block a user