Newest 'ffmpeg' Questions - Stack Overflow

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

Les articles publiés sur le site

  • Making changes on a video before a download [on hold]

    1er février 2016, par Chris Russo

    We have a website with lots of videos (>10,000) and lots of users (>50,000). Each video might be around 1,2 Gbs.

    The goal is to generate a unique video for each one of the members or users of the website making a small variation either on the audio track of the video, or the keyframes on the video itself, using low frequency beeps, or a few random pixels on specific keyframes.

    I understand that this operation can be done using SoX for the audio track, or FFmpeg in the case of the video, manipulating the keyframes.

    Here's my question, as we have to choose between 2 options at this point:

    In terms of resources: would it be convenient or even possible to generate in real time a clone of the video and make this variations at the moment that the user's request the download (please considerate the big volume of videos and users).

    Or it would be convenient to face this problem using HDD, pre-generating and storing the already manipulated videos ready to be served?

    I understand that storing all this data will require a few many Tera's but I'm not sure about how much RAM and Microprocessing could be demanded to perform this operations in real time, over videos that might be as big as 1Gbs.

  • Android, How to convert video into slow motion and play it in slow motion using FFmpeg

    1er février 2016, par Kishor Ramani

    In Android, How to convert video into slow motion and play it in slow motion using FFmpeg.

    I am using FFmpeg command :

    ffmpeg -i input.mkv -filter:v "setpts=2.0*PTS" output.mkv
    
    Link : https://trac.ffmpeg.org/wiki/How%20to%20speed%20up%20/%20slow%20down%20a%20video
    

    but i can't pass "setpts=2.0*PTS" command with Double Quote in String

        String cmd1 = "-i " + inputpath.mp4 + " " + "-filter:v" + " " 
    + "setpts=0.5*PTS"  
    + " " +
    Environment.getExternalStorageDirectory().getAbsolutePath() + "/hij.mp4";
    

    if you have any better solution for converting video into slow motion or fast motion then it will be appreciated.

    Thanks.

  • How to read ffmpeg response from java and use it to create a progress bar ?

    1er février 2016, par shalki

    I am working on creating a progress bar for ffmpeg in java. So for that I need to execute a command, then read all of the progress:

    String[] command = {"gnome-terminal", "-x", "/bin/sh", "-c","ffmpeg -i /home/tmp/F.webm /home/tmp/converted1.mp4"};
    
    Process process = Runtime.getRuntime().exec(command);
    

    This runs perfectly. However, I need to capture the all of the progress to make a progress bar. So how can I read that data from java?

  • how to add text over video using ffmpeg in android

    1er février 2016, par android_beginner

    I am working on a video - editing app where user can add text/images, trim video,etc. and to implement this i have decided to use ffmpeg. The problem now is i do not have much idea on how to implement the same in my app as it seems bit difficult. Can any one help over this with the easiest way possible?

  • FFmpeg on android with libX264 and libfreetype

    1er février 2016, par LostPuppy

    I previously had a ffmpeg build with just the x264 library and now I have re-complied ffmpeg with x264 and libfreetype. I used the guardian project and used the following script

    #!/bin/bash
    
    . abi_settings.sh $1 $2 $3
    
    pushd ffmpeg
    
    case $1 in
      armeabi-v7a | armeabi-v7a-neon)
        CPU='cortex-a8'
      ;;
      x86)
        CPU='i686'
      ;;
    esac
    
    make clean
    
    ./configure \
    --target-os=linux \
    --arch=arm \
    --cross-prefix="$CROSS_PREFIX" \
    --cpu="$CPU" \
    --sysroot="$NDK_SYSROOT" \
    --enable-encoder=mpeg4 \
    --enable-pic \
    --enable-libx264 \
    --enable-libfreetype \
    --enable-pthreads \
    --enable-version3 \
    --enable-gpl \
    --disable-doc \
    --disable-shared \
    --enable-static \
    --pkg-config="${2}/ffmpeg-pkg-config" \
    --prefix="${2}/build/${1}" \
    --extra-cflags='-I/usr/local/include' \
    --extra-ldflags='-L/usr/local/lib'\
    
    make -j${NUMBER_OF_CORES} && make install || exit 1
    
    popd
    

    I am observing that the new build is taking almost double the time to process videos on android device when compared with previous versions.

    Any suggestions on speeding up the binary ?