Recherche avancée

Médias (0)

Mot : - Tags -/médias

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (29)

  • La sauvegarde automatique de canaux SPIP

    1er avril 2010, par

    Dans le cadre de la mise en place d’une plateforme ouverte, il est important pour les hébergeurs de pouvoir disposer de sauvegardes assez régulières pour parer à tout problème éventuel.
    Pour réaliser cette tâche on se base sur deux plugins SPIP : Saveauto qui permet une sauvegarde régulière de la base de donnée sous la forme d’un dump mysql (utilisable dans phpmyadmin) mes_fichiers_2 qui permet de réaliser une archive au format zip des données importantes du site (les documents, les éléments (...)

  • Script d’installation automatique de MediaSPIP

    25 avril 2011, par

    Afin de palier aux difficultés d’installation dues principalement aux dépendances logicielles coté serveur, un script d’installation "tout en un" en bash a été créé afin de faciliter cette étape sur un serveur doté d’une distribution Linux compatible.
    Vous devez bénéficier d’un accès SSH à votre serveur et d’un compte "root" afin de l’utiliser, ce qui permettra d’installer les dépendances. Contactez votre hébergeur si vous ne disposez pas de cela.
    La documentation de l’utilisation du script d’installation (...)

  • 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 (...)

Sur d’autres sites (6212)

  • Decoding H.264 individual nal units

    24 septembre 2018, par madprogrammer2015

    I am currently sending individual NAL units across a network. These NAL units are generated by x264. Now is it possible to feed these NAL units individually into avcodec_decode_video2 ?

    Or do I have to concatenate the nal units until they represent the same frame ? If thats the case then how is that done ?

    I have also read that I might be able to receive the SPS and PPS packets. Then wait for at least one packet, and attempt to decode. Is this correct ?

    Any advice that can be offered would be greatly appreciated

  • ffprobe only shows a single stream

    19 novembre 2018, par marchaos

    I’ve got a webcam that is capable of 1080p. Under windows I can choose a 1080p 2mbps and all works well. When using ffprobe, it only shows a single 640x480 stream. If you use ffmpeg copy, it only records at 640x480.

    Is there a way to get it to record at the full 1080p ?

  • Convert individual pixel values from RGB to YUV420 and save the frame - C++

    24 mars 2014, par learner

    I have been working with RGB->YUV420 conversion for sometime using the FFmpeg library. Already tried the sws_scale functionality but its not working well. Now, I have decided to convert each pixel individually, using colorspace conversion formulae. So, following is the code that gets me few frames and allows me to access individual R,G,B values of each pixel :

    // Read frames and save first five frames to disk
       i=0;
       while((av_read_frame(pFormatCtx, &packet)>=0) && (i<5))
       {
           // Is this a packet from the video stream?
           if(packet.stream_index==videoStreamIdx)
           {  
               /// Decode video frame            
               avcodec_decode_video2(pCodecCtx, pFrame, &frameFinished, &packet);

               // Did we get a video frame?
               if(frameFinished)
               {
                   i++;
                   sws_scale(img_convert_ctx, (const uint8_t * const *)pFrame->data,
                             pFrame->linesize, 0, pCodecCtx->height,
                             pFrameRGB->data, pFrameRGB->linesize);

                   int x, y, R, G, B;
                   uint8_t *p = pFrameRGB->data[0];
                   for(y = 0; y < h; y++)
                   {  
                       for(x = 0; x < w; x++)
                       {
                           R = *p++;
                           G = *p++;
                           B = *p++;
                           printf(" %d-%d-%d ",R,G,B);
                       }
                   }

                   SaveFrame(pFrameRGB, pCodecCtx->width, pCodecCtx->height, i);
               }
           }

           // Free the packet that was allocated by av_read_frame
           av_free_packet(&packet);
       }

    I read online that to convert RGB->YUV420 or vice-versa, one should first convert to YUV444 format. So, its like : RGB->YUV444->YUV420. How do I implement this in C++ ?

    Also, here is the SaveFrame() function used above. I guess this will also have to change a little since YUV420 stores data differently. How to take care of that ?

    void SaveFrame(AVFrame *pFrame, int width, int height, int iFrame)
    {
       FILE *pFile;
       char szFilename[32];
       int  y;

       // Open file
       sprintf(szFilename, "frame%d.ppm", iFrame);
       pFile=fopen(szFilename, "wb");
       if(pFile==NULL)
           return;

       // Write header
       fprintf(pFile, "P6\n%d %d\n255\n", width, height);

       // Write pixel data
       for(y=0; ydata[0]+y*pFrame->linesize[0], 1, width*3, pFile);

       // Close file
       fclose(pFile);
    }

    Can somebody please suggest ? Many thanks !!!