@@ -199,10 +199,16 @@ PYBIND11_MODULE(polyfempy, m) {
199199 Eigen::MatrixXd discr;
200200 Eigen::MatrixXd fun;
201201
202+ const bool tmp = s.args [" export" ][" vis_boundary_only" ];
203+ s.args [" export" ][" vis_boundary_only" ] = boundary_only;
204+
202205 s.build_vis_mesh (points, tets, discr);
203206
204207
205208 s.interpolate_function (points.rows (), s.sol , fun, boundary_only);
209+
210+ s.args [" export" ][" vis_boundary_only" ] = tmp;
211+
206212 return py::make_tuple (points, tets, fun);
207213 },
208214 " returns the solution on a densly sampled mesh, use 'vismesh_rel_area' to control density" ,
@@ -214,9 +220,14 @@ PYBIND11_MODULE(polyfempy, m) {
214220 Eigen::MatrixXd discr;
215221 Eigen::MatrixXd fun;
216222
223+ const bool tmp = s.args [" export" ][" vis_boundary_only" ];
224+ s.args [" export" ][" vis_boundary_only" ] = boundary_only;
225+
217226 s.build_vis_mesh (points, tets, discr);
218227 s.compute_tensor_value (points.rows (), s.sol , fun, boundary_only);
219228
229+ s.args [" export" ][" vis_boundary_only" ] = tmp;
230+
220231 return fun;
221232 },
222233 " returns the stress tensor on a densly sampled mesh, use 'vismesh_rel_area' to control density" ,
@@ -228,9 +239,14 @@ PYBIND11_MODULE(polyfempy, m) {
228239 Eigen::MatrixXd discr;
229240 Eigen::MatrixXd fun;
230241
242+ const bool tmp = s.args [" export" ][" vis_boundary_only" ];
243+ s.args [" export" ][" vis_boundary_only" ] = boundary_only;
244+
231245 s.build_vis_mesh (points, tets, discr);
232246 s.compute_scalar_value (points.rows (), s.sol , fun, boundary_only);
233247
248+ s.args [" export" ][" vis_boundary_only" ] = tmp;
249+
234250 return fun;
235251 },
236252 " returns the von mises stresses on a densly sampled mesh, use 'vismesh_rel_area' to control density" ,
@@ -242,9 +258,14 @@ PYBIND11_MODULE(polyfempy, m) {
242258 Eigen::MatrixXd discr;
243259 Eigen::MatrixXd fun, tfun;
244260
261+ const bool tmp = s.args [" export" ][" vis_boundary_only" ];
262+ s.args [" export" ][" vis_boundary_only" ] = boundary_only;
263+
245264 s.build_vis_mesh (points, tets, discr);
246265 s.average_grad_based_function (points.rows (), s.sol , fun, tfun, boundary_only);
247266
267+ s.args [" export" ][" vis_boundary_only" ] = tmp;
268+
248269 return py::make_tuple (fun, tfun);
249270 },
250271 " returns the von mises stresses and stress tensor averaged around a vertex on a densly sampled mesh, use 'vismesh_rel_area' to control density" ,
0 commit comments