Changeset 13329
- Timestamp:
- 09/11/12 14:57:54 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/m/mesh/bamg.m
r13009 r13329 64 64 domainfile=getfieldvalue(options,'domain'); 65 65 if ~exist(domainfile,'file') error(['bamg error message: file ' domainfile ' not found ']); end 66 domain=expread(domainfile); 67 68 %Write temporary file, with only the domain outline (exclude holes) 69 expwrite(domain(1),[domainfile '_TEMPouterboundary.exp']); 66 70 67 71 %Build geometry 68 domain=expread(domainfile);69 72 count=0; 70 73 for i=1:length(domain), … … 77 80 %Checks that all holes are INSIDE the principle domain outline 78 81 if i>1, 79 flags=ContourToNodes(domain(i).x,domain(i).y, domain(1),0);82 flags=ContourToNodes(domain(i).x,domain(i).y,[domainfile '_TEMPouterboundary.exp'],0); 80 83 if any(~flags), 81 84 error('bamg error message: All holes should be stricly inside the principal domain'); … … 106 109 107 110 %detect wether all points of the rift are inside the domain 108 flags=ContourToNodes(rift(i).x,rift(i).y, domain(1),0);111 flags=ContourToNodes(rift(i).x,rift(i).y,[domainfile '_TEMPouterboundary.exp'],0); 109 112 if ~flags, 110 113 error('one Rift has all his points outside of the domain outline'), … … 238 241 239 242 %only keep those inside 240 flags=ContourToNodes(requiredvertices(:,1),requiredvertices(:,2), domain(1),0);243 flags=ContourToNodes(requiredvertices(:,1),requiredvertices(:,2),[domainfile '_TEMPouterboundary.exp'],0); 241 244 requiredvertices=requiredvertices(find(flags),:); 242 245 … … 252 255 %process geom 253 256 %bamg_geometry=processgeometry(bamg_geometry,getfieldvalue(options,'tol',NaN),domain(1)); 257 delete([domainfile '_TEMPouterboundary.exp']); 254 258 255 259 elseif isstruct(md.private.bamg) & isfield(md.private.bamg,'geometry'),
Note:
See TracChangeset
for help on using the changeset viewer.