Skip to content

Commit

Permalink
Update polygon2GRIDobj.m
Browse files Browse the repository at this point in the history
  • Loading branch information
wschwanghart committed Sep 4, 2020
1 parent e7155a1 commit 13fbd01
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions @GRIDobj/polygon2GRIDobj.m
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
writelogical = true;
writeclass = @logical;
else
P = GRIDobj(DEM,'single');
P = GRIDobj(DEM,'single')*nan;
writelogical = false;
writeclass = @single;
end
Expand Down Expand Up @@ -126,10 +126,10 @@
is_hole(IX_hole) = true;

% loop through features of mapping structure MS
% h = waitbar(0);
h = waitbar(0);
for r = 1:numel(MS)
% waitbar(r/numel(MS),h,...
% ['Please wait (' num2str(r) '/' num2str(numel(MS)) ')']);
waitbar(r/numel(MS),h,...
['Please wait (' num2str(r) '/' num2str(numel(MS)) ')']);

% get coordinates
x = MS(r).X;
Expand Down Expand Up @@ -174,7 +174,7 @@
P.Z(ext(1):ext(2),ext(3):ext(4)) = FillMat;

end
% close(h)
close(h)
end

function [BW,ext] = getmask(r,c,siz)
Expand Down

0 comments on commit 13fbd01

Please sign in to comment.