Skip to content
Snippets Groups Projects
Commit 755c7740 authored by Martin Schneider's avatar Martin Schneider
Browse files

[opm][geometry] Correct opm-grid patch

Adapt geometry() functions of opm-grid
parent 87e5967e
No related branches found
No related tags found
2 merge requests!600[WIP][components][plotproperties] Add a source file to plot properties of some components,!526[opm] Update dumux to newest opm release
diff --git a/dune/grid/cpgrid/Entity.hpp b/dune/grid/cpgrid/Entity.hpp diff --git a/dune/grid/cpgrid/Entity.hpp b/dune/grid/cpgrid/Entity.hpp
index eadcb33..290fbb0 100644 index eadcb33..0efcedd 100644
--- a/dune/grid/cpgrid/Entity.hpp --- a/dune/grid/cpgrid/Entity.hpp
+++ b/dune/grid/cpgrid/Entity.hpp +++ b/dune/grid/cpgrid/Entity.hpp
@@ -148,7 +148,7 @@ namespace Dune
}
/// Returns the geometry of the entity (does not depend on its orientation).
- const Geometry& geometry() const;
+ Geometry geometry() const;
/// We do not support refinement, so level() is always 0.
int level() const
@@ -182,7 +182,7 @@ namespace Dune @@ -182,7 +182,7 @@ namespace Dune
/// The count of subentities of codimension cc /// The count of subentities of codimension cc
unsigned int subEntities ( const unsigned int cc ) const unsigned int subEntities ( const unsigned int cc ) const
...@@ -11,6 +20,15 @@ index eadcb33..290fbb0 100644 ...@@ -11,6 +20,15 @@ index eadcb33..290fbb0 100644
if (cc == 0) { if (cc == 0) {
return 1; return 1;
} else if (cc == 3) { } else if (cc == 3) {
@@ -412,7 +412,7 @@ namespace Dune {
namespace cpgrid {
template <int codim>
-const typename Entity<codim>::Geometry& Entity<codim>::geometry() const
+typename Entity<codim>::Geometry Entity<codim>::geometry() const
{
return pgrid_->geomVector<codim>()[*this];
}
diff --git a/dune/grid/cpgrid/Geometry.hpp b/dune/grid/cpgrid/Geometry.hpp diff --git a/dune/grid/cpgrid/Geometry.hpp b/dune/grid/cpgrid/Geometry.hpp
index 86d82a5..10c7e14 100644 index 86d82a5..10c7e14 100644
--- a/dune/grid/cpgrid/Geometry.hpp --- a/dune/grid/cpgrid/Geometry.hpp
...@@ -68,6 +86,19 @@ index 86d82a5..10c7e14 100644 ...@@ -68,6 +86,19 @@ index 86d82a5..10c7e14 100644
} }
/// Using the cube type for all entities now (cells and vertices), /// Using the cube type for all entities now (cells and vertices),
diff --git a/dune/grid/cpgrid/Intersection.hpp b/dune/grid/cpgrid/Intersection.hpp
index f7152ef..cf01473 100644
--- a/dune/grid/cpgrid/Intersection.hpp
+++ b/dune/grid/cpgrid/Intersection.hpp
@@ -188,7 +188,7 @@ namespace Dune
/// @brief
/// @todo Doc me!
/// @return
- const Geometry& geometry() const
+ Geometry geometry() const
{
return global_geom_;
}
diff --git a/dune/grid/polyhedralgrid/geometry.hh b/dune/grid/polyhedralgrid/geometry.hh diff --git a/dune/grid/polyhedralgrid/geometry.hh b/dune/grid/polyhedralgrid/geometry.hh
index 64a15fc..9c3c0b4 100644 index 64a15fc..9c3c0b4 100644
--- a/dune/grid/polyhedralgrid/geometry.hh --- a/dune/grid/polyhedralgrid/geometry.hh
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment