Newest 'ffmpeg' Questions - Stack Overflow

http://stackoverflow.com/questions/tagged/ffmpeg

Les articles publiés sur le site

  • FFMPEG filter_complex wih speedup and subtitles and scaling

    11 décembre 2015, par Sambir

    Hi I am trying to convert a file to a specific framerate and remove any jittering, jumping of the screen. I also try to boost the volume and add a subtitle overlay. I get an error with the curent line than it is not allowed to use complex_filter in combination with vf and af. as an extra I also would like to add text in the left corner (this i did not try yet) and would want the screen to be sized to full hd (changed scale to 1920:1080 but no succes).

    ffmpeg -i movie.mp4 -r 25 -filter_complex "[0:v]setpts=0.959*PTS[v];[0:a]atempo=1.0427[a]" -map "[v]" -map "[a]" -vf subtitles=sub.srt,scale=1920:1080 -af volume=2 -strict -2 -preset veryfast movie_new.mp4
    

    Got it!

    New:

    ffmpeg -i inside.mp4 -r 25 -filter_complex "[0:v]setpts=0.959*PTS[i];[i]scale=1920:1080[j];[j]subtitles=inside.srt[k];[0:a]atempo=1.0427[p];[p]volume=2[q]" -map "[k]" -map "[q]" -strict -2 -preset veryfast inside_new.mp4
    

    But now there is a new issue. Subs out of sync :P is there a easy fix for this or do i first need to encode without subs then resync then encode with subs?

    found this link by the way Subtitle Resync Tool

    moviespeed is changed by 0.959. is there a calculation i can do to adjust the subtitles by x miliseconds?

    EDIT: Got the subtitles fixed with subtitle workshop. Was just a small setting to change which directly shifted all the text :)

  • HTML to video converter

    11 décembre 2015, par frodeborli

    I want to use html and JavaScript to render graphics that is then exported to a video format. There are already tools that take html and generate images by using WebKit, but are there any scriptable tools that can take an html file and generate a video?

    Obviously there should be JavaScript commands to start recording and stop recording.

    Perhaps ffmpeg?

  • FFMPEG Crash c0000005 ?

    11 décembre 2015, par TTGroup

    I'm using FFMPEG to decode H264 Stream from IP Camera.

    Sometime It crash with the info as the following image

    enter image description here

    I'm using FFMPEG code very much in the program, so I cannot relocate which code caused this crash.

    Someone can tell me which case that may be caused this crash.

  • Windows Batch-File to execute n other batch-files in parallel

    11 décembre 2015, par Jos

    I use ffmpeg to convert video files. The codec I'm encoding with is single-threaded. There are a lot of video files to convert, so instead of using multithreaded encoding I can simply encode multiple video files with 1 thread each.

    To automate the encoding I use the follow commands in a .bat:

    SET maindir=%~dp0
    FOR /r /d %%f in (*) do pushd "%%f" & Call %maindir%convert-with-ffmpeg.bat & popd
    

    This calls "convert-with-ffmpeg.bat" sequentially`to convert each file/folder in the main dir.

    What would my .bat file have to look like if I want to do this in parallel (say, 12 times) until there are no more folders left to process?

    EDIT: Let me be clear that I want to LIMIT the amount of running processes at 12. When a .bat is done, I want the main .bat to start a new process until all files are converted (100+).

  • What is the best way to implement ffmpeg for mp3 compression with php on the fly ? [on hold]

    11 décembre 2015, par Akash Bose

    I am trying to compress mp3 files to 92 kbps on the fly when a user uploads a mp3 file. It looks like conversion takes my 35% of CPU for a single file. So if three conversion process happens together it takes my entire CPU recourse. i am using the following command:

    $cmd = 'ffmpeg -i ' . $mp3path . ' -ab 92k ' . $smp3path . '.mp3';
    exec($cmd);