Add checks for zero indexes on fill patterns to match fills. (#1638)
Co-authored-by: Bart Louwers <bart@emeel.net> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
@@ -210,10 +210,12 @@ void DrawableGL::upload(gfx::UploadPass& uploadPass) {
|
||||
|
||||
if (!glSeg.getVertexArray().isValid()) {
|
||||
auto vertexArray = glContext.createVertexArray();
|
||||
IndexBufferGL& indexBuffer = *static_cast<IndexBufferGL*>(impl->indexes->getBuffer());
|
||||
const auto& indexBuffer = static_cast<IndexBufferGL&>(*impl->indexes->getBuffer());
|
||||
vertexArray.bind(glContext, *indexBuffer.buffer, bindings);
|
||||
assert(vertexArray.isValid());
|
||||
glSeg.setVertexArray(std::move(vertexArray));
|
||||
if (vertexArray.isValid()) {
|
||||
glSeg.setVertexArray(std::move(vertexArray));
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user