17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-11-03 19:00:22 +01:00

feat(track): the blades of a switch whose frog is cut from the rails are made from its geometry: the tip is where the gauge lines of both paths are 3 mm apart, the head reaches its full width where they are a head plus 0.5 mm apart, and the heel is the shortest blade whose open flangeway stays at least 58 mm with a throw of 160 mm bent like a cantilever from the heel, or straight when that does not fit as in slips; the blade is the whole rail profile lofted from the tip to the heel, cut along the head of the stock rail, with the head lowered by the drop of the blade half of the profile file towards the tip and back to the top at a 50 mm head, and thrown with knots every 0.5 m so the vertex count does not change between the positions; the stock rails get stations every 0.5 m along the blades so their curve follows the blade, the fixed rail behind the heel starts at the heel, the old blades take their segment count per path, and the self-test command blade logs the tip, heel, drop, flangeway and the gauge lines against x^2/2R and faults on a short flangeway, a heel past the throat or a change of the vertex count

This commit is contained in:
maj00r
2026-10-14 03:32:41 +02:00
parent df2bbae449
commit 20c4b6542e
7 changed files with 256 additions and 11 deletions

View File

@@ -308,6 +308,21 @@ public:
double angle { 0.0 };
};
switch_frog frog() const;
struct switch_blade {
bool valid { false };
bool rigid { false };
double tip { 0.0 };
double full { 0.0 };
double heel { 0.0 };
double drop { 0.0 };
double opening { 0.0 };
double openingat { 0.0 };
std::vector<glm::dvec2> gauge;
std::vector<glm::dvec2> extents;
std::vector<glm::dvec2> drops;
std::vector<glm::dvec2> bends;
};
switch_blade const &blade( int const Path ) const;
// where a rail of this track crosses a rail of another one, found from their gauge lines
struct rail_crossing {
TTrack *track { nullptr };