Various smaller improvements
All checks were successful
KnarCraft/FFmpegConvert/pipeline/head This commit looks good

Improves Signs & Songs subtitle RegEx
Adds tests for the Signs & Songs subtitle RegEx
Automatically changes "enm" language to English
Makes the downscale converter select HEVC if the input is HEVC
This commit is contained in:
2024-06-07 15:46:51 +02:00
parent 1dc489a6f8
commit 1ceb378757
6 changed files with 93 additions and 4 deletions

View File

@ -1,5 +1,6 @@
package net.knarcraft.ffmpegconverter.streams;
import net.knarcraft.ffmpegconverter.utility.SubtitleHelper;
import org.jetbrains.annotations.NotNull;
import java.util.Map;
@ -50,8 +51,7 @@ public class SubtitleStream extends AbstractStream implements StreamObject {
* @return <p>True if the subtitle translates everything.</p>
*/
private boolean checkIfIsFullSubtitle() {
return !getTitle().toLowerCase().trim().matches(".*si(ng|gn)s?[ &/a-z+]+(songs?)?([$ @-]+.*)?|" +
".*songs?[ &/a-z]+(si(gn|ng)s?)?([$ @-]+.*)?|.*forced.*|.*s&s.*|songs($| |-|@)+|si(gn|ng)s($| |-|@)+");
return !SubtitleHelper.isSongsSignsSubtitle(this.getTitle());
}
@Override