summaryrefslogtreecommitdiff
path: root/game/scenary/foliage.cpp
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2024-10-10 00:59:41 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2024-10-10 00:59:41 +0100
commit439630ae86b01b714574335d4dd2e583f724dba3 (patch)
tree719374873dad863c4a71c741ed74f143bc52b089 /game/scenary/foliage.cpp
parentFix stencil shadow depth offset (diff)
downloadilt-439630ae86b01b714574335d4dd2e583f724dba3.tar.bz2
ilt-439630ae86b01b714574335d4dd2e583f724dba3.tar.xz
ilt-439630ae86b01b714574335d4dd2e583f724dba3.zip
Include foliage yaw rotation in vertex, pass through instead of whole model rotation matrix
Diffstat (limited to 'game/scenary/foliage.cpp')
-rw-r--r--game/scenary/foliage.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/game/scenary/foliage.cpp b/game/scenary/foliage.cpp
index 1e7424e..c90d5be 100644
--- a/game/scenary/foliage.cpp
+++ b/game/scenary/foliage.cpp
@@ -15,8 +15,9 @@ Foliage::postLoad()
{
texture = getTexture();
bodyMesh->configureVAO(instanceVAO)
- .addAttribs<LocationVertex, &LocationVertex::first, &LocationVertex::second>(instances.bufferName(), 1);
- VertexArrayObject {instancePointVAO}.addAttribs<LocationVertex, &LocationVertex::first, &LocationVertex::second>(
+ .addAttribs<LocationVertex, &LocationVertex::rotation, &LocationVertex::position>(
+ instances.bufferName(), 1);
+ VertexArrayObject {instancePointVAO}.addAttribs<LocationVertex, &LocationVertex::position, &LocationVertex::yaw>(
instances.bufferName());
}