Recherche avancée

Médias (1)

Mot : - Tags -/ticket

Autres articles (111)

  • Demande de création d’un canal

    12 mars 2010, par

    En fonction de la configuration de la plateforme, l’utilisateur peu avoir à sa disposition deux méthodes différentes de demande de création de canal. La première est au moment de son inscription, la seconde, après son inscription en remplissant un formulaire de demande.
    Les deux manières demandent les mêmes choses fonctionnent à peu près de la même manière, le futur utilisateur doit remplir une série de champ de formulaire permettant tout d’abord aux administrateurs d’avoir des informations quant à (...)

  • Diogene : création de masques spécifiques de formulaires d’édition de contenus

    26 octobre 2010, par

    Diogene est un des plugins ? SPIP activé par défaut (extension) lors de l’initialisation de MediaSPIP.
    A quoi sert ce plugin
    Création de masques de formulaires
    Le plugin Diogène permet de créer des masques de formulaires spécifiques par secteur sur les trois objets spécifiques SPIP que sont : les articles ; les rubriques ; les sites
    Il permet ainsi de définir en fonction d’un secteur particulier, un masque de formulaire par objet, ajoutant ou enlevant ainsi des champs afin de rendre le formulaire (...)

  • Les formats acceptés

    28 janvier 2010, par

    Les commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
    ffmpeg -codecs ffmpeg -formats
    Les format videos acceptés en entrée
    Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
    Les formats vidéos de sortie possibles
    Dans un premier temps on (...)

Sur d’autres sites (4328)

  • Installing faad library for ffmpeg through Homebrew on mac OS X Lion

    14 décembre 2011, par alex

    Following up with my previous question, I decided to give Ffmpeg a try and installed it on my Mac with Homebrew.

    I am now trying to follow this tutorial and use the linked script. But can't make/install the script. I first corrected a small bug (replaced CODEC_TYPE_AUDIO, CODEC_TYPE_VIDEO and PKT_FLAG_KEY with AVMEDIA_TYPE_AUDIO, AVMEDIA_TYPE_VIDEO, and AV_PKT_FLAG_KEY respectively in live_segmenter.c). But now, when I run make in the unzipped folder, I get the following warning and error messages :

    gcc -Wall -g live_segmenter.c -o live_segmenter -lavformat -lavcodec -lavutil -lbz2 -lm -lz -lfaac -lmp3lame -lx264 -lfaad -lpthread
    live_segmenter.c: In function ‘main’:
    live_segmenter.c:149: warning: ‘av_open_input_file’ is deprecated (declared at /usr/local/include/libavformat/avformat.h:1093)
    live_segmenter.c:165: warning: implicit declaration of function ‘guess_format’
    live_segmenter.c:165: warning: initialization makes pointer from integer without a cast
    live_segmenter.c:208: warning: ‘av_set_parameters’ is deprecated (declared at /usr/local/include/libavformat/avformat.h:1407)
    live_segmenter.c:214: warning: ‘dump_format’ is deprecated (declared at /usr/local/include/libavformat/avformat.h:1535)
    live_segmenter.c:232: warning: ‘url_fopen’ is deprecated (declared at /usr/local/include/libavformat/avio.h:279)
    live_segmenter.c:238: warning: ‘av_write_header’ is deprecated (declared at /usr/local/include/libavformat/avformat.h:1465)
    live_segmenter.c:283: warning: ‘put_flush_packet’ is deprecated (declared at /usr/local/include/libavformat/avio.h:293)
    live_segmenter.c:284: warning: ‘url_fclose’ is deprecated (declared at /usr/local/include/libavformat/avio.h:280)
    live_segmenter.c:289: warning: ‘url_fopen’ is deprecated (declared at /usr/local/include/libavformat/avio.h:279)
    live_segmenter.c:326: warning: ‘url_fclose’ is deprecated (declared at /usr/local/include/libavformat/avio.h:280)
    ld: library not found for -lfaad
    collect2: ld returned 1 exit status
    make: *** [all] Error 1

    I also downloaded the faac/faad libraries from here. When I run make in faac, it says I have nothing to install, but I can't find out how to install faad...

    Would love any help you can offer !

  • Getting video metadata in ruby script using ffmpeg, ffprobe or rvideo

    24 janvier 2013, par alex

    I want to get metadata of videos referenced by a URL using Ruby. At this point, I found many related posts, but could not find out how to solve my problem.

    I tried to use RVideo, but when I do :

    file = RVideo::Inspector.new(:file => 'http://www.agreatsite.com/avideo.mp4' ;)

    It throws

    'ArgumentError : File not found (http://www.agreatsite.com/avideo.mp4)...

    So I can't get the information using RVideo (but it works well when I have the file hosted on my local computer).

    I then tried to use ffprobe, but I don't know how to read the output.
    So far, I have the following method, which "shows" the information I want when I run it in the console, but it actually returns "true" and I can't find out how to capture the output I need...

     def media_info
       source = self
       command = <<-end_command
         ffprobe -v quiet -print_format json -show_format -show_streams  #{source}
       end_command
       command.gsub!(/\s+/, " ")
       system(command)
     end

    Would love some help, to make this work with either ffprobe or RVideo !

    UPDATE :
    I found a way to get what I needed. Not sure this is the best way to do it :

    def get_media_duration

    source = self.media[0][:url]    

    command = <<-end_command
     ffprobe -v quiet  -show_streams  #{source}
    end_command
    command.gsub!(/\s+/, " ")

    duration = ""
    IO.popen(command) { |io| while (line = io.gets) do
                           puts "++ "+line.inspect
                           duration = line.split("duration=")[1].gsub("\n", "") if line.split("duration=").length > 1
                         end
                     }
    duration  

    end

    I guess I could make it work that way, but doesn't seem very elegant to me. Better suggestions would be greatly appreciated !

  • encapsulating H.264 streams variable framerate in MPEG2 transport stream

    2 mai 2012, par user1058600

    Imagine I have H.264 AnxB frames coming in from a real-time conversation. What is the best way to encapsulate in MPEG2 transport stream while maintaining the timing information for subsequent playback ?

    I am using libavcodec and libavformat libraries. When I obtain pointer to object (*pcc) of type AVCodecContext, I set the foll.

    pcc->codec_id = CODEC_ID_H264;
    pcc->bit_rate = br;
    pcc->width = 640;
    pcc->height = 480;
    pcc->time_base.num = 1;
    pcc->time_base.den = fps;

    When I receive NAL units, I create a AVPacket and call av_interleaved_write_frame().

    AVPacket pkt;
    av_init_packet( &pkt );
    pkt.flags |= AV_PKT_FLAG_KEY;  
    pkt.stream_index = pst->index;
    pkt.data = (uint8_t*)p_NALunit;
    pkt.size = len;

    pkt.dts = AV_NOPTS_VALUE;
    pkt.pts = AV_NOPTS_VALUE;

    av_interleaved_write_frame( fc, &pkt );

    I basically have two questions :

    1) For variable framerate, is there a way to not specify the foll.
    pcc->time_base.num = 1 ;
    pcc->time_base.den = fps ;
    and replace it with something to indicate variable framerate ?

    2) While submitting packets, what "timestamps" should I assign to
    pkt.dts and pkt.pts ?

    Right now, when I play the output using ffplay it is playing at constant framerate (fps) which I use in the above code.

    I also would love to know how to accommodate varying spatial resolution. In the stream that I receive, each keyframe is preceded by SPS and PPS. I know whenever the spatial resolution changes.
    IS there a way to not have to specify
    pcc->width = 640 ;
    pcc->height = 480 ;
    upfront ? In other words, indicate that the spatial resolution can change mid-stream.

    Thanks a lot,
    Eddie