diff options
-rw-r--r-- | game/network/rail.cpp | 2 | ||||
-rw-r--r-- | gfx/gl/shader.cpp | 4 | ||||
-rw-r--r-- | gfx/gl/shader.h | 4 |
3 files changed, 7 insertions, 3 deletions
diff --git a/game/network/rail.cpp b/game/network/rail.cpp index 6834989..d095e38 100644 --- a/game/network/rail.cpp +++ b/game/network/rail.cpp @@ -98,7 +98,7 @@ RailLinks::addLinksBetween(glm::vec3 start, glm::vec3 end) void RailLinks::render(const Shader & shader) const { - shader.setModel(Location {}); + shader.setModel(Location {}, Shader::Program::StaticPos); texture->Bind(); links.apply(&RailLink::render, shader); } diff --git a/gfx/gl/shader.cpp b/gfx/gl/shader.cpp index 3021257..b97d6fc 100644 --- a/gfx/gl/shader.cpp +++ b/gfx/gl/shader.cpp @@ -45,6 +45,10 @@ Shader::Shader() : {
landmassShader_vs.compile(),
landmassShader_fs.compile(),
+ },
+ {
+ landmassShader_vs.compile(),
+ basicShader_fs.compile(),
}}}
{
}
diff --git a/gfx/gl/shader.h b/gfx/gl/shader.h index f1fe705..8b18e99 100644 --- a/gfx/gl/shader.h +++ b/gfx/gl/shader.h @@ -11,7 +11,7 @@ class Location; class Shader {
public:
- enum class Program { Basic = 0, Water = 1, LandMass = 2 };
+ enum class Program { Basic = 0, Water = 1, LandMass = 2, StaticPos = 3 };
Shader();
@@ -31,7 +31,7 @@ private: GLint viewProjection_uniform, model_uniform;
};
- std::array<ProgramHandle, 3> programs;
+ std::array<ProgramHandle, 4> programs;
};
#endif
|