Fixed Problem regarding negative riTrans values

The reason was a bit sloppy detection of whether the surface normals was
pointing outwards or inwards in a cell.
The cells can be turned inside out due to depth/Z or mapaxis conditions.
This commit is contained in:
Jacob Støren
2014-09-23 12:24:48 +02:00
parent b58862ad93
commit 6e55ca82e2
8 changed files with 45 additions and 15 deletions

View File

@@ -220,7 +220,7 @@ cvf::Vec3d StructGridInterface::displayModelOffset() const
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void StructGridInterface::characteristicCellSizes(double* iSize, double* jSize, double* kSize)
void StructGridInterface::characteristicCellSizes(double* iSize, double* jSize, double* kSize) const
{
CVF_ASSERT(iSize && jSize && kSize);

View File

@@ -84,7 +84,7 @@ public:
virtual cvf::Vec3d minCoordinate() const = 0;
virtual cvf::Vec3d maxCoordinate() const = 0;
void characteristicCellSizes(double* iSize, double* jSize, double* kSize);
void characteristicCellSizes(double* iSize, double* jSize, double* kSize) const;
virtual cvf::Vec3d displayModelOffset() const;
@@ -109,9 +109,9 @@ public:
static void neighborIJKAtCellFace(size_t i, size_t j, size_t k, StructGridInterface::FaceType face, size_t* ni, size_t* nj, size_t* nk);
private:
double m_characteristicCellSizeI;
double m_characteristicCellSizeJ;
double m_characteristicCellSizeK;
mutable double m_characteristicCellSizeI;
mutable double m_characteristicCellSizeJ;
mutable double m_characteristicCellSizeK;
};
} // namespace cvf