Newest 'ffmpeg' Questions - Stack Overflow

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

Les articles publiés sur le site

  • Loss of frames results in a memory leak in the FFmpeg H.264 decoder

    9 octobre 2013, par user2863509

    guys!

    I am using FFmpeg library 'avcodec' in my VOIP-application for decoding streaming video in H.264 format. Video stream is transmitted over the network via RTP. I am using function avcodec_decode_video2() to decode H.264 frames received from the network.

    I've used valgrind with tool 'massif' and found the memory leaks in the function avcodec_decode_video2().

    I've discovered that the leaks occur when there is a loss of RTP packets before receiving the first INTRA frame (keyframe). The leak is directly proportional to the time which passes from the moment the first call avcodec_decode_video2() until arrival of the next INTRA frame (keyframe).

    Question 1: Has anyone seen this behavior function avcodec_decode_video2()?

    Question 2: There is a suspicion that the decoder allocates memory for data and does not release it after the arrival of good keyframe. How to bring back the memory in heap?

    Thank all!

  • ffmpeg MAMP "dyld : Library not loaded" error

    9 octobre 2013, par benedict_w

    I am using ffmpeg on Mac OSX 10.7.3 in MAMP through PHP's exec() command, I have an absolute path set to call ffmpeg, e.g.

    /opt/local/bin/ffmpeg -i "/sample.avi"
    

    But I receive the following error -

    dyld: Library not loaded: /opt/local/lib/libjpeg.8.dylib  Referenced from: /opt/local/lib/libopenjpeg.1.dylib  Reason: Incompatible library version: libopenjpeg.1.dylib requires version 13.0.0 or later, but libJPEG.dylib provides version 12.0.0
    

    N.B. ffmpeg was installed through Macports.

    It works from the command line.

    What to do?

    EDIT

    I've reopened this - originally thought shell_exec() solved the issue, but infact it should be called differently - and I didn't realise until investigating further today. Here is my code using shell_exec and still giving the error above:

     $cmd = '/opt/local/bin/ffmpeg -h';
     $cmd = escapeshellcmd($cmd) . ' 2>&1';
     $output = shell_exec($cmd);
     var_dump($output);
    
  • m3u8 on ios and safari, firefox

    9 octobre 2013, par user2741735

    I'm implementing the HTTP Live Streaming protocol. I have successfully created .ts and .m3u8 files using ffmpeg and mediastreamsegmenter(using terminal) from IP Camera input. Now, when I play these files on ios using MPMoviePlayerViewController the m3u8 file doesn't play. Do I need to do some additional stuffs to play these files so that the simulator and browser could understand those file types.

  • Motion Vectors and DC coefficients from MPEG4 stream

    9 octobre 2013, par Lampis

    I need to extract information about motion vectors and DC coefficients from an MPEG4 video. I've searched relevant sites and topics and I found that a good solution is to work with the code of ffmpeg codec. Especially the ff_print_debug_info function in libavcodec/mpegvideo.c calculates relevant information.

    However, I'm new on the C/C++ field and if there is any example code that describes or explains how to extract MVs and DC coefficients that would be very helpful.

    In the more recent version I use (FFmpeg 0.10.2 from http://ffmpeg.org/download.html) there is another file mpeg4videodec.c. Is there any chance to retrieve the needed information by this code?

  • nobody can't exec ffmpeg command

    9 octobre 2013, par joaner

    I'm try to get the tag info from media file use ffmpeg. It work fine on system user xiaoai.

    // it should output the info, but nothing
    exec("/usr/bin/ffmpeg -i /home/xiaoai/music/Roar.mp3", $say, $code);
    var_dump($code); // code is 1, I know it's a error: Catchall for general errors.
    

    So I think about permission, my script run as nobody. I give the mp3 file 777 permission, /usr/bin/ffmpeg 777, and user change to nobody. but still not work.

    I must use this ffmpeg, this is only way for aac as i know, mp3, m4a, ogg. Please tell me how to do or other way.