#1292 Fixed CppCheck Issues in ModelVisualization

This commit is contained in:
Jacob Støren committed 2017-03-06 11:20:28 +01:00
1 parent c7c01e346c
commit b5e782dfc3
19 files changed
+17 -22

No files matched your search

@@ -71,7 +71,7 @@ private:
class RivFemIntersectionGrid : public RivIntersectionHexGridInterface
{
public:
RivFemIntersectionGrid(const RigFemPart * femPart);
explicit RivFemIntersectionGrid(const RigFemPart * femPart);
virtual cvf::Vec3d displayOffset() const;
virtual cvf::BoundingBox boundingBox() const;
@@ -349,8 +349,7 @@ cvf::ref<RivIntersectionHexGridInterface> RivIntersectionBoxPartMgr::createHexGr
m_rimIntersectionBox->firstAncestorOrThisOfType(eclipseView);
if (eclipseView)
{
RigMainGrid* grid = NULL;
grid = eclipseView->mainGrid();
RigMainGrid* grid = eclipseView->mainGrid();
return new RivEclipseIntersectionGrid(grid, eclipseView->currentActiveCellInfo(), m_rimIntersectionBox->showInactiveCells());
}
@@ -45,7 +45,7 @@ class RimIntersectionBox;
class RivIntersectionBoxPartMgr : public cvf::Object
{
public:
RivIntersectionBoxPartMgr(const RimIntersectionBox* intersectionBox);
explicit RivIntersectionBoxPartMgr(const RimIntersectionBox* intersectionBox);
void applySingleColorEffect();
void updateCellResultColor(size_t timeStepIndex);
@@ -29,7 +29,7 @@ class RimIntersectionBox;
class RivIntersectionBoxSourceInfo : public cvf::Object
{
public:
RivIntersectionBoxSourceInfo(RivIntersectionBoxGeometryGenerator* geometryGenerator);
explicit RivIntersectionBoxSourceInfo(RivIntersectionBoxGeometryGenerator* geometryGenerator);
const std::vector<size_t>& triangleToCellIndex() const;
@@ -737,8 +737,7 @@ cvf::ref<RivIntersectionHexGridInterface> RivIntersectionPartMgr::createHexGridI
m_rimCrossSection->firstAncestorOrThisOfType(eclipseView);
if (eclipseView)
{
RigMainGrid* grid = NULL;
grid = eclipseView->mainGrid();
RigMainGrid* grid = eclipseView->mainGrid();
return new RivEclipseIntersectionGrid(grid, eclipseView->currentActiveCellInfo(), m_rimCrossSection->showInactiveCells());
}
@@ -55,7 +55,7 @@ class RivIntersectionVertexWeights;
class RivIntersectionPartMgr : public cvf::Object
{
public:
RivIntersectionPartMgr(const RimIntersection* rimCrossSection);
explicit RivIntersectionPartMgr(const RimIntersection* rimCrossSection);
void applySingleColorEffect();
void updateCellResultColor(size_t timeStepIndex);
@@ -30,7 +30,7 @@ class RimIntersection;
class RivIntersectionSourceInfo : public cvf::Object
{
public:
RivIntersectionSourceInfo(RivIntersectionGeometryGenerator* geometryGenerator);
explicit RivIntersectionSourceInfo(RivIntersectionGeometryGenerator* geometryGenerator);
const std::vector<size_t>& triangleToCellIndex() const;
std::array<cvf::Vec3f, 3> triangle(int triangleIdx) const;
@@ -101,7 +101,7 @@ class RivTernaryScalarMapper;
class CellEdgeEffectGenerator : public caf::EffectGenerator
{
public:
CellEdgeEffectGenerator(const cvf::ScalarMapper* edgeScalarMapper);
explicit CellEdgeEffectGenerator(const cvf::ScalarMapper* edgeScalarMapper);
void setScalarMapper(const cvf::ScalarMapper* cellScalarMapper);
void setTernaryScalarMapper(const RivTernaryScalarMapper* ternaryScalarMapper);
@@ -471,7 +471,6 @@ void RivPipeGeometryGenerator::updateFilteredPipeCenterCoords()
double squareDistanceTolerance = 1e-4*1e-4;
const size_t lastOriginalCoordIdx = m_originalPipeCenterCoords->size() - 1;
const size_t originalSegmentCount = m_originalPipeCenterCoords->size() - 1;
size_t firstSegmentWithLength = findFirstSegmentWithLenght(squareDistanceTolerance);
@@ -38,7 +38,7 @@ class RivWellHeadPartMgr;
class RivReservoirPipesPartMgr : public cvf::Object
{
public:
RivReservoirPipesPartMgr(RimEclipseView* reservoirView);
explicit RivReservoirPipesPartMgr(RimEclipseView* reservoirView);
~RivReservoirPipesPartMgr();
void clearGeometryCache();
@@ -46,7 +46,7 @@ namespace cvf
class RivReservoirViewPartMgr: public cvf::Object
{
public:
RivReservoirViewPartMgr(RimEclipseView * resv);
explicit RivReservoirViewPartMgr(RimEclipseView * resv);
cvf::Transform* scaleTransform() { return m_scaleTransform.p();}
@@ -35,7 +35,7 @@ class RivWellSpheresPartMgr;
class RivReservoirWellSpheresPartMgr : public cvf::Object
{
public:
RivReservoirWellSpheresPartMgr(RimEclipseView* reservoirView);
explicit RivReservoirWellSpheresPartMgr(RimEclipseView* reservoirView);
~RivReservoirWellSpheresPartMgr();
void clearGeometryCache();
@@ -188,8 +188,6 @@ void RivSimWellPipesPartMgr::appendDynamicGeometryPartsToModel(cvf::ModelBasicLi
if (m_needsTransformUpdate) buildWellPipeParts();
const RigWellResultFrame& wellResultFrame = m_rimWell->wellResults()->wellResultFrame(frameIndex);
std::list<RivPipeBranchData>::iterator it;
for (it = m_wellBranches.begin(); it != m_wellBranches.end(); ++it)
{
@@ -27,7 +27,7 @@
class RivSourceInfo : public cvf::Object
{
public:
RivSourceInfo(size_t gridIndex) : m_gridIndex(gridIndex) {}
explicit RivSourceInfo(size_t gridIndex) : m_gridIndex(gridIndex) {}
size_t gridIndex() const { return m_gridIndex; }
bool hasCellFaceMapping() const;
@@ -38,7 +38,7 @@ class Font;
class RivTernarySaturationOverlayItem : public cvf::OverlayItem
{
public:
RivTernarySaturationOverlayItem(cvf::Font* font);
explicit RivTernarySaturationOverlayItem(cvf::Font* font);
~RivTernarySaturationOverlayItem();
void setRangeText(const cvf::String& soilRange, const cvf::String& sgasRange, const cvf::String& swatRange);
@@ -35,7 +35,7 @@ namespace cvf
class RivTernaryScalarMapper : public cvf::Object
{
public:
RivTernaryScalarMapper(const cvf::Color3f& undefScalarColor);
explicit RivTernaryScalarMapper(const cvf::Color3f& undefScalarColor);
void setTernaryRanges(double soilLower, double soilUpper, double sgasLower, double sgasUpper);
@@ -42,7 +42,7 @@ namespace cvf
class RivWellPathCollectionPartMgr : public cvf::Object
{
public:
RivWellPathCollectionPartMgr(RimWellPathCollection* wellPathCollection);
explicit RivWellPathCollectionPartMgr(RimWellPathCollection* wellPathCollection);
~RivWellPathCollectionPartMgr();
void scheduleGeometryRegen();
@@ -40,7 +40,7 @@ class RimWellPath;
class RivWellPathPartMgr : public cvf::Object
{
public:
RivWellPathPartMgr(RimWellPath* wellPath);
explicit RivWellPathPartMgr(RimWellPath* wellPath);
~RivWellPathPartMgr();
void setScaleTransform(cvf::Transform * scaleTransform);
@@ -33,7 +33,7 @@ class RimWellPath;
class RivWellPathSourceInfo : public cvf::Object
{
public:
RivWellPathSourceInfo(RimWellPath* wellPath);
explicit RivWellPathSourceInfo(RimWellPath* wellPath);
RimWellPath* wellPath() const;