57 float elevation_ratio = 0.f,
58 float distance_exponent = 0.5f,
59 float upward_penalization = 1.f,
60 Array *p_mask_nogo =
nullptr);
89 float dijk_elevation_ratio = 0.9f,
90 float dijk_distance_exponent = 2.f,
91 float dijk_upward_penalization = 100.f,
93 bool favor_boundary_center =
true,
94 bool favor_lower_elevation =
true,
95 bool favor_sinks =
true);
123 float offset_ratio = 0.2f,
125 bool favor_boundary_center =
true,
126 bool favor_lower_elevation =
true,
127 bool favor_sinks =
true);
173 std::vector<int> &i_path,
174 std::vector<int> &j_path,
175 float elevation_ratio = 0.1f,
176 float distance_exponent = 2.f,
177 float upward_penalization = 1.f,
178 const Array *p_mask_nogo =
nullptr);
182 std::vector<glm::ivec2> ij_end_list,
183 std::vector<std::vector<int>> &i_path_list,
184 std::vector<std::vector<int>> &j_path_list,
185 float elevation_ratio = 0.1f,
186 float distance_exponent = 2.f,
187 float upward_penalization = 1.f,
188 const Array *p_mask_nogo =
nullptr);
215 float offset_ratio = 0.5f,
Declaration of the Array class for 2D floating-point arrays with various mathematical operations and ...
unsigned int uint
Definition array.hpp:14
Header file for boundary condition functions and utilities.
Definition algebra.hpp:23
DomainBoundary
Describes which domain boundary.
Definition boundary.hpp:43
Path find_cut_path_dijkstra(const Array &z, DomainBoundary start, DomainBoundary end, float dijk_elevation_ratio=0.9f, float dijk_distance_exponent=2.f, float dijk_upward_penalization=100.f, uint seed=0, bool favor_boundary_center=true, bool favor_lower_elevation=true, bool favor_sinks=true)
Find a Dijkstra-based cut path between two domain boundaries.
Definition find_cut_path.cpp:11
Path find_cut_path_midpoint(const Array &z, DomainBoundary start, DomainBoundary end, uint seed, float offset_ratio=0.2f, int steps=16, bool favor_boundary_center=true, bool favor_lower_elevation=true, bool favor_sinks=true)
Generate a stochastic cut path using midpoint displacement.
Definition find_cut_path.cpp:70
Path dijkstra(const Path &path, const Array &array, glm::vec4 bbox, float elevation_ratio=0.f, float distance_exponent=0.5f, float upward_penalization=1.f, Array *p_mask_nogo=nullptr)
Divide the path by adding points based on the lowest elevation difference between each pair of edge e...
Definition dijsktra_path.cpp:12
std::vector< glm::ivec2 > find_path_midpoint(const Array &z, glm::ivec2 ij_start, glm::ivec2 ij_end, float offset_ratio=0.5f, int max_it=0, int steps=16)
Compute a path between two points using iterative midpoint refinement.
Definition find_path_midpoint.cpp:73
void find_path_dijkstra(const Array &z, glm::ivec2 ij_start, glm::ivec2 ij_end, std::vector< int > &i_path, std::vector< int > &j_path, float elevation_ratio=0.1f, float distance_exponent=2.f, float upward_penalization=1.f, const Array *p_mask_nogo=nullptr)
Finds the path with the lowest elevation and elevation difference between two points in a 2D array us...
Definition dijsktra.cpp:141
Path class for manipulating and analyzing paths in 2D space.