shouldn't this return false?
also now that I think about it, I am not sure x_delta can ever be 0. It would only be 0 if the beyond key and the reference key are the same, which they cannot be since you are getting different indices.
Hm ok writing this now, you can have the curve in a state where two keys are at the same point in time. Shouldn't happen, but could...
Anyway, the function should return true if it ran and false if it didn't. Since you are exiting early here, I think it should return false.
shouldn't this return false?
also now that I think about it, I am not sure x_delta can ever be 0. It would only be 0 if the beyond key and the reference key are the same, which they cannot be since you are getting different indices.
Hm ok writing this now, you can have the curve in a state where two keys are at the same point in time. Shouldn't happen, but could...
Anyway, the function should return true if it ran and false if it didn't. Since you are exiting early here, I think it should return false.
This would be clearer if you checked explicitly to 0
segment->start_index == 0
the start index will never be smaller than 0
I am glad you didn't listen to me here, because I just realized what I suggested is wrong 🤦