initial upload
This commit is contained in:
34
archive/gmshinfo/main.cpp
Normal file
34
archive/gmshinfo/main.cpp
Normal file
@@ -0,0 +1,34 @@
|
||||
#include "func.h"
|
||||
void disp_help()
|
||||
{
|
||||
cout<<"gmshinfo 0.1 - inspect a Gmsh .msh file and show relative infomation"<<endl<<endl
|
||||
<<"syntax: gmshinfo <filename> [filename ...]"<<endl
|
||||
<<" The program takes at least one filename for the input information, and it only support ASCII format."<<endl;
|
||||
|
||||
}
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
{
|
||||
|
||||
char* filename;
|
||||
|
||||
if (argc == 1)
|
||||
{
|
||||
disp_help();
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int i = 1; i < argc; ++i)
|
||||
{
|
||||
MshInfo meshone;
|
||||
filename = argv[i];
|
||||
meshone.init();
|
||||
if(!meshone.readmsh(filename))
|
||||
{
|
||||
meshone.relese_node_id();
|
||||
meshone.showinfo();
|
||||
}
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
Reference in New Issue
Block a user