1、修复生成vtk文件失败的问题;

feature/ribbon-menu-20240927
simonyan 3 weeks ago
parent 5adffb3c20
commit 5ed163b058

@ -21,10 +21,10 @@ QString nmDataGeo::createFile()
// 设置网格厚度,目前只支持单层网格
double gridThickness = 0.2;
geoLines.append(QString("Extrude {0, 0, %1} {Surface{1};Layers{1};Recombine;}").arg(gridThickness));
geoLines.append("Mesh.Algorithm = 2");
geoLines.append("Mesh.ElementOrder = 1");
geoLines.append("Mesh.Mode = 3");
geoLines.append("Mesh.CharacteristicLengthFactor = 1.0");
// geoLines.append("Mesh.Algorithm = 2");
// geoLines.append("Mesh.ElementOrder = 1");
// geoLines.append("Mesh.Mode = 3");
// geoLines.append("Mesh.CharacteristicLengthFactor = 1.0");
return geoLines.join("\n");
}

@ -152,7 +152,7 @@ void nmSubWndGrid::genGrid()
// 设置工作目录
QDir::setCurrent(sDir);
// 要执行的命令和参数
process.start("gmsh.exe", QStringList() << "-2" << "-t" << "oil.geo" << "-o" << "oil.vtk");
process.start("gmsh.exe", QStringList() << "-2" << "oil.geo" << "-o" << "oil.vtk");
// 等待命令启动
if (!process.waitForStarted()) {
nmDataLogFile::getInstance()->writeLog("Command failed to start.");

Loading…
Cancel
Save