It wasn't obvious this can be used for calculating the triangle index from the polygon and loop index.