Recherche avancée

Médias (2)

Mot : - Tags -/documentation

Autres articles (99)

  • Automated installation script of MediaSPIP

    25 avril 2011, par

    To overcome the difficulties mainly due to the installation of server side software dependencies, an "all-in-one" installation script written in bash was created to facilitate this step on a server with a compatible Linux distribution.
    You must have access to your server via SSH and a root account to use it, which will install the dependencies. Contact your provider if you do not have that.
    The documentation of the use of this installation script is available here.
    The code of this (...)

  • Les statuts des instances de mutualisation

    13 mars 2010, par

    Pour des raisons de compatibilité générale du plugin de gestion de mutualisations avec les fonctions originales de SPIP, les statuts des instances sont les mêmes que pour tout autre objets (articles...), seuls leurs noms dans l’interface change quelque peu.
    Les différents statuts possibles sont : prepa (demandé) qui correspond à une instance demandée par un utilisateur. Si le site a déjà été créé par le passé, il est passé en mode désactivé. publie (validé) qui correspond à une instance validée par un (...)

  • Que fait exactement ce script ?

    18 janvier 2011, par

    Ce script est écrit en bash. Il est donc facilement utilisable sur n’importe quel serveur.
    Il n’est compatible qu’avec une liste de distributions précises (voir Liste des distributions compatibles).
    Installation de dépendances de MediaSPIP
    Son rôle principal est d’installer l’ensemble des dépendances logicielles nécessaires coté serveur à savoir :
    Les outils de base pour pouvoir installer le reste des dépendances Les outils de développements : build-essential (via APT depuis les dépôts officiels) ; (...)

Sur d’autres sites (11384)

  • ffmpeg Problem with converting. ffmpeg converts image attachments to stream ? [closed]

    5 mars 2021, par For Fun

    I have a mp4 file with cover.jpg as attachments but when I use -c copy to convert to mkv the image won't stay as attachments ffmpeg changes it to stream 0:2 ?

    


    ffmpeg -i 'file.mp4' -c copy -map 0 'output.mkv' 


    


    Full Log : https://pastebin.com/raw/L9Ss3qbx

    


  • c/c++ program for ffmpeg command line

    25 mars 2015, par Yoohoo

    I want to find the corresponding c/c++ program for the ffmpeg command line :

    ffmpeg -i sample.mp4 -an -vcodec libx264 -crf 23 outfile.h264

    which convert a sample.mp4 file to outfile.h264, and

    ffplay outfile.h264

    What I am doing is to combine the ffmpeg program with my udp socket program to do a real-time video transmission. beacause it is ’real-time’, so I want to find the ffmpeg program cut it at the frame encoding step instead of writing the frames into output file, and send frame by frame and also read frame by frame at the server side.

    My questions are :

    1.What c/c++ program is actually running when I use the above command line ?

    2.where can i find the c/c++ program ?

  • Convert opencv mat frame to ffmpeg AVFrame

    1er avril 2015, par Yoohoo

    I am currently work on a c++ real-time video transmission project, now I am using opencv to capture the webcam, and I want to convert the opencv Mat to ffmepg AVFrame to do the encoding and write into buffer. At the decoder side, read packet from buffer, using ffmpeg decode, and then convert ffmpeg AVFrame to opencv Mat again and play.

    Now I have finished the opencv capturing, and I can encode v4l2 source with ffmpeg, but what I want to do is replace the v4l2 source with opencv Mat. But it get error in follow code (I just show the part of the conversion) :

       Mat opencvin;                    //frame from webcam
       cap.read(opencvin);

       Mat* opencvframe;
       opencvframe = &opencvin;
       AVFrame ffmpegout;
       Size frameSize = opencvframe->size();
       AVCodec *encoder = avcodec_find_encoder(AV_CODEC_ID_H264);
       AVFormatContext* outContainer = avformat_alloc_context();
       AVStream *outStream = avformat_new_stream(outContainer, encoder);
       avcodec_get_context_defaults3(outStream->codec, encoder);

       outStream->codec->pix_fmt = AV_PIX_FMT_YUV420P;
       outStream->codec->width = opencvframe->cols;
       outStream->codec->height = opencvframe->rows;
       avpicture_fill((AVPicture*)&ffmpegout, opencvframe->data, PIX_FMT_BGR24, outStream->codec->width, outStream->codec->height);
       ffmpegout.width = frameSize.width;
       ffmpegout.height = frameSize.height;

    This is a code I borrow from Internet, it seems the frame have already be encoded during conversion, before I use

    static AVCodecContext *c= NULL;

    c = avcodec_alloc_context3(codec);
    if (!c) {
       fprintf(stderr, "Could not allocate video codec context\n");
       exit(1);
    }
    c->bit_rate = 400000;
    /* resolution must be a multiple of two */
    c->width = 640;
    c->height = 480;
    /* frames per second */
    c->time_base= (AVRational){1,25};
    c->gop_size = 10; /* emit one intra frame every ten frames */
    c->max_b_frames=15;
    c->pix_fmt = AV_PIX_FMT_YUV420P;

    ret = avcodec_encode_video2(c, &pkt, &ffmpegout, &got_output);

    to encode the frame. And I get core dumped error if I continue encode the converted frame.

    I want encode the frame after conversion so that I can keep the data in pkt. How can I get a pure converted ffmpeg frame from opencv frame ?

    Or if the encode have already done during coversion, how can I get the output into pkt ?