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

build 170508. fixes for local brake use and 3-way crossroad setup

This commit is contained in:
tmj-fstate
2017-05-08 22:41:56 +02:00
parent 3203ad1f6c
commit 54fc93f6e5
8 changed files with 87 additions and 42 deletions

View File

@@ -304,7 +304,7 @@ void TGroundNode::RenderVBO() { // renderowanie obiektu z VBO - faza nieprzezroc
double distancesquared = SquareMagnitude( pCenter - Global::pCameraPosition ) / Global::ZoomFactor;
if( ( distancesquared > ( fSquareRadius * Global::fDistanceFactor ) )
|| ( distancesquared < ( fSquareMinRadius / Global::fDistanceFactor ) ) ) {
|| ( distancesquared < ( fSquareMinRadius / Global::fDistanceFactor ) ) ) {
return;
}
@@ -318,6 +318,10 @@ void TGroundNode::RenderVBO() { // renderowanie obiektu z VBO - faza nieprzezroc
Model->Render( &pCenter );
return;
}
case TP_MEMCELL: {
GfxRenderer.Render( MemCell );
return;
}
}
if( ( iFlags & 0x10 ) || ( fLineThickness < 0 ) ) {
@@ -577,6 +581,10 @@ void TGroundNode::RenderDL()
Model->Render( &pCenter );
return;
}
case TP_MEMCELL: {
GfxRenderer.Render( MemCell );
return;
}
}
// TODO: sprawdzic czy jest potrzebny warunek fLineThickness < 0
@@ -847,7 +855,12 @@ void TSubRect::NodeAdd(TGroundNode *Node)
// Node->nNext3=nMeshed; //dopisanie do listy sortowania
// nMeshed=Node;
break;
case TP_MEMCELL:
#ifdef EU07_SCENERY_EDITOR
case TP_MEMCELL: {
m_memcells.emplace_back( Node );
break;
}
#endif
case TP_TRACTIONPOWERSOURCE: // a te w ogóle pomijamy
// case TP_ISOLATED: //lista torów w obwodzie izolowanym - na razie ignorowana
break;
@@ -1173,7 +1186,14 @@ void TSubRect::RenderDL()
node->RenderDL(); // nieprzezroczyste z mieszanych modeli
for (int j = 0; j < iTracks; ++j)
tTracks[j]->RenderDyn(); // nieprzezroczyste fragmenty pojazdów na torach
#ifdef EU07_SCENERY_EDITOR
// memcells
if( DebugModeFlag ) {
for( auto const memcell : m_memcells ) {
memcell->RenderDL();
}
}
#endif
/*
float width = 100.0f;
float height = 25.0f;
@@ -1246,6 +1266,14 @@ void TSubRect::RenderVBO()
node->RenderVBO(); // nieprzezroczyste z mieszanych modeli
for (int j = 0; j < iTracks; ++j)
tTracks[j]->RenderDyn(); // nieprzezroczyste fragmenty pojazdów na torach
#ifdef EU07_SCENERY_EDITOR
// memcells
if( DebugModeFlag ) {
for( auto const memcell : m_memcells ) {
memcell->RenderVBO();
}
}
#endif
};
void TSubRect::RenderAlphaVBO()