mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-02 23:16:22 +01:00
feat(editor): far out the top view shows the base map of OpenStreetMap from geoportal.gov.pl in place of the imagery, tiles as large as the view needs, the ground not drawn under it nor streamed as far as the view; the tracks over it in the colour of the rails, blue by default, and the joints of the pieces left out far out
This commit is contained in:
@@ -598,7 +598,7 @@ void terrain_streamer::update(glm::dvec3 const &Camera)
|
||||
}
|
||||
|
||||
// the top view of the tracks wants the terrain as far as the corners of the screen, as fine as its pixels need
|
||||
auto const top{Global.EditorOrtho && Global.editor_tracks};
|
||||
auto const top{Global.EditorOrtho && Global.editor_tracks && false == Global.EditorOrthoMap};
|
||||
auto const aspect{Global.window_size.x / std::max(1.0, static_cast<double>(Global.window_size.y))};
|
||||
auto const reach{top ? Global.EditorOrthoExtent * std::sqrt(1.0 + aspect * aspect) : 0.0};
|
||||
m_pixel = top ? 2.0 * Global.EditorOrthoExtent / std::max(1, Global.window_size.y) : 0.0;
|
||||
|
||||
Reference in New Issue
Block a user