forked from mia/Aegisub
Fix adding lead in/out in the timing postprocessor
The wrong set of lines were being checked for overlaps resulting in completely broken results. Originally committed to SVN as r6345.
This commit is contained in:
parent
2d3e505193
commit
e6252ae11b
1 changed files with 2 additions and 2 deletions
|
@ -354,10 +354,10 @@ void DialogTimingProcessor::Process() {
|
|||
for (size_t i = 0; i < sorted.size(); ++i) {
|
||||
AssDialogue *cur = sorted[i];
|
||||
if (addIn)
|
||||
cur->Start = safe_time(sorted.begin() + i + 1, sorted.end(), cur, cur->Start - leadIn, &AssDialogue::End, &std::max<int>);
|
||||
cur->Start = safe_time(sorted.rend() - i, sorted.rend(), cur, cur->Start - leadIn, &AssDialogue::End, &std::max<int>);
|
||||
|
||||
if (addOut)
|
||||
cur->End = safe_time(sorted.rend() - i, sorted.rend(), cur, cur->End + leadOut, &AssDialogue::Start, &std::min<int>);
|
||||
cur->End = safe_time(sorted.begin() + i + 1, sorted.end(), cur, cur->End + leadOut, &AssDialogue::Start, &std::min<int>);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue