[FFmpeg-user] Subtitle filter and filename with quotes and spaces
kouta84 at gmail.com
kouta84 at gmail.com
Tue May 13 21:28:29 CEST 2014
Hi can someone try if this works?
for me, on Windows works.
::remove quotes
::for /f "useback tokens=*" %%a in ('%2') do set SubString=%%~a
set SubString=%2
::first escape
set SubString=%SubString:\=\\%
set SubString=%SubString::=\:%
set SubString=%SubString:'=\'%
::second escape
set SubString=%SubString:\=\\%
set SubString=%SubString:'=\'%
set SubString=%SubString:[=\[%
set SubString=%SubString:]=\]%
set SubString=%SubString:,=\,%
set SubString=%SubString:;=\;%
::third escape
::set SubString=%SubString:\=\\%
%~dp0ffmpeg.exe -i %1 -c:v libx264 -vf subtitles=filename=%SubString% -strict -2 -c:a aac "%~n1_test.mp4"
More information about the ffmpeg-user
mailing list