diff --git a/.gitignore b/.gitignore index 3b834c93f..945f21039 100644 --- a/.gitignore +++ b/.gitignore @@ -65,4 +65,4 @@ example/dev-bundle *.generated.js -build/** \ No newline at end of file +build/** diff --git a/src/core/build/geometryUtils.js b/src/core/build/geometryUtils.js index 8c8f1975d..d472d2d3d 100644 --- a/src/core/build/geometryUtils.js +++ b/src/core/build/geometryUtils.js @@ -84,7 +84,7 @@ export function getRootIndexRanges( geo, range ) { const ranges = []; const rangeBoundaries = new Set(); - const drawRange = range ? getRangesIntersection( geo.drawRange, range ) : geo.drawRange; // or we just want to use only 'range' also here? + const drawRange = range ? range : geo.drawRange; const drawRangeStart = drawRange.start / 3; const drawRangeEnd = ( drawRange.start + drawRange.count ) / 3; for ( const group of geo.groups ) { @@ -135,17 +135,3 @@ export function hasGroupGaps( geometry, range ) { return vertexCount !== total; } - - -export function getRangesIntersection( geoRange, customRange ) { - - const start = Math.max( geoRange.start, customRange.start ); - - return { - - start, - count: Math.min( geoRange.start + geoRange.count, customRange.start + customRange.count ) - start - - }; - -}