mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-07 20:16:08 +01:00
fix: structure gauge measured from the rail head, not the rail foot of the scenery points
This commit is contained in:
@@ -51,8 +51,9 @@ gauge_line make_line(editor_track::route &Route)
|
|||||||
gauge_line line;
|
gauge_line line;
|
||||||
line.samples = editor_track::sample_route(Route, 1.0);
|
line.samples = editor_track::sample_route(Route, 1.0);
|
||||||
std::vector<double> chainage, curvature, cant;
|
std::vector<double> chainage, curvature, cant;
|
||||||
for (auto const &sample : line.samples)
|
for (auto &sample : line.samples)
|
||||||
{
|
{
|
||||||
|
sample.position.y += gauge::rail_height;
|
||||||
chainage.push_back(sample.chainage);
|
chainage.push_back(sample.chainage);
|
||||||
curvature.push_back(sample.curvature);
|
curvature.push_back(sample.curvature);
|
||||||
cant.push_back(sample.cant);
|
cant.push_back(sample.cant);
|
||||||
|
|||||||
@@ -37,6 +37,9 @@ std::vector<profile> default_profiles();
|
|||||||
std::vector<profile> load_profiles(std::string const &File);
|
std::vector<profile> load_profiles(std::string const &File);
|
||||||
void save_profiles(std::string const &File, std::vector<profile> const &Profiles);
|
void save_profiles(std::string const &File, std::vector<profile> const &Profiles);
|
||||||
|
|
||||||
|
// the points of the paths in the scenery lie at the rail foot, the gauge is measured from the rail head
|
||||||
|
double constexpr rail_height{0.18};
|
||||||
|
|
||||||
// below this height the outline is the limit installation gauge, which leaves the room for the platforms
|
// below this height the outline is the limit installation gauge, which leaves the room for the platforms
|
||||||
double constexpr lower_part{1.17};
|
double constexpr lower_part{1.17};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user