Newest 'ffmpeg' Questions - Stack Overflow

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

Les articles publiés sur le site

  • ffserver maps audio to stream 0:0, I think thats why it play only audio in output

    26 février 2014, par user3355301

    Hello am new to ffserver, I have installed ffmpeg on my centos server (FFmpeg version 0.6.5, Copyright (c) ) and started the ffserver, but when I send a stream to http://xxx.xxx.xxx.xxx:8090/feed1.ffm it maps

    audio as

    "Stream #0.0, 0, 1/1000000: Audio: libfaac, 48000 Hz, 2 channels, s16, 31 kb/s"

    and video on

    "Stream #0.1, 0, 1/1000000: Video: mpeg4, yuv420p, 1920x816, 1001/24000, q=2-31, 1000k tbn, 23.98 tbc"

    then when I stream this with xxx.xxx.xxx.xxx:8090/test1.mpg I only get audio and no video.

    please is this mapping incorrect or have I read it wrong.

    my command ffmpeg -loglevel debug -i /home/avi/Terminator\ 2.avi -vcodec copy -acodec copy -b 128k http://xxx.xxx.xxx.xxx:8090/feed1.ffm

    Output #0, ffm, to 'xxx.xxx.xxx.xxx:8090/feed1.ffm':

    Metadata:

    encoder         : Lavf52.64.2
    Stream #0.0, 0, 1/1000000: Audio: ac3, 48000 Hz, 5.1, 640 kb/s
    Stream #0.1, 0, 1/1000000: Video: mpeg4, yuv420p, 1920x816, 1001/24000, q=2-31, 1000k tbn, 23.98 tbc
    
  • how to use ffmpeg to do video compression in android [duplicate]

    26 février 2014, par user963241

    This question already has an answer here:

    I tried to compile the ffmpeg to shared library to android

    where can i find the jni ffmpeg sample code to reduce the video size? thanks.

  • h264 lossless settings in c

    26 février 2014, par Squid

    I am currently trying to apply lossless H264 settings for FFMPEG in c. However, I am unsure as to what the settings need to be to ensure lossless encoding and I have found little documentation in this area.

    My current settings are:

        codecContex->coder_type = 1; 
        codecContex->flags|=CODEC_FLAG_LOOP_FILTER;
        codecContex->flags2|=CODEC_FLAG2_BPYRAMID-CODEC_FLAG2_WPRED-CODEC_FLAG2_8X8DCT;
    
        codecContex->profile=FF_PROFILE_H264_BASELINE;
        codecContex->scenechange_threshold = 40; 
        codecContex->gop_size=40;
        codecContex->max_b_frames=0;
        codecContex->max_qdiff=4;
        codecContex->me_method=10;
        codecContex->me_range=16;
        codecContex->me_cmp|= 1;
        codecContex->me_subpel_quality = 5; 
        codecContex->qmin=0; 
        codecContex->qmax=0;
        codecContex->qcompress=0.6f;
        codecContex->keyint_min=25;
        codecContex->trellis=0;
        codecContex->level=13;
        codecContex->refs = 16;
        codecContex->weighted_p_pred = 2;
        codecContex->b_frame_strategy= 1;
        codecContex->color_range = libffmpeg::AVCOL_RANGE_JPEG;
        codecContex->coder_type = FF_CODER_TYPE_AC;
        codecContex->crf = 0;
    

    Any ideas as to what they should be to ensure lossless encoding? Thanks in advance.

  • How to determine video rotation using ffmpeg

    26 février 2014, par Co-Gia

    I have built library ffmpeg successfully for Android. Now I want to use it to determine video rotation. How can I do that. Could you help me?

    Many thanks for reading and help.

  • Streaming flv video via avserver

    26 février 2014, par Yuvraj Kakkar

    While streaming flv file to avserver.
    Steps followed are :-
    1. Configured avserver by command on ubuntu terminal.
    * gedit /etc/avserver.conf
    * Added the content as below :-

    
    File            /tmp/live1.ffm
    FileMaxSize     1G
    
    
          
       Feed live1.ffm             
        Format flv
        VideoCodec libx264
        VideoFrameRate 30
        VideoBitRate 800
        VideoSize 720x576  
        AVOptionVideo crf 23
        AVOptionVideo preset medium
        AVOptionVideo me_range 16
        AVOptionVideo qdiff 4
        AVOptionVideo qmin 10
        AVOptionVideo qmax 51
        AVOptionVideo flags +global_header
        AudioCodec aac
        Strict -2
        AudioBitRate 128
        AudioChannels 2
        AudioSampleRate 22050
        AVOptionAudio
     flags +global_header
    
    


    2. Stream flv file to live1.ffm using avconv tool by following command -

    avconv -i /home/Videos/abc.flv  http://127.0.0.1:8090/live1.ffm
    

    3.Play live.flv stream via avplay tool .

     avplay http://127.0.0.1:8090/live.flv
    

    But at 3rd step getting error

    [flv @ 0x7f9b840008c0] decoding for stream 0 failed
    [flv @ 0x7f9b840008c0] Estimating duration from bitrate, this may be inaccurate
    http://127.0.0.1:8090/live.flv: could not find codec parameters
    

    4.I tried to download flv video via url http://127.0.0.1:8090/live.flv.It gets downloaded with 0 bytes and gives error - Error stream contains no data.

    Kindly provide suggestion on this. Thanks in advance.