Skip to content
Snippets Groups Projects
Commit 9ad110ed authored by Anna Wellmann's avatar Anna Wellmann
Browse files

Call initGridPaths in setGridPaths

parent c83a819a
No related branches found
No related tags found
1 merge request!115Enable running VirtualFluidsGPU without config file
......@@ -360,18 +360,17 @@ void Parameter::initGridPaths(){
std::string gridPath = this->getGridPath();
// add missing slash to gridPath
if (gridPath.back() != '/')
{
if (gridPath.back() != '/') {
gridPath += "/";
this->setGridPath(gridPath);
ic.gridPath = gridPath;
}
// for multi-gpu add process id
if (this->getNumprocs() > 1){
// for multi-gpu add process id (if not already there)
if (this->getNumprocs() > 1) {
gridPath += StringUtil::toString(this->getMyID()) + "/";
this->setGridPath(gridPath);
ic.gridPath = gridPath;
}
//////////////////////////////////////////////////////////////////////////
this->setgeoVec(gridPath + "geoVec.dat");
......@@ -758,6 +757,7 @@ void Parameter::setFName(std::string fname)
void Parameter::setGridPath(std::string gridPath)
{
ic.gridPath = gridPath;
this->initGridPaths();
}
void Parameter::setPrintFiles(bool printfiles)
{
......
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