Newest 'ffmpeg' Questions - Stack Overflow

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

Les articles publiés sur le site

  • extracting h264 raw video stream from mp4 or flv with ffmpeg generate an invalid stream

    10 octobre 2013, par neo2006

    I'm trying to extract the video stream from an mp4 or flv h264 video (youtube video) using ffmpeg. The original video (test.flv) play without trouble with ffplay , ffprobe gives an error as follow:

    ffprobe version N-55515-gbbbd959 Copyright (c) 2007-2013 the FFmpeg developers
    built on Aug 13 2013 18:06:32 with gcc 4.7.3 (GCC)
    configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-av
    isynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enab
    le-iconv --enable-libass --enable-libbluray --enable-libcaca --enable-libfreetyp
    e --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --ena
    ble-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-l
    ibopus --enable-librtmp --enable-libschroedinger --enable-libsoxr --enable-libsp
    eex --enable-libtheora --enable-libtwolame --enable-libvo-aacenc --enable-libvo-
    amrwbenc --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxavs --
    enable-libxvid --enable-zlib
      libavutil      52. 42.100 / 52. 42.100
      libavcodec     55. 27.100 / 55. 27.100
      libavformat    55. 13.102 / 55. 13.102
      libavdevice    55.  3.100 / 55.  3.100
      libavfilter     3. 82.100 /  3. 82.100
      libswscale      2.  4.100 /  2.  4.100
      libswresample   0. 17.103 /  0. 17.103
      libpostproc    52.  3.100 / 52.  3.100
    [flv @ 000000000031ea80] Stream discovered after head already parsed
    Input #0, flv, from 'test.flv':
      Metadata:
        starttime       : 0
        totalduration   : 142
        totaldatarate   : 692
        bytelength      : 12286492
        canseekontime   : true
        sourcedata      : B42B95507HH1381414522145462
        purl            :
        pmsg            :
      Duration: 00:02:22.02, start: 0.000000, bitrate: 692 kb/s
        Stream #0:0: Video: h264 (Main), yuv420p, 640x268, 568 kb/s, 23.98 tbr, 1k t
    bn, 47.95 tbc
        Stream #0:1: Audio: aac, 44100 Hz, stereo, fltp, 131 kb/s
        Stream #0:2: Data: none
    Unsupported codec with id 0 for input stream 2
    

    to get rid of the extra streams ( I only needs the video) I used the following ffmpeg command line:

    ffmpeg -i test.flv -map 0:0 -vcodec copy -an -f h264 test.h264
    

    The new stream is unreadable by any player including ffplay and gives an error with ffprobe : test.h264: Invalid data found when processing inputq= 0B f=0/0

    Any body have an idea about what am I doing wrong?

    I also tried simpler youtube command line:

    ffmpeg -i test.flv -vcodec copy -an test.h264
    

    if I use another format (avi for example):

    ffmpeg -i test.flv -vcodec copy -an test.avi
    

    the output video is valid.

    If I transcode the video

    ffmpeg -i test.flv -an test.h264
    

    the output is also valid

    Any suggestions?

  • How to get video thumbnail in PHP ? [on hold]

    10 octobre 2013, par assaf

    I am trying to get a thumbnail from an uploaded videos to my site, but I don't really know how to do this.

    I read that FFMPEG is the tool for this kind of actions, but I didn't understand how do I use this tool, is this a plugin? Do I need to install it?

    I really need help here and the detailed kind, thanks!

  • Is there a way using FFmpeg or software that would allow a user to upload a video with audio muted, but download the video with the audio rencoded ?

    10 octobre 2013, par user2868184

    Here is the background:

    I am looking to start a video sharing site that would allow artists to upload their original dance choreography. The problem is that while the choreography is original, the music most likely won't be. I would like the user to be able to upload the video with the sound muted, but once it's downloaded the sound would return. I am looking to host this on a WordPress site but is there a way using FFmpeg or a plug-in that would accomplish this? I am a very novice programmer but I would like to to be able to suggest a solution to a plugin developer.

    This would also allow me to display and play multiple videos on a page without having all of the audio overlap one another. Thanks in advance for your help!!!

  • how to convert stream to new stream with redrawing frames [on hold]

    10 octobre 2013, par DevellMen

    I have stream from my IP-camera (rtsp). I need to re-draw each frame using a special algorithm and build a new stream to my site. Algorithm is written in C + + and C # and works with image Bitmap. I can convert stream to images and images to stream using FFMPEG, but I can't:

    get frame from stream -> /convert frame using my algoritm/ -> join new image to new stream.

  • How to do HTML 5 video with Flash-free fallback for IE 8

    10 octobre 2013, par forthrin

    I need a simple and clean Flash-free, cross-browser solution for embedding video in a Web page. I came up with the solution below, and wish to hear if someone can improve it even further, including:

    1. Can the method show a still image while buffering the video?
    2. Can someone verify those conditional comments? downlevel-hidden and downlevel-revealed got me a bit confused :)

    Video converting as follows (using WMV for IE 8, WEBM for Firefox, and H264 for the rest):

    ffmpeg -i video.mov -b 3000k -vcodec wmv2   -acodec wmav2     -ab 320k -g 30 out.wmv
    ffmpeg -i video.mov -b 3000k -vcodec libvpx -acodec libvorbis -ab 320k -g 30 out.webm
    

    Markup (using conditional comments to create a fallback to IE 8 users):