Skip to content

Commit

Permalink
fix: batchRender last array cull funtion
Browse files Browse the repository at this point in the history
  • Loading branch information
lirongf committed Jan 10, 2023
1 parent c277701 commit 8a9a34f
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,12 @@ export class BatchRender extends BaseRender {
if (this._cacheLod == lod) {
return;
}

if(this._cacheLod == this.lodCullRateArray.length - 1)
{
lod = -1;
}

this._renderElements = this._lodInstanceRenderElement[lod];
if (this._lodInstanceRenderElement[lod] && lod != -1) {
this._renderElements || (this._renderElements = []);
Expand Down

0 comments on commit 8a9a34f

Please sign in to comment.