mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-03-22 15:05:03 +01:00
higher quality map
This commit is contained in:
15
Segment.cpp
15
Segment.cpp
@@ -521,3 +521,18 @@ bool TSegment::RenderLoft( gfx::vertex_array &Output, Math3D::vector3 const &Ori
|
||||
return true;
|
||||
};
|
||||
|
||||
void TSegment::render_lines(std::vector<gfx::basic_vertex> &out, float quality) const
|
||||
{
|
||||
float step = 1.0f / iSegCount / quality;
|
||||
|
||||
float x;
|
||||
|
||||
glm::vec3 previous = FastGetPoint(0.0);
|
||||
|
||||
for (x = step; x <= 1.0f; x += step) {
|
||||
out.push_back(gfx::basic_vertex(previous, glm::vec3(0.0f), glm::vec2(0.0f)));
|
||||
|
||||
previous = glm::vec3(FastGetPoint(x));
|
||||
out.push_back(gfx::basic_vertex(previous, glm::vec3(0.0f), glm::vec2(0.0f)));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user