diff options
Diffstat (limited to 'src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp')
-rw-r--r-- | src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp b/src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp index 83234bd32c..ecd450bcc8 100644 --- a/src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp +++ b/src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp @@ -1875,9 +1875,12 @@ void Renderer::uploadBatch(Batch *b) vd += g->sizeOfVertex(); } - const quint16 *id = (const quint16 *) (b->vbo.data - + b->vertexCount * g->sizeOfVertex() - + (b->merged ? b->vertexCount * sizeof(float) : 0)); + const quint16 *id = +#ifdef QSG_SEPARATE_INDEX_BUFFER + (const quint16 *) (b->ibo.data); +#else + (const quint16 *) (b->vbo.data + b->drawSets.at(0).indices); +#endif { QDebug iDump = qDebug(); iDump << " -- Index Data, count:" << b->indexCount; |