Open
Description
Hello,
I'm not 100% sure this is an issue with this library or if it's something else, but basically I am attempting to use the 'subtitles' filter by feeding it an mkv file, ffmpeg always crashes and when I printed the stream arguments I got the below:
['-i', "tes't.mkv", '-filter_complex', "[0]subtitles=tes\\\\\\\\\\\\\\'t.mkv[s0]", '-map', '[s0]', "tes't.mkv2.mkv"]
This is for a file called tes't.mkv
This is a script I recreated this with:
import ffmpeg
import sys
file_path = "tes't.mkv"
def convert_video(file_path):
#Create a stream
stream = ffmpeg.input(file_path)
#Apply subtitle filter
stream = ffmpeg.filter_(stream,'subtitles',str(file_path))
#Output file
stream = ffmpeg.output(stream, file_path + '2.mkv')
#Get to work
print(ffmpeg.get_args(stream))
convert_video(file_path)
If I attempt to run this stream then ffmpeg crashes with the below error:
[Parsed_subtitles_0 @ 0x5591972f24a0] Unable to open tes\'t.mkv
[AVFilterGraph @ 0x5591972cd1c0] Error initializing filter 'subtitles' with args 'tes\\\'t.mkv'
Error initializing complex filters.
No such file or directory
Traceback (most recent call last):
File "test.py", line 16, in <module>
convert_video(file_path)
File "test.py", line 14, in convert_video
ffmpeg.run(stream)
File "/home/baa/.local/lib/python3.6/site-packages/ffmpeg/_run.py", line 212, in run
raise Error('ffmpeg', out, err)
ffmpeg._run.Error: ffmpeg error (see stderr output for detail)
Metadata
Metadata
Assignees
Labels
No labels