dont make trivial splits
parent
48961fee2a
commit
ccc4d7fbd2
|
|
@ -207,12 +207,14 @@ impl Inspection {
|
||||||
for i in 0..unstuck_spans.len() {
|
for i in 0..unstuck_spans.len() {
|
||||||
let mut span = unstuck_spans[i];
|
let mut span = unstuck_spans[i];
|
||||||
for split in scene_splits.iter() {
|
for split in scene_splits.iter() {
|
||||||
if &span.start < split && split < &span.stop { // TODO buffer
|
if &(span.start + 5.0) < split && split < &(span.stop - 5.0) { // TODO const
|
||||||
result.push(ContentSpan{start: span.start, stop: *split});
|
result.push(ContentSpan{start: span.start, stop: *split});
|
||||||
span.start = *split;
|
span.start = *split;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
result.push(span); // TODO assert nontrivial
|
if span.stop - span.start > 2.0 {
|
||||||
|
result.push(span);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
result
|
result
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue