mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-07-23 00:29:19 +02:00
Merge branch 'gfx-work' into sim
This commit is contained in:
@@ -672,6 +672,7 @@ struct TCoupling {
|
||||
double CForce = 0.0; /*sila z jaka dzialal*/
|
||||
double Dist = 0.0; /*strzalka ugiecia zderzaków*/
|
||||
bool CheckCollision = false; /*czy sprawdzac sile czy pedy*/
|
||||
float stretch_duration { 0.f }; // seconds, elapsed time with excessive force applied to the coupler
|
||||
|
||||
power_coupling power_high;
|
||||
// power_coupling power_low; // TODO: implement this
|
||||
@@ -1185,6 +1186,7 @@ public:
|
||||
/*--opis konkretnego egzemplarza taboru*/
|
||||
TLocation Loc { 0.0, 0.0, 0.0 }; //pozycja pojazdów do wyznaczenia odległości pomiędzy sprzęgami
|
||||
TRotation Rot { 0.0, 0.0, 0.0 };
|
||||
glm::vec3 Front{};
|
||||
std::string Name; /*nazwa wlasna*/
|
||||
TCoupling Couplers[2]; //urzadzenia zderzno-sprzegowe, polaczenia miedzy wagonami
|
||||
std::array<neighbour_data, 2> Neighbours; // potential collision sources
|
||||
@@ -1450,6 +1452,8 @@ public:
|
||||
bool Attach(int ConnectNo, int ConnectToNr, TMoverParameters *ConnectTo, int CouplingType, bool Forced = false, bool Audible = true);
|
||||
int DettachStatus(int ConnectNo);
|
||||
bool Dettach(int ConnectNo);
|
||||
void damage_coupler( int const End );
|
||||
void derail( int const Reason );
|
||||
bool DirectionForward();
|
||||
bool DirectionBackward( void );/*! kierunek ruchu*/
|
||||
void BrakeLevelSet(double b);
|
||||
@@ -1459,8 +1463,8 @@ public:
|
||||
bool ChangeCab(int direction);
|
||||
bool CurrentSwitch(bool const State);
|
||||
void UpdateBatteryVoltage(double dt);
|
||||
double ComputeMovement(double dt, double dt1, const TTrackShape &Shape, TTrackParam &Track, TTractionParam &ElectricTraction, const TLocation &NewLoc, TRotation &NewRot); //oblicza przesuniecie pojazdu
|
||||
double FastComputeMovement(double dt, const TTrackShape &Shape, TTrackParam &Track, const TLocation &NewLoc, TRotation &NewRot); //oblicza przesuniecie pojazdu - wersja zoptymalizowana
|
||||
double ComputeMovement(double dt, double dt1, const TTrackShape &Shape, TTrackParam &Track, TTractionParam &ElectricTraction, TLocation const &NewLoc, TRotation const &NewRot); //oblicza przesuniecie pojazdu
|
||||
double FastComputeMovement(double dt, const TTrackShape &Shape, TTrackParam &Track, TLocation const &NewLoc, TRotation const &NewRot); //oblicza przesuniecie pojazdu - wersja zoptymalizowana
|
||||
void compute_movement_( double const Deltatime );
|
||||
double ShowEngineRotation(int VehN);
|
||||
|
||||
@@ -1543,7 +1547,7 @@ public:
|
||||
|
||||
/*funkcje obliczajace sily*/
|
||||
void ComputeConstans(void);//ABu: wczesniejsze wyznaczenie stalych dla liczenia sil
|
||||
double ComputeMass(void);
|
||||
void ComputeMass(void);
|
||||
void ComputeTotalForce(double dt);
|
||||
double Adhesive(double staticfriction) const;
|
||||
double TractionForce(double dt);
|
||||
@@ -1552,7 +1556,7 @@ public:
|
||||
double BrakeForceP(double press, double velocity);
|
||||
double BrakeForce(const TTrackParam &Track);
|
||||
double CouplerForce(int const End, double dt);
|
||||
void CollisionDetect(int CouplerN, double dt);
|
||||
void CollisionDetect(int const End, double const dt);
|
||||
/*obrot kol uwzgledniajacy poslizg*/
|
||||
double ComputeRotatingWheel(double WForce, double dt, double n) const;
|
||||
|
||||
@@ -1691,3 +1695,11 @@ private:
|
||||
};
|
||||
|
||||
//double Distance(TLocation Loc1, TLocation Loc2, TDimension Dim1, TDimension Dim2);
|
||||
|
||||
namespace simulation {
|
||||
|
||||
using weights_table = std::unordered_map<std::string, float>;
|
||||
|
||||
extern weights_table Weights;
|
||||
|
||||
} // simulation
|
||||
|
||||
Reference in New Issue
Block a user