diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2024-04-16 00:23:43 +0100 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2024-04-16 00:23:43 +0100 |
commit | 741bb027df58fd9f30f4d94cdaf2d6416e11e3ee (patch) | |
tree | 67a91f8c4f5394df90bf7ce149229bb85389749f /gfx/gl/shadowMapper.cpp | |
parent | Create terrain vertices per surface type (diff) | |
download | ilt-741bb027df58fd9f30f4d94cdaf2d6416e11e3ee.tar.bz2 ilt-741bb027df58fd9f30f4d94cdaf2d6416e11e3ee.tar.xz ilt-741bb027df58fd9f30f4d94cdaf2d6416e11e3ee.zip |
Custom vertex, vertex shader and fragment shader for landmass
Handles global position type, colourBias for surface types
Diffstat (limited to 'gfx/gl/shadowMapper.cpp')
-rw-r--r-- | gfx/gl/shadowMapper.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gfx/gl/shadowMapper.cpp b/gfx/gl/shadowMapper.cpp index 4dbee8d..206e4a7 100644 --- a/gfx/gl/shadowMapper.cpp +++ b/gfx/gl/shadowMapper.cpp @@ -4,7 +4,7 @@ #include "gfx/gl/shaders/gs-commonShadowPoint.h" #include "gfx/gl/shaders/vs-shadowDynamicPoint.h" #include "gfx/gl/shaders/vs-shadowDynamicPointInst.h" -#include "gfx/gl/shaders/vs-shadowFixedPoint.h" +#include "gfx/gl/shaders/vs-shadowLandmass.h" #include "gl_traits.h" #include "location.h" #include "maths.h" @@ -18,7 +18,7 @@ #include <vector> ShadowMapper::ShadowMapper(const TextureAbsCoord & s) : - fixedPoint {shadowFixedPoint_vs}, dynamicPointInst {shadowDynamicPointInst_vs}, size {s} + landmess {shadowLandmass_vs}, dynamicPointInst {shadowDynamicPointInst_vs}, size {s} { glBindTexture(GL_TEXTURE_2D_ARRAY, depthMap); glTexImage3D( @@ -92,7 +92,7 @@ ShadowMapper::update(const SceneProvider & scene, const Direction3D & dir, const return lightProjection * lightViewDir; }); - for (const auto p : std::initializer_list<const ShadowProgram *> {&fixedPoint, &dynamicPoint, &dynamicPointInst}) { + for (const auto p : std::initializer_list<const ShadowProgram *> {&landmess, &dynamicPoint, &dynamicPointInst}) { p->setView(out, lightViewPoint); } scene.shadows(*this); |