Skip to content

Commit

Permalink
Don't add cells higher than out_cell to depression volume (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
KCallaghan committed Oct 10, 2020
1 parent 10fae85 commit c5eb46d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions include/fsm/fill_spill_merge.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -914,6 +914,8 @@ void FillDepressions(
if(dep_labels.count(label(ni))==0 && ni!=out_cell)
continue;

if(topo(nx,ny) > topo(out_cell)) //We may not add any cells higher than the out_cell. Without this check, we would sometimes look at higher cells before checking out_cell for the second time.
continue;
//Ocean cells may be found at the edge of a depression. They might get
//added to this list even if there are other, lower, cells within the
//depression which have not yet been explored. This happens when a flat
Expand Down

0 comments on commit c5eb46d

Please sign in to comment.