From 8f84e67b7b9dcd4f5993909aa9ee2e222a207836 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Sun, 23 Apr 2023 20:56:49 +0100 Subject: Assert the buffer is actually mapped Will fail if the context is deleted. We shouldn't trigger that, but we do right now. --- gfx/gl/instanceVertices.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'gfx/gl/instanceVertices.h') diff --git a/gfx/gl/instanceVertices.h b/gfx/gl/instanceVertices.h index 228020d..8bb2f21 100644 --- a/gfx/gl/instanceVertices.h +++ b/gfx/gl/instanceVertices.h @@ -1,6 +1,7 @@ #pragma once #include "glArrays.h" +#include #include #include #include @@ -186,6 +187,7 @@ protected: { if (!data) { data = static_cast(glMapNamedBuffer(buffer, GL_READ_WRITE)); + assert(data); } } -- cgit v1.2.3