From: Bruno Turcksin Date: Fri, 11 Sep 2020 20:45:34 +0000 (+0000) Subject: Add constructor to GridIn that directly attaches the Triangulation X-Git-Tag: v9.3.0-rc1~1122^2~1 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b7a6f998a75556861185728faabbf2cf7b79a4e7;p=dealii.git Add constructor to GridIn that directly attaches the Triangulation --- diff --git a/include/deal.II/grid/grid_in.h b/include/deal.II/grid/grid_in.h index 17062b68ff..56bacfe3fd 100644 --- a/include/deal.II/grid/grid_in.h +++ b/include/deal.II/grid/grid_in.h @@ -341,6 +341,11 @@ public: */ GridIn(); + /** + * Constructor. Attach this triangulation to be fed with the grid data. + */ + GridIn(Triangulation &tria); + /** * Attach this triangulation to be fed with the grid data. */ diff --git a/source/grid/grid_in.cc b/source/grid/grid_in.cc index e60737bf93..421e30db9c 100644 --- a/source/grid/grid_in.cc +++ b/source/grid/grid_in.cc @@ -96,6 +96,15 @@ GridIn::GridIn() {} + +template +GridIn::GridIn(Triangulation &t) + : tria(&t, typeid(*this).name()) + , default_format(ucd) +{} + + + template void GridIn::attach_triangulation(Triangulation &t)