From b26b292b02a9cfcbacf81eafec33ed6aed1a0f53 Mon Sep 17 00:00:00 2001 From: bkaradzic Date: Sat, 23 Mar 2013 16:04:45 -0700 Subject: [PATCH] Added check for stride/vertex size. --- src/renderer_d3d11.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/renderer_d3d11.cpp b/src/renderer_d3d11.cpp index 1415ef14c..68774abd8 100644 --- a/src/renderer_d3d11.cpp +++ b/src/renderer_d3d11.cpp @@ -1272,6 +1272,7 @@ namespace bgfx float m_z; uint32_t m_abgr; } * vertex = (Vertex*)m_vb->data; + BX_CHECK(stride == sizeof(Vertex), "Stride/Vertex mismatch (stride %d, sizeof(Vertex) %d)", stride, sizeof(Vertex) ); const uint32_t abgr = bx::endianSwap(_clear.m_rgba); const float depth = _clear.m_depth;