16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-18 22:39:18 +02:00

merge2 (incomplete)

This commit is contained in:
VB
2017-06-20 23:05:07 +02:00
38 changed files with 3068 additions and 4144 deletions

View File

@@ -1265,7 +1265,7 @@ TWorld::Render_Cab() {
}
TDynamicObject *dynamic = Train->Dynamic();
TSubModel::iInstance = reinterpret_cast<size_t>( dynamic );
TSubModel::iInstance = reinterpret_cast<std::size_t>( dynamic );
if( ( true == FreeFlyModeFlag )
|| ( false == dynamic->bDisplayCab )
@@ -1273,8 +1273,6 @@ TWorld::Render_Cab() {
// ABu: Rendering kabiny jako ostatniej, zeby bylo widac przez szyby, tylko w widoku ze srodka
return;
}
::glEnable( GL_LIGHTING ); // po renderowaniu drutów może być to wyłączone. TODO: have the wires render take care of its own shit
/*
glPushMatrix();
vector3 pos = dynamic->GetPosition(); // wszpółrzędne pojazdu z kabiną
@@ -1649,27 +1647,15 @@ TWorld::Update_UI() {
}
case( GLFW_KEY_F8 ) : {
// gfx renderer data
uitextline1 =
"Draw range x " + to_string( Global::fDistanceFactor, 1 )
+ "; FPS: " + to_string( Timer::GetFPS(), 2 );
"FoV: " + to_string( Global::FieldOfView / Global::ZoomFactor, 1 )
+ ", Draw range x " + to_string( Global::fDistanceFactor, 1 )
+ "; sectors: " + std::to_string( GfxRenderer.m_drawcount )
+ ", FPS: " + to_string( Timer::GetFPS(), 2 );
if( Global::iSlowMotion ) {
uitextline1 += " (slowmotion " + to_string( Global::iSlowMotion ) + ")";
}
uitextline1 +=
", sectors: " + to_string( Ground.iRendered )
+ "/" + to_string( Global::iSegmentsRendered )
+ "; FoV: " + to_string( Global::FieldOfView / Global::ZoomFactor, 1 );
break;
}
case( GLFW_KEY_F9 ) : {
// informacja o wersji, sposobie wyświetlania i błędach OpenGL
uitextline1 = "MaSzyna " + Global::asVersion; // informacja o wersji
if( Global::iMultiplayer ) {
uitextline1 += " (multiplayer mode is active)";
}
uitextline2 = GfxRenderer.Info();
@@ -1681,10 +1667,22 @@ TWorld::Update_UI() {
Global::LastGLError = std::to_string( glerror ) + " (" + glerrorstring + ")";
}
if( false == Global::LastGLError.empty() ) {
uitextline3 =
uitextline2 +=
"Last openGL error: "
+ Global::LastGLError;
}
// renderer stats
uitextline3 = GfxRenderer.Info();
break;
}
case( GLFW_KEY_F9 ) : {
// informacja o wersji
uitextline1 = "MaSzyna " + Global::asVersion; // informacja o wersji
if( Global::iMultiplayer ) {
uitextline1 += " (multiplayer mode is active)";
}
break;
}