Skip to content

Commit d9e4114

Browse files
committed
[bug] fix #85, but it don't do anything as cgalsurf always returns 0
1 parent 9a31573 commit d9e4114

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

vol2restrictedtri.m

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,14 @@
4848
initnum = getvarfrom({'caller', 'base'}, 'ISO2MESH_INITSIZE');
4949
end
5050

51-
system([' "' mcpath('cgalsurf') exesuff '" "' mwpath('pre_extract.inr') ...
51+
status = system([' "' mcpath('cgalsurf') exesuff '" "' mwpath('pre_extract.inr') ...
5252
'" ' sprintf('%.16f %.16f %.16f %.16f %.16f %.16f %.16f %.16f %d ', thres, cent, brad, ang, radbound, distbound, maxnode) ...
5353
' "' mwpath('post_extract.off') '" ' sprintf('%.0f %d', randseed, initnum)]);
54+
55+
if(status)
56+
error('cgalsurf failed to extract surfaces');
57+
end
58+
5459
[node, elem] = readoff(mwpath('post_extract.off'));
5560

5661
[node, elem] = meshcheckrepair(node, elem);

0 commit comments

Comments
 (0)