Просмотр исходного кода

Merge pull request #535 from blackberry-gaming/next-kwhatmough

Remove unnecessary error when mesh batch is not indexed. Code review req...
Sean Paul Taylor 13 лет назад
Родитель
Сommit
32ad060b48
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      gameplay/src/MeshBatch.cpp

+ 1 - 1
gameplay/src/MeshBatch.cpp

@@ -114,7 +114,7 @@ bool MeshBatch::resize(unsigned int capacity)
     // (we only know how many indices will be stored). Assume the worst case
     // for now, which is the same number of vertices as indices.
     unsigned int indexCapacity = vertexCapacity;
-    if (indexCapacity > USHRT_MAX)
+    if (_indexed && indexCapacity > USHRT_MAX)
     {
         GP_ERROR("Index capacity is greater than the maximum unsigned short value (%d > %d).", indexCapacity, USHRT_MAX);
         return false;