Newest 'ffmpeg' Questions - Stack Overflow

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

Les articles publiés sur le site

  • Audio output with video processing with opencv

    22 février 2012, par victor1234

    I am processing video with opencv, but at the same time I need to play audio and simply control it, like loud or current frame number.

    I think I should create a parallel process with ffmpeg, but I don't know how to do so. Can you explain what to do?

    Or do you know another solution?

  • Find video resolution and video duration of remote mediafile

    22 février 2012, par osgx

    I want to write an program which can find some metainformation of mediafile. I'm interested in popular video formats, such as avi, mkv, mp4, mov (may be other popular too). I want basically to get:

    • Video size (720, 1080, 360 etc)
    • Total runtime of video (may be not very exact)
    • Number of audio streams
    • Name of video codec
    • Name of audio codec

    There is already the mediainfo, but in my program I want to get information about remote file, which may be accessed via ftp, http, samba; or even torrent (there are some torrent solutions, which allows to read not-yet downloaded file).

    MediaInfo library have no support of samba (smb://) and mkv format (for runtime).

    Also, I want to know, how much data should be downloaded to get this information. I want not to download full videofile because I have no enough disk space.

    Is this information in the first 1 or 10 or 100 KiloBytes of the file? Is it at predictable offset if I know the container name and total file size?

    PS: Platform is Linux, Language is C/C++

  • FFMpeg on Android : Streaming HTTP audio stream

    21 février 2012, par ebarch

    I'm having an issue being able to open streams with FFMpeg on Android. I downloaded the FFMpeg code from http://bambuser.com/opensource and compiled it without any issues. I tried adding --enable-protocol=http to the build options and then wrote some test JNI to setup the stream.

    When calling av_open_input_file with the URL to a valid HTTP MP3 stream, I'm always receiving -2 (No such file or directory) back as the error code. I've seen other projects that use this method to open streams, so I'm thinking it has to do with my FFMpeg build.

    Any help would be greatly appreciated!

  • grab_image is not working for HD videos ?

    21 février 2012, par user1222769

    I am using ffmpeg command for grab_image of converted videos which are in flv format. All videos images are created except for HD videos. The code which i have written is as follws. Thanks in advance.

    
    function grab_image($filename, $rootpath, $inputpath,$outputpath, $no_of_thumbs, $frame_number, $image_format, $width, $height)
    
    
        $_rootpath = $rootpath."\ffmpeg";
        // Media Size
        $size = $width."x".$height;
    
        // I am using static image, you can dynamic it with your own choice.
        $out=explode(".",$filename);
    
        $outfile = $out[0].".jpg";
    
        //$ffmpegcmd1="ffmpeg -i ".$inputpath."/".$filename." -ss 1.4 -vframes 1 -f image2 ". $outputpath."/".$outfile;
    
            // in local
    
               $ffmpegcmd1="D:/xampp/htdocs/abc/ffmpeg -i ".$inputpath."/".$filename." -r 1 -ss 1.4 -vframes 1 -f image2 ". $outputpath."/".$outfile;
        $ret = exec($ffmpegcmd1);
    
        // Execute this command using exec command or any other tool to grab image from converted flv file.
        return $ffmpegcmd1;
    }
    
    
  • How do I make a video with a static image background in FFMPEG ?

    21 février 2012, par Tim Scollick

    I have an image. I have a transparent FLV. I want to use the image as a background to the transparent FLV and have it outputted as FLV.

    This command works but the video is one frame long:

    ffmpeg -i background.png -f flv -vcodec flv -b 1500k -vf "movie=test_videos/alpha.flv [logo]; [in][logo] overlay=0:0 [out]" -s 800x464 -y output.flv
    

    I have tried to use the -t and -vframes parameters to no avail.

    Does anyone have any tips?