mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-10-17 05:09:20 +02:00
feat(terrain): grade line fitted to the ground under the route within the limits; editor terrain shaped to the grade line with a formation and rounded slopes, with one step back; scenery ground triangles of chosen materials converted to editor terrain and taken out of the files on save, with a dated backup of each file; crack-free simplified terrain mesh, terrain streamed as far as the scenery is drawn, the nearest chunks first; smoothing brush
This commit is contained in:
@@ -111,6 +111,15 @@ struct recognition
|
||||
// grade line of existing track, from its elevations and grades sampled along the chainage
|
||||
line recognize(std::vector<double> const &Chainages, std::vector<double> const &Elevations, std::vector<double> const &Grades, recognition const &Options);
|
||||
|
||||
struct ground_fit
|
||||
{
|
||||
double tolerance{1.0}; // m, departure from the ground which doesn't yet need a change of grade
|
||||
double smoothing{20.0}; // m, length over which the ground is averaged
|
||||
};
|
||||
// grade line which follows the ground within the limits of Settings, with the least earthworks.
|
||||
// Ground is NaN where there's none; the joined ends of the route keep the elevation of the adjoining track
|
||||
line fit_ground(std::vector<double> const &Chainages, std::vector<double> const &Ground, context const &Context, line const &Settings, ground_fit const &Options);
|
||||
|
||||
// chainages where the paths have to end so that each of them carries a single grade or a single curve
|
||||
std::vector<double> breaks(line const &Line);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user