Last active
November 4, 2022 21:48
-
-
Save Alucard316/dc95ebed0e975304416896b86ffbdc7e to your computer and use it in GitHub Desktop.
Windows DVR PostProcess Batch Script for Jellyfin
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
:: This is the simplest batch script known to man. | |
:: Takes the unplayable ts_mpeg file from a recorded Live TV program in Windows-Jellyfin and outputs it to h264 mkv, then removes the Transport Stream (NOT Typescript XD) file. | |
:: This goes in my base Jellyfin folder, sitting alongside the "system" directory per the wiki recommendation for hosting jellyfin on windows. | |
:: To enable in Jellyfin, navigate to Admin Dashboard->DVR->Select this script file under Post-processing application, and leave the default CLI argument of "{path}" (WITH the quotes). | |
:: To increase output quality, lower the -crf value and/or change the -preset value to slow or veryslow. Raise the value and change preset to medium or fast for smaller files. | |
:: All thanks goes to thornbill and his linux script | |
set WORKDIR=%~d1%~p1 | |
set STARTDIR=%CD% | |
%~d1 | |
cd %WORKDIR% | |
"%STARTDIR%\system\ffmpeg.exe" -i "%~nx1" -c:v libx264 -vf yadif=parity=auto -crf 20 -preset medium -max_muxing_queue_size 1024 -c:a aac -map 0:0 -map 0:1 -async 1 "%~n1.mkv" | |
del "%~nx1" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment