From 4420f20a901ed1f96d9fb8f4df0148bc0bc3666d Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Sat, 7 Mar 2026 12:32:55 +0000 Subject: Add glVertexArray useBuffer Wraps glVertexArrayVertexBuffer automatically getting the buffer name from the argument and deriving the stride from the container's value_type. --- game/network/rail.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'game/network') diff --git a/game/network/rail.cpp b/game/network/rail.cpp index 545620d..d0a8bdd 100644 --- a/game/network/rail.cpp +++ b/game/network/rail.cpp @@ -159,8 +159,7 @@ namespace { if (auto count = networkLinks.vertices.size()) { shader.use(RAIL_CROSS_SECTION, RAIL_TEXTURE_POS); glBindVertexArray(networkLinks.vao); - glVertexArrayVertexBuffer( - networkLinks.vao, 0, networkLinks.vertices.bufferName(), 0, sizeof(typename LinkType::Vertex)); + networkLinks.vao.useBuffer(0, networkLinks.vertices); glDrawArrays(mode, 0, static_cast(count)); } }; -- cgit v1.3