re-enabling my terrain renderer line optimization

This commit is contained in:
Chris Forbes
2009-10-29 22:19:31 +13:00
parent 72f77d32e2
commit db7b653daf

View File

@@ -67,8 +67,8 @@ namespace OpenRa.Game.Graphics
int visibleRows = (int)(region.Size.Y / 24.0f + 2);
int firstRow = 0;// (int)( ( region.Position.Y + viewport.Location.Y ) / 24.0f );
int lastRow = 128;// firstRow + visibleRows;
int firstRow = (int)((region.Position.Y + viewport.Location.Y) / 24.0f - map.YOffset);
int lastRow = firstRow + visibleRows;
if (lastRow < 0 || firstRow > map.Height)
return;