Commit 1985e97f authored by Markus Mueller-Trapet's avatar Markus Mueller-Trapet

add option for stored itaMesh object

parent 5d56427a
......@@ -319,11 +319,17 @@ if ~isempty(meshFilename)
surfElem = makeShellElements(volElem);
generateGroups = 1;
else %.mat-file
else %.mat-file
classes = load(meshFilename);
fnames = fieldnames(classes);
%supported file?
if length(fnames) == 2 && isa(classes.(fnames{1}),...
if isa(classes.(fnames{1}),'itaMesh')
mesh = classes.(fnames{1});
coord = mesh.nodes;
volElem = mesh.volumeElements;
surfElem = mesh.shellElements;
generateGroups = 1;
elseif length(fnames) == 2 && isa(classes.(fnames{1}),...
'itaMeshNodes') && isa(classes.(fnames{2}), 'itaMeshElements')
coord = classes.coord;
volElem = classes.elem;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment