Browse Source

[cpp] Fixed asserts in Atlas.cpp.

badlogic 7 years ago
parent
commit
307230259e
1 changed files with 8 additions and 8 deletions
  1. 8 8
      spine-cpp/spine-cpp/src/spine/Atlas.cpp

+ 8 - 8
spine-cpp/spine-cpp/src/spine/Atlas.cpp

@@ -134,15 +134,15 @@ void Atlas::load(const char *begin, int length, const char *dir) {
 			/* size is only optional for an atlas packed with an old TexturePacker. */
 			page->width = toInt(tuple);
 			page->height = toInt(tuple + 1);
-			assert(readTuple(&begin, end, tuple));
+			readTuple(&begin, end, tuple);
 
 			page->format = (Format) indexOf(formatNames, 8, tuple);
 
-			assert(readTuple(&begin, end, tuple));
+			readTuple(&begin, end, tuple);
 			page->minFilter = (TextureFilter) indexOf(textureFilterNames, 8, tuple);
 			page->magFilter = (TextureFilter) indexOf(textureFilterNames, 8, tuple + 1);
 
-			assert(readValue(&begin, end, &str));
+			readValue(&begin, end, &str);
 
 			page->uWrap = TextureWrap_ClampToEdge;
 			page->vWrap = TextureWrap_ClampToEdge;
@@ -170,14 +170,14 @@ void Atlas::load(const char *begin, int length, const char *dir) {
 			region->page = page;
 			region->name = String(mallocString(&str), true);
 
-			assert(readValue(&begin, end, &str));
+			readValue(&begin, end, &str);
 			region->rotate = equals(&str, "true") ? true : false;
 
-			assert(readTuple(&begin, end, tuple) == 2);
+			readTuple(&begin, end, tuple);
 			region->x = toInt(tuple);
 			region->y = toInt(tuple + 1);
 
-			assert(readTuple(&begin, end, tuple) == 2);
+			readTuple(&begin, end, tuple);
 			region->width = toInt(tuple);
 			region->height = toInt(tuple + 1);
 
@@ -213,7 +213,7 @@ void Atlas::load(const char *begin, int length, const char *dir) {
 					region->pads[2] = toInt(tuple + 2);
 					region->pads[3] = toInt(tuple + 3);
 
-					assert(readTuple(&begin, end, tuple));
+					readTuple(&begin, end, tuple);
 				}
 			}
 
@@ -224,7 +224,7 @@ void Atlas::load(const char *begin, int length, const char *dir) {
 			region->offsetX = (float)toInt(tuple);
 			region->offsetY = (float)toInt(tuple + 1);
 
-			assert(readValue(&begin, end, &str));
+			readValue(&begin, end, &str);
 
 			region->index = toInt(&str);