mirror of
https://github.com/gabehf/Tdarr_Plugins.git
synced 2026-03-09 07:29:04 -07:00
Merge pull request #529 from HaveAGitGat/parser_update
Add better estimates for 2 pass hb encoding
This commit is contained in:
commit
82b61eb4d9
2 changed files with 12 additions and 0 deletions
|
|
@ -21,6 +21,12 @@ var handbrakeParser = function (_a) {
|
|||
percentage = outputNum;
|
||||
}
|
||||
}
|
||||
if (str.includes('task 1 of 2')) {
|
||||
percentage /= 2;
|
||||
}
|
||||
else if (str.includes('task 2 of 2')) {
|
||||
percentage = 50 + (percentage / 2);
|
||||
}
|
||||
return percentage;
|
||||
};
|
||||
exports.handbrakeParser = handbrakeParser;
|
||||
|
|
|
|||
|
|
@ -28,6 +28,12 @@ const handbrakeParser = ({
|
|||
}
|
||||
}
|
||||
|
||||
if (str.includes('task 1 of 2')) {
|
||||
percentage /= 2;
|
||||
} else if (str.includes('task 2 of 2')) {
|
||||
percentage = 50 + (percentage / 2);
|
||||
}
|
||||
|
||||
return percentage;
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue