diff --git a/src/Text/Renderer.cpp b/src/Text/Renderer.cpp index 09f98c970..9b112e40e 100644 --- a/src/Text/Renderer.cpp +++ b/src/Text/Renderer.cpp @@ -176,11 +176,11 @@ std::pair, Mesh::IndexType> renderIndicesIntern Containers::Array indices; Mesh::IndexType indexType; - if(vertexCount < 255) { + if(vertexCount <= 256) { indexType = Mesh::IndexType::UnsignedByte; indices = Containers::Array(indexCount*sizeof(UnsignedByte)); createIndices(indices, glyphCount); - } else if(vertexCount < 65535) { + } else if(vertexCount <= 65536) { indexType = Mesh::IndexType::UnsignedShort; indices = Containers::Array(indexCount*sizeof(UnsignedShort)); createIndices(indices, glyphCount);