mirror of
https://github.com/love2d/love.git
synced 2026-08-20 04:30:09 +02:00
Allow drawing a Mesh that has no VertexPosition attribute, if it has custom attributes.
This commit is contained in:
@@ -634,8 +634,8 @@ void Mesh::drawInternal(Graphics *gfx, const Matrix4 &m, int instancecount, Buff
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Not supported on all platforms or GL versions, I believe.
|
// Not supported on all platforms or GL versions, I believe.
|
||||||
if (!attributes.isEnabled(ATTRIB_POS))
|
if ((attributes.enableBits & ~(ATTRIBFLAG_TEXCOORD | ATTRIBFLAG_COLOR)) == 0)
|
||||||
throw love::Exception("Mesh must have an enabled VertexPosition attribute to be drawn.");
|
throw love::Exception("Mesh must have an enabled VertexPosition or custom attribute to be drawn.");
|
||||||
|
|
||||||
Graphics::TempTransform transform(gfx, m);
|
Graphics::TempTransform transform(gfx, m);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user