Skip to content

Commit

Permalink
Update CCRenderer.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
StarBeat authored Jun 29, 2020
1 parent dda7559 commit e3827d2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions cocos/renderer/CCRenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,7 @@ void Renderer::drawBatchedTriangles()

_triBatchesToDraw[batchesTotal].cmd = cmd;
_triBatchesToDraw[batchesTotal].indicesToDraw = (int) cmd->getIndexCount();

isValidMaterialID = true;
// is this a single batch ? Prevent creating a batch group then
if (!batchable)
isValidMaterialID = false;
Expand All @@ -615,7 +615,6 @@ void Renderer::drawBatchedTriangles()
}

prevMaterialID = currentMaterialID;
isValidMaterialID = true;
firstCommand = false;
}
batchesTotal++;
Expand Down

0 comments on commit e3827d2

Please sign in to comment.