Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


FFmpeg cannot burn-in subs on some videos?
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

FFmpeg cannot burn-in subs on some videos?

sgno1sgno1 Member

I'm not sure what the issue is but it works fine on Handbrake, but breaks on FFmpeg, this command works for sure since I have burned in subs with the same command just a few hours before.

Subtitles definitely exist since it worked with Handbrake pretty fine!

ffmpeg -i '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv' -map 0:v -map 0:2 -acodec aac -crf 21 -preset veryfast -filter_complex subtitles="'/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv':si=1" '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv/test.mp4'

[1;32m[Parsed_subtitles_0 @ 0x55ae5b7c12c0] [0mShaper: FriBidi 0.19.7 (SIMPLE) > HarfBuzz-ng 1.7.2 (COMPLEX)
[0;35m[matroska,webm @ 0x55ae5b7bda00] [0m[0;33mCould not find codec parameters for stream 3 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
Consider increasing the value for the 'analyzeduration' and 'probesize' options
[0m[0;35m[matroska,webm @ 0x55ae5b7bda00] [0m[0;33mCould not find codec parameters for stream 4 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
Consider increasing the value for the 'analyzeduration' and 'probesize' options
[0m[1;32m[Parsed_subtitles_0 @ 0x55ae5b7c12c0] [0mUsing font provider fontconfig
[1;32m[Parsed_subtitles_0 @ 0x55ae5b7c12c0] [0m[1;31mOnly text based subtitles are currently supported
[0m[1;32m[AVFilterGraph @ 0x55ae5b7e7440] [0m[1;31mError initializing filter 'subtitles'[0m[1;31m with args '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv:si=1'[0m[1;31m
[0m[4;31mError initializing complex filters.
[0m[4;31mNot yet implemented in FFmpeg, patches welcome
[0m

Comments

  • sgno1sgno1 Member

    @sgno1 said:
    I'm not sure what the issue is but it works fine on Handbrake, but breaks on FFmpeg, this command works for sure since I have burned in subs with the same command just a few hours before.

    Subtitles definitely exist since it worked with Handbrake pretty fine!

    ffmpeg -i '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv' -map 0:v -map 0:2 -acodec aac -crf 21 -preset veryfast -filter_complex subtitles="'/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv':si=1" '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv/test.mp4'

    [1;32m[Parsed_subtitles_0 @ 0x55ae5b7c12c0] [0mShaper: FriBidi 0.19.7 (SIMPLE) > HarfBuzz-ng 1.7.2 (COMPLEX)
    [0;35m[matroska,webm @ 0x55ae5b7bda00] [0m[0;33mCould not find codec parameters for stream 3 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
    Consider increasing the value for the 'analyzeduration' and 'probesize' options
    [0m[0;35m[matroska,webm @ 0x55ae5b7bda00] [0m[0;33mCould not find codec parameters for stream 4 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
    Consider increasing the value for the 'analyzeduration' and 'probesize' options
    [0m[1;32m[Parsed_subtitles_0 @ 0x55ae5b7c12c0] [0mUsing font provider fontconfig
    [1;32m[Parsed_subtitles_0 @ 0x55ae5b7c12c0] [0m[1;31mOnly text based subtitles are currently supported
    [0m[1;32m[AVFilterGraph @ 0x55ae5b7e7440] [0m[1;31mError initializing filter 'subtitles'[0m[1;31m with args '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv:si=1'[0m[1;31m
    [0m[4;31mError initializing complex filters.
    [0m[4;31mNot yet implemented in FFmpeg, patches welcome
    [0m

    Running this on Ubuntu 18!

  • TomzTomz Member

    ffmpeg -probesize 1M -analyzeduration 1M -i '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv' -map 0:v -map 0:2 -acodec aac -crf 21 -preset veryfast -filter_complex subtitles="'/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv':si=1" '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv/test.mp4'

  • CidloxCidlox Member

    Use HandBrake 4head 😘

  • @Cidlox said:
    just use HandBrake image

    FTFY

  • sgno1sgno1 Member

    @Tomz said:
    ffmpeg -probesize 1M -analyzeduration 1M -i '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv' -map 0:v -map 0:2 -acodec aac -crf 21 -preset veryfast -filter_complex subtitles="'/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv':si=1" '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv/test.mp4'

    [1;32m[Parsed_subtitles_0 @ 0x557aafd13400] [0mShaper: FriBidi 0.19.7 (SIMPLE) HarfBuzz-ng 1.7.2 (COMPLEX) [0;35m[matroska,webm @ 0x557aafd0fb40] [0m[0;33mCould not find codec parameters for stream 3 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size Consider increasing the value for the 'analyzeduration' and 'probesize' options [0m[0;35m[matroska,webm @ 0x557aafd0fb40] [0m[0;33mCould not find codec parameters for stream 4 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size Consider increasing the value for the 'analyzeduration' and 'probesize' options [0m[1;32m[Parsed_subtitles_0 @ 0x557aafd13400] [0mUsing font provider fontconfig [1;32m[Parsed_subtitles_0 @ 0x557aafd13400] [0m[1;31mOnly text based subtitles are currently supported [0m[1;32m[AVFilterGraph @ 0x557aafd700c0] [0m[1;31mError initializing filter 'subtitles'[0m[1;31m with args '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv:si=1'[0m[1;31m [0m[4;31mError initializing complex filters. [0m[4;31mNot yet implemented in FFmpeg, patches welcome [0m

    Same thing

  • sgno1sgno1 Member
    edited June 2021

    @sgno1 said:

    @Tomz said:
    ffmpeg -probesize 1M -analyzeduration 1M -i '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv' -map 0:v -map 0:2 -acodec aac -crf 21 -preset veryfast -filter_complex subtitles="'/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv':si=1" '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv/test.mp4'


    [1;32m[Parsed_subtitles_0 @ 0x557aafd13400] [0mShaper: FriBidi 0.19.7 (SIMPLE) HarfBuzz-ng 1.7.2 (COMPLEX)
    [0;35m[matroska,webm @ 0x557aafd0fb40] [0m[0;33mCould not find codec parameters for stream 3 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
    Consider increasing the value for the 'analyzeduration' and 'probesize' options
    [0m[0;35m[matroska,webm @ 0x557aafd0fb40] [0m[0;33mCould not find codec parameters for stream 4 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
    Consider increasing the value for the 'analyzeduration' and 'probesize' options
    [0m[1;32m[Parsed_subtitles_0 @ 0x557aafd13400] [0mUsing font provider fontconfig
    [1;32m[Parsed_subtitles_0 @ 0x557aafd13400] [0m[1;31mOnly text based subtitles are currently supported
    [0m[1;32m[AVFilterGraph @ 0x557aafd700c0] [0m[1;31mError initializing filter 'subtitles'[0m[1;31m with args '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv:si=1'[0m[1;31m
    [0m[4;31mError initializing complex filters.
    [0m[4;31mNot yet implemented in FFmpeg, patches welcome
    [0m

    Same thing

  • jmgcaguiclajmgcaguicla Member
    edited June 2021

    Try dumping the subtitle streams from the previous videos that you managed to successfully encoded to check what format they are.

    My guess would be your ffmpeg version doesn't support or has trouble with pgs subs and am guessing that the previous videos you encoded successfully had a different sub format.

  • sgno1sgno1 Member
    edited June 2021

    @jmgcaguicla said:
    Try dumping the subtitle streams from the previous videos that you managed to successfully encoded to check what format they are.

    My guess would be your ffmpeg version doesn't support or has trouble with pgs subs and am guessing that the previous videos you encoded successfully had a different sub format.

    Trying out this, might work since it's encoding:

    ffmpeg -i '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mkv' -map 0:v -map 0:2 -filter_complex '[0:v:0][0:4]overlay' -acodec copy -crf 21 -sn '/root/temp/.todo/some-sample-test-folder-here-one-two/test.mp4'

    Although, it didn't let me exactly specify where to get the subtitle like the previous command, so I'm not exactly sure if it will work.

    EDIT: Worked

Sign In or Register to comment.