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

fixes for display list path camera-centric rendering, basic support for binary terrain object type, fix for assignment of 3d objects to terrain cells

This commit is contained in:
tmj-fstate
2017-05-26 21:22:13 +02:00
parent 2b6ea903bc
commit 3068cc669e
8 changed files with 150 additions and 112 deletions

View File

@@ -166,7 +166,7 @@ public:
return NULL;
};
void Compile(bool many = false);
void Compile(Math3D::vector3 const &Origin, bool const Multiple = false);
void Release();
void RenderHidden(); // obsługa dźwięków i wyzwalaczy zdarzeń
@@ -341,16 +341,15 @@ class TGround
{
return &Rects[GetColFromX(x) / iNumSubRects][GetRowFromZ(z) / iNumSubRects];
};
TSubRect * GetSubRect( int iCol, int iRow );
TSubRect * GetSubRect(double x, double z)
{
return GetSubRect(GetColFromX(x), GetRowFromZ(z));
};
TSubRect * FastGetSubRect(double x, double z)
{
return FastGetSubRect(GetColFromX(x), GetRowFromZ(z));
TSubRect * FastGetSubRect( int iCol, int iRow );
TSubRect * FastGetSubRect( double x, double z ) {
return FastGetSubRect( GetColFromX( x ), GetRowFromZ( z ) );
};
TSubRect * GetSubRect(int iCol, int iRow);
TSubRect * FastGetSubRect(int iCol, int iRow);
int GetRowFromZ(double z)
{
return (int)(z / fSubRectSize + fHalfTotalNumSubRects);