From 356e874050e5ad5af87b04a2bb01ce34a86640bb Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Mon, 13 Nov 2023 00:17:11 +0000 Subject: Send position and rotation matrix to GPU separately --- game/vehicles/railVehicleClass.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'game/vehicles/railVehicleClass.cpp') diff --git a/game/vehicles/railVehicleClass.cpp b/game/vehicles/railVehicleClass.cpp index 324148c..7a6a9fe 100644 --- a/game/vehicles/railVehicleClass.cpp +++ b/game/vehicles/railVehicleClass.cpp @@ -35,13 +35,15 @@ void RailVehicleClass::postLoad() { texture = getTexture(); - bodyMesh->configureVAO(instanceVAO).addAttribs(instances.bufferName(), 1); + bodyMesh->configureVAO(instanceVAO) + .addAttribs(instances.bufferName(), 1); bogies.front() ->configureVAO(instancesBogiesVAO.front()) - .addAttribs(instances.bufferName(), 1); + .addAttribs(instances.bufferName(), 1); bogies.back() ->configureVAO(instancesBogiesVAO.back()) - .addAttribs(instances.bufferName(), 1); + .addAttribs(instances.bufferName(), 1); + static_assert(sizeof(LocationVertex) == 228UL); } void -- cgit v1.2.3