mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#10367 Janitor: Remove unneccessary 'this' pointers
This commit is contained in:
@@ -232,7 +232,7 @@ void RigFemPart::assertNodeToElmIndicesIsCalculated()
|
||||
{
|
||||
if ( m_nodeToElmRefs.size() != nodes().nodeIds.size() )
|
||||
{
|
||||
this->calculateNodeToElmRefs();
|
||||
calculateNodeToElmRefs();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -279,7 +279,7 @@ void RigFemPart::assertElmNeighborsIsCalculated()
|
||||
{
|
||||
if ( m_elmNeighbors.size() != m_elementId.size() )
|
||||
{
|
||||
this->calculateElmNeighbors();
|
||||
calculateElmNeighbors();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -295,12 +295,12 @@ void RigFemPart::calculateElmNeighbors()
|
||||
// parallelization
|
||||
std::vector<int> candidates; //
|
||||
|
||||
m_elmNeighbors.resize( this->elementCount() );
|
||||
m_elmNeighbors.resize( elementCount() );
|
||||
|
||||
for ( int eIdx = 0; eIdx < this->elementCount(); ++eIdx )
|
||||
for ( int eIdx = 0; eIdx < elementCount(); ++eIdx )
|
||||
{
|
||||
RigElementType elmType = this->elementType( eIdx );
|
||||
const int* elmNodes = this->connectivities( eIdx );
|
||||
RigElementType elmType = elementType( eIdx );
|
||||
const int* elmNodes = connectivities( eIdx );
|
||||
|
||||
int faceCount = RigFemTypes::elementFaceCount( elmType );
|
||||
int neighborCount = 0;
|
||||
@@ -315,7 +315,7 @@ void RigFemPart::calculateElmNeighbors()
|
||||
candidates.clear();
|
||||
{
|
||||
int firstNodeIdxOfFace = elmNodes[localFaceIndices[0]];
|
||||
const std::vector<int>& candidates1 = this->elementsUsingNode( firstNodeIdxOfFace );
|
||||
const std::vector<int>& candidates1 = elementsUsingNode( firstNodeIdxOfFace );
|
||||
|
||||
if ( !candidates1.empty() )
|
||||
{
|
||||
@@ -323,7 +323,7 @@ void RigFemPart::calculateElmNeighbors()
|
||||
|
||||
int thirdNodeIdxOfFace = elmNodes[localFaceIndices[3]];
|
||||
|
||||
const std::vector<int>& candidates2 = this->elementsUsingNode( thirdNodeIdxOfFace );
|
||||
const std::vector<int>& candidates2 = elementsUsingNode( thirdNodeIdxOfFace );
|
||||
|
||||
// The candidates are sorted from smallest to largest, so we do a linear search to find the
|
||||
// (two) common cells in the two arrays, and leaving this element out, we have one candidate left
|
||||
@@ -366,8 +366,8 @@ void RigFemPart::calculateElmNeighbors()
|
||||
{
|
||||
int nbcElmIdx = candidates[nbcIdx];
|
||||
|
||||
RigElementType nbcElmType = this->elementType( nbcElmIdx );
|
||||
const int* nbcElmNodes = this->connectivities( nbcElmIdx );
|
||||
RigElementType nbcElmType = elementType( nbcElmIdx );
|
||||
const int* nbcElmNodes = connectivities( nbcElmIdx );
|
||||
|
||||
int nbcFaceCount = RigFemTypes::elementFaceCount( nbcElmType );
|
||||
bool isNeighborFound = false;
|
||||
@@ -407,10 +407,10 @@ void RigFemPart::calculateElmNeighbors()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
cvf::Vec3f RigFemPart::faceNormal( int elmIdx, int faceIdx ) const
|
||||
{
|
||||
const std::vector<cvf::Vec3f>& nodeCoordinates = this->nodes().coordinates;
|
||||
const std::vector<cvf::Vec3f>& nodeCoordinates = nodes().coordinates;
|
||||
|
||||
RigElementType eType = this->elementType( elmIdx );
|
||||
const int* elmNodeIndices = this->connectivities( elmIdx );
|
||||
RigElementType eType = elementType( elmIdx );
|
||||
const int* elmNodeIndices = connectivities( elmIdx );
|
||||
|
||||
int faceNodeCount = 0;
|
||||
const int* localElmNodeIndicesForFace = RigFemTypes::localElmNodeIndicesForFace( eType, faceIdx, &faceNodeCount );
|
||||
@@ -450,15 +450,15 @@ float RigFemPart::characteristicElementSize() const
|
||||
float sumMaxEdgeLength = 0;
|
||||
for ( int elmIdx = 0; elmIdx < elementCount(); elmIdx++ )
|
||||
{
|
||||
RigElementType eType = this->elementType( elmIdx );
|
||||
RigElementType eType = elementType( elmIdx );
|
||||
|
||||
if ( eType == elmType )
|
||||
{
|
||||
const int* elementConn = this->connectivities( elmIdx );
|
||||
cvf::Vec3f nodePos0 = this->nodes().coordinates[elementConn[0]];
|
||||
cvf::Vec3f nodePos1 = this->nodes().coordinates[elementConn[1]];
|
||||
cvf::Vec3f nodePos3 = this->nodes().coordinates[elementConn[3]];
|
||||
cvf::Vec3f nodePos4 = this->nodes().coordinates[elementConn[4]];
|
||||
const int* elementConn = connectivities( elmIdx );
|
||||
cvf::Vec3f nodePos0 = nodes().coordinates[elementConn[0]];
|
||||
cvf::Vec3f nodePos1 = nodes().coordinates[elementConn[1]];
|
||||
cvf::Vec3f nodePos3 = nodes().coordinates[elementConn[3]];
|
||||
cvf::Vec3f nodePos4 = nodes().coordinates[elementConn[4]];
|
||||
|
||||
float l1 = ( nodePos1 - nodePos0 ).length();
|
||||
float l3 = ( nodePos3 - nodePos0 ).length();
|
||||
@@ -560,11 +560,11 @@ void RigFemPart::ensureIntersectionSearchTreeIsBuilt() const
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
size_t RigFemPart::elementNodeResultCount() const
|
||||
{
|
||||
int lastElmIdx = this->elementCount() - 1;
|
||||
int lastElmIdx = elementCount() - 1;
|
||||
if ( lastElmIdx < 0 ) return 0;
|
||||
RigElementType elmType = this->elementType( lastElmIdx );
|
||||
RigElementType elmType = elementType( lastElmIdx );
|
||||
int elmNodeCount = RigFemTypes::elementNodeCount( elmType );
|
||||
size_t lastElmResultIdx = this->elementNodeResultIdx( lastElmIdx, elmNodeCount - 1 );
|
||||
size_t lastElmResultIdx = elementNodeResultIdx( lastElmIdx, elmNodeCount - 1 );
|
||||
|
||||
return lastElmResultIdx + 1;
|
||||
}
|
||||
|
@@ -481,7 +481,7 @@ void RigFemPartGrid::cellCornerVertices( size_t cellIndex, cvf::Vec3d vertices[8
|
||||
cvf::Vec3d RigFemPartGrid::cellCentroid( size_t cellIndex ) const
|
||||
{
|
||||
std::array<cvf::Vec3d, 8> cellVertices;
|
||||
this->cellCornerVertices( cellIndex, cellVertices.data() );
|
||||
cellCornerVertices( cellIndex, cellVertices.data() );
|
||||
|
||||
cvf::Vec3d centroid( 0.0, 0.0, 0.0 );
|
||||
for ( int i = 0; i < 8; ++i )
|
||||
|
@@ -215,7 +215,7 @@ void RigFemPartResultsCollection::setActiveFormationNames( RigFormationNames* ac
|
||||
{
|
||||
m_activeFormationNamesData = activeFormationNames;
|
||||
|
||||
this->deleteResult( RigFemResultAddress( RIG_FORMATION_NAMES, "Active Formation Names", "" ) );
|
||||
deleteResult( RigFemResultAddress( RIG_FORMATION_NAMES, "Active Formation Names", "" ) );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -260,7 +260,7 @@ void RigFemPartResultsCollection::addElementPropertyFiles( const std::vector<QSt
|
||||
// Invalidate previous result if already in cache
|
||||
for ( const RigFemResultAddress& address : newAddresses )
|
||||
{
|
||||
this->deleteResult( address );
|
||||
deleteResult( address );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -285,7 +285,7 @@ std::vector<RigFemResultAddress> RigFemPartResultsCollection::removeElementPrope
|
||||
|
||||
for ( const RigFemResultAddress& address : addressesToRemove )
|
||||
{
|
||||
this->deleteResult( address );
|
||||
deleteResult( address );
|
||||
}
|
||||
|
||||
return addressesToRemove;
|
||||
@@ -459,7 +459,7 @@ RigFemScalarResultFrames* RigFemPartResultsCollection::findOrLoadScalarResult( i
|
||||
|
||||
// We need to read the data as bulk fields, and populate the correct scalar caches
|
||||
|
||||
std::vector<RigFemResultAddress> resultAddressOfComponents = this->getResAddrToComponentsToRead( resVarAddr );
|
||||
std::vector<RigFemResultAddress> resultAddressOfComponents = getResAddrToComponentsToRead( resVarAddr );
|
||||
|
||||
if ( !resultAddressOfComponents.empty() )
|
||||
{
|
||||
@@ -469,7 +469,7 @@ RigFemScalarResultFrames* RigFemPartResultsCollection::findOrLoadScalarResult( i
|
||||
resultsForEachComponent.push_back( m_femPartResults[partIndex]->createScalarResult( resultAddressOfComponent ) );
|
||||
}
|
||||
|
||||
int timeSteps = this->timeStepCount();
|
||||
int timeSteps = timeStepCount();
|
||||
caf::ProgressInfo progress( timeSteps, "" );
|
||||
progress.setProgressDescription(
|
||||
QString( "Loading Native Result %1 %2" ).arg( resVarAddr.fieldName.c_str(), resVarAddr.componentName.c_str() ) );
|
||||
@@ -1183,7 +1183,7 @@ void RigFemPartResultsCollection::minMaxScalarValues( const RigFemResultAddress&
|
||||
double* localMin,
|
||||
double* localMax )
|
||||
{
|
||||
this->statistics( resVarAddr )->minMaxCellScalarValues( stepIndex, *localMin, *localMax );
|
||||
statistics( resVarAddr )->minMaxCellScalarValues( stepIndex, *localMin, *localMax );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1191,7 +1191,7 @@ void RigFemPartResultsCollection::minMaxScalarValues( const RigFemResultAddress&
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RigFemPartResultsCollection::minMaxScalarValues( const RigFemResultAddress& resVarAddr, double* globalMin, double* globalMax )
|
||||
{
|
||||
this->statistics( resVarAddr )->minMaxCellScalarValues( *globalMin, *globalMax );
|
||||
statistics( resVarAddr )->minMaxCellScalarValues( *globalMin, *globalMax );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1203,7 +1203,7 @@ void RigFemPartResultsCollection::posNegClosestToZero( const RigFemResultAddress
|
||||
double* localPosClosestToZero,
|
||||
double* localNegClosestToZero )
|
||||
{
|
||||
this->statistics( resVarAddr )->posNegClosestToZero( stepIndex, *localPosClosestToZero, *localNegClosestToZero );
|
||||
statistics( resVarAddr )->posNegClosestToZero( stepIndex, *localPosClosestToZero, *localNegClosestToZero );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1213,7 +1213,7 @@ void RigFemPartResultsCollection::posNegClosestToZero( const RigFemResultAddress
|
||||
double* globalPosClosestToZero,
|
||||
double* globalNegClosestToZero )
|
||||
{
|
||||
this->statistics( resVarAddr )->posNegClosestToZero( *globalPosClosestToZero, *globalNegClosestToZero );
|
||||
statistics( resVarAddr )->posNegClosestToZero( *globalPosClosestToZero, *globalNegClosestToZero );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1223,7 +1223,7 @@ void RigFemPartResultsCollection::meanScalarValue( const RigFemResultAddress& re
|
||||
{
|
||||
CVF_ASSERT( meanValue );
|
||||
|
||||
this->statistics( resVarAddr )->meanCellScalarValues( *meanValue );
|
||||
statistics( resVarAddr )->meanCellScalarValues( *meanValue );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1231,7 +1231,7 @@ void RigFemPartResultsCollection::meanScalarValue( const RigFemResultAddress& re
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RigFemPartResultsCollection::meanScalarValue( const RigFemResultAddress& resVarAddr, int stepIndex, int frameIndex, double* meanValue )
|
||||
{
|
||||
this->statistics( resVarAddr )->meanCellScalarValues( stepIndex, *meanValue );
|
||||
statistics( resVarAddr )->meanCellScalarValues( stepIndex, *meanValue );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1239,7 +1239,7 @@ void RigFemPartResultsCollection::meanScalarValue( const RigFemResultAddress& re
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RigFemPartResultsCollection::p10p90ScalarValues( const RigFemResultAddress& resVarAddr, double* p10, double* p90 )
|
||||
{
|
||||
this->statistics( resVarAddr )->p10p90CellScalarValues( *p10, *p90 );
|
||||
statistics( resVarAddr )->p10p90CellScalarValues( *p10, *p90 );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1247,7 +1247,7 @@ void RigFemPartResultsCollection::p10p90ScalarValues( const RigFemResultAddress&
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RigFemPartResultsCollection::p10p90ScalarValues( const RigFemResultAddress& resVarAddr, int stepIndex, int frameIndex, double* p10, double* p90 )
|
||||
{
|
||||
this->statistics( resVarAddr )->p10p90CellScalarValues( stepIndex, *p10, *p90 );
|
||||
statistics( resVarAddr )->p10p90CellScalarValues( stepIndex, *p10, *p90 );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1257,7 +1257,7 @@ void RigFemPartResultsCollection::sumScalarValue( const RigFemResultAddress& res
|
||||
{
|
||||
CVF_ASSERT( sum );
|
||||
|
||||
this->statistics( resVarAddr )->sumCellScalarValues( *sum );
|
||||
statistics( resVarAddr )->sumCellScalarValues( *sum );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1267,7 +1267,7 @@ void RigFemPartResultsCollection::sumScalarValue( const RigFemResultAddress& res
|
||||
{
|
||||
CVF_ASSERT( sum );
|
||||
|
||||
this->statistics( resVarAddr )->sumCellScalarValues( stepIndex, *sum );
|
||||
statistics( resVarAddr )->sumCellScalarValues( stepIndex, *sum );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1275,7 +1275,7 @@ void RigFemPartResultsCollection::sumScalarValue( const RigFemResultAddress& res
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
const std::vector<size_t>& RigFemPartResultsCollection::scalarValuesHistogram( const RigFemResultAddress& resVarAddr )
|
||||
{
|
||||
return this->statistics( resVarAddr )->cellScalarValuesHistogram();
|
||||
return statistics( resVarAddr )->cellScalarValuesHistogram();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1284,7 +1284,7 @@ const std::vector<size_t>& RigFemPartResultsCollection::scalarValuesHistogram( c
|
||||
const std::vector<size_t>&
|
||||
RigFemPartResultsCollection::scalarValuesHistogram( const RigFemResultAddress& resVarAddr, int stepIndex, int frameIndex )
|
||||
{
|
||||
return this->statistics( resVarAddr )->cellScalarValuesHistogram( stepIndex );
|
||||
return statistics( resVarAddr )->cellScalarValuesHistogram( stepIndex );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1434,7 +1434,7 @@ void RigFemPartResultsCollection::setNormalizationAirGap( double normalizationAi
|
||||
{
|
||||
for ( auto result : normalizedResults() )
|
||||
{
|
||||
this->deleteResult( result );
|
||||
deleteResult( result );
|
||||
}
|
||||
}
|
||||
m_normalizationAirGap = normalizationAirGap;
|
||||
@@ -1464,7 +1464,7 @@ void RigFemPartResultsCollection::minMaxScalarValuesOverAllTensorComponents( con
|
||||
|
||||
for ( const auto& address : tensorPrincipalComponentAdresses( resVarAddr ) )
|
||||
{
|
||||
this->statistics( address )->minMaxCellScalarValues( stepIndex, min, max );
|
||||
statistics( address )->minMaxCellScalarValues( stepIndex, min, max );
|
||||
if ( min < currentMin )
|
||||
{
|
||||
currentMin = min;
|
||||
@@ -1493,7 +1493,7 @@ void RigFemPartResultsCollection::minMaxScalarValuesOverAllTensorComponents( con
|
||||
|
||||
for ( const auto& address : tensorPrincipalComponentAdresses( resVarAddr ) )
|
||||
{
|
||||
this->statistics( address )->minMaxCellScalarValues( min, max );
|
||||
statistics( address )->minMaxCellScalarValues( min, max );
|
||||
if ( min < currentMin )
|
||||
{
|
||||
currentMin = min;
|
||||
@@ -1524,7 +1524,7 @@ void RigFemPartResultsCollection::posNegClosestToZeroOverAllTensorComponents( co
|
||||
|
||||
for ( const auto& address : tensorPrincipalComponentAdresses( resVarAddr ) )
|
||||
{
|
||||
this->statistics( address )->posNegClosestToZero( stepIndex, pos, neg );
|
||||
statistics( address )->posNegClosestToZero( stepIndex, pos, neg );
|
||||
if ( pos < currentPosClosestToZero )
|
||||
{
|
||||
currentPosClosestToZero = pos;
|
||||
@@ -1553,7 +1553,7 @@ void RigFemPartResultsCollection::posNegClosestToZeroOverAllTensorComponents( co
|
||||
|
||||
for ( const auto& address : tensorPrincipalComponentAdresses( resVarAddr ) )
|
||||
{
|
||||
this->statistics( address )->posNegClosestToZero( pos, neg );
|
||||
statistics( address )->posNegClosestToZero( pos, neg );
|
||||
if ( pos < currentPosClosestToZero )
|
||||
{
|
||||
currentPosClosestToZero = pos;
|
||||
@@ -1700,7 +1700,7 @@ void RigFemPartResultsCollection::setCalculationParameters( RimMudWeightWindowPa
|
||||
// Invalidate dependent results
|
||||
for ( auto result : mudWeightWindowResults() )
|
||||
{
|
||||
this->deleteResult( result );
|
||||
deleteResult( result );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1824,7 +1824,7 @@ void RigFemPartResultsCollection::setMudWeightWindowParameters( double
|
||||
// Invalidate dependent results
|
||||
for ( auto result : mudWeightWindowResults() )
|
||||
{
|
||||
this->deleteResult( result );
|
||||
deleteResult( result );
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -63,7 +63,7 @@ RivGeoMechVizLogic::~RivGeoMechVizLogic()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivGeoMechVizLogic::appendNoAnimPartsToModel( cvf::ModelBasicList* model )
|
||||
{
|
||||
this->appendPartsToModel( -1, model );
|
||||
appendPartsToModel( -1, model );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -112,7 +112,7 @@ void RivGeoMechVizLogic::updateStaticCellColors( int viewerStepIndex )
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivGeoMechVizLogic::scheduleGeometryRegen( RivCellSetEnum geometryType )
|
||||
{
|
||||
this->scheduleRegenOfDirectlyDependentGeometry( geometryType );
|
||||
scheduleRegenOfDirectlyDependentGeometry( geometryType );
|
||||
|
||||
bool resultsOk = ( m_geomechView->geoMechCase() && m_geomechView->geoMechCase()->geoMechData() &&
|
||||
m_geomechView->geoMechCase()->geoMechData()->femPartResults() );
|
||||
@@ -149,7 +149,7 @@ void RivGeoMechVizLogic::scheduleRegenOfDirectlyDependentGeometry( RivCellSetEnu
|
||||
{
|
||||
if ( geometryType == RANGE_FILTERED )
|
||||
{
|
||||
this->scheduleGeometryRegen( PROPERTY_FILTERED );
|
||||
scheduleGeometryRegen( PROPERTY_FILTERED );
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -448,7 +448,7 @@ std::vector<std::string> RifOdbReader::filteredStepNames() const
|
||||
for ( sIter.first(); !sIter.isDone(); sIter.next() )
|
||||
{
|
||||
std::string stepName( sIter.currentValue().name().CStr() );
|
||||
if ( this->isTimeStepIncludedByFilter( stepIndex++ ) )
|
||||
if ( isTimeStepIncludedByFilter( stepIndex++ ) )
|
||||
{
|
||||
stepNames.push_back( stepName );
|
||||
}
|
||||
@@ -468,7 +468,7 @@ std::vector<double> RifOdbReader::frameTimes( int stepIndex ) const
|
||||
|
||||
odb_StepList stepList = stepRepository.stepList();
|
||||
|
||||
int stepFileIndex = this->timeStepIndexOnFile( stepIndex );
|
||||
int stepFileIndex = timeStepIndexOnFile( stepIndex );
|
||||
|
||||
odb_Step& step = stepList.Get( stepFileIndex );
|
||||
|
||||
@@ -607,8 +607,8 @@ const odb_Frame& RifOdbReader::stepFrame( int stepIndex, int frameIndex ) const
|
||||
const odb_StepRepository& stepRepository = m_odb->steps();
|
||||
const odb_StepList& stepList = stepRepository.stepList();
|
||||
|
||||
int stepFileIndex = this->timeStepIndexOnFile( stepIndex );
|
||||
int fileFrameIndex = this->frameIndexOnFile( frameIndex );
|
||||
int stepFileIndex = timeStepIndexOnFile( stepIndex );
|
||||
int fileFrameIndex = frameIndexOnFile( frameIndex );
|
||||
|
||||
const odb_Step& step = stepList.ConstGet( stepFileIndex );
|
||||
const odb_SequenceFrame& stepFrames = step.frames();
|
||||
|
Reference in New Issue
Block a user