Line data Source code
1 : //* This file is part of the MOOSE framework 2 : //* https://mooseframework.inl.gov 3 : //* 4 : //* All rights reserved, see COPYRIGHT for full restrictions 5 : //* https://github.com/idaholab/moose/blob/master/COPYRIGHT 6 : //* 7 : //* Licensed under LGPL 2.1, please see LICENSE for details 8 : //* https://www.gnu.org/licenses/lgpl-2.1.html 9 : 10 : #ifdef MFEM_ENABLED 11 : 12 : #include "MFEMVisItDataCollection.h" 13 : 14 : registerMooseObject("MooseApp", MFEMVisItDataCollection); 15 : 16 : InputParameters 17 8642 : MFEMVisItDataCollection::validParams() 18 : { 19 8642 : InputParameters params = MFEMDataCollection::validParams(); 20 8642 : params.addClassDescription("Output for controlling export to an mfem::VisItDataCollection."); 21 25926 : params.addParam<unsigned int>("refinements", 22 17284 : 0, 23 : "Number of uniform refinements for oversampling " 24 : "(refinement levels beyond any uniform " 25 : "refinements)"); 26 8642 : return params; 27 0 : } 28 : 29 6 : MFEMVisItDataCollection::MFEMVisItDataCollection(const InputParameters & parameters) 30 : : MFEMDataCollection(parameters), 31 6 : _visit_dc((_file_base + std::string("/Run") + std::to_string(getFileNumber())).c_str(), 32 6 : &_pmesh), 33 12 : _refinements(getParam<unsigned int>("refinements")) 34 : { 35 6 : _visit_dc.SetLevelsOfDetail(_refinements + 1); 36 6 : registerFields(); 37 6 : } 38 : 39 : #endif