PDollar-Unity
PDollar-Unity copied to clipboard
IndexOutOfRangeException: Index was outside the bounds of the array.
Reproduce this error by performing a gesture which has only 1 point. The error comes from this line [1] when the index value is -1. After further investigation I found out that creating a gesture via new Gesture(Points) will return a gesture with an array points initialized with NaN values.
[1] https://github.com/DaVikingCode/PDollar-Unity/blob/43f069d4aab9dd5013bc630fdfbe8056e36bda35/Assets/PDollar/Scripts/PDollarGestureRecognizer/PointCloudRecognizer.cs#L148