Skip to content

Commit d47c40d

Browse files
committed
Keyframe::GetDelta() removed unused loop and variables
1 parent 5f7766e commit d47c40d

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

src/KeyFrame.cpp

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -479,9 +479,7 @@ double Keyframe::GetDelta(int64_t index)
479479
if (index >= 1 && (index + 1) < Values.size()) {
480480
int64_t current_value = GetLong(index);
481481
int64_t previous_value = 0;
482-
int64_t next_value = 0;
483482
int64_t previous_repeats = 0;
484-
int64_t next_repeats = 0;
485483

486484
// Loop backwards and look for the next unique value
487485
for (std::vector<Coordinate>::iterator backwards_it = Values.begin() + index; backwards_it != Values.begin(); backwards_it--) {
@@ -495,18 +493,6 @@ double Keyframe::GetDelta(int64_t index)
495493
}
496494
}
497495

498-
// Loop forwards and look for the next unique value
499-
for (std::vector<Coordinate>::iterator forwards_it = Values.begin() + (index + 1); forwards_it != Values.end(); forwards_it++) {
500-
next_value = long(round((*forwards_it).Y));
501-
if (next_value == current_value) {
502-
// Found same value
503-
next_repeats++;
504-
} else {
505-
// Found non repeating value, no more repeats found
506-
break;
507-
}
508-
}
509-
510496
// Check for matching previous value (special case for 1st element)
511497
if (current_value == previous_value)
512498
previous_value = 0;

0 commit comments

Comments
 (0)