reverseIndicesSingleFacet MethodStatic
Reverse the indices for the specified facet in the specified index array.
- Parameterized over type T so non-number data (e.g., boolean visibility flags) can be reversed.
reverseIndicesSingleFacet<T>(facetIndex: number, facetStartIndex: number[], indices: T[], preserveStart: boolean): boolean
| Parameter | Type | Description | 
|---|---|---|
| facetIndex | number | index of the facet to reverse. The entries of indicesto be reversed are found atfacetStartIndex[facetIndex] <= i < facetStartIndex[facetIndex + 1]. | 
| facetStartIndex | number[] | start indices of consecutive facets, e.g., an IndexedPolyface's _facetStart array. See reverseIndices. | 
| indices | T[] | the index array, e.g., pointIndex, normalIndex, etc. | 
| preserveStart | boolean | trueto preserve the start index of each facet (e.g., facet [1,2,3,4] becomes [1,4,3,2]);falseto reverse all indices (e.g., facet [1,2,3,4] becomes [4,3,2,1]). | 
Returns - boolean
Defined in
- polyface/PolyfaceData.ts Line 699
Last Updated: 29 October, 2025
Found something wrong, missing, or unclear on this page? Raise an issue in our repo.