Recherche avancée

Médias (1)

Mot : - Tags -/publier

Autres articles (89)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;

  • Creating farms of unique websites

    13 avril 2011, par

    MediaSPIP platforms can be installed as a farm, with a single "core" hosted on a dedicated server and used by multiple websites.
    This allows (among other things) : implementation costs to be shared between several different projects / individuals rapid deployment of multiple unique sites creation of groups of like-minded sites, making it possible to browse media in a more controlled and selective environment than the major "open" (...)

  • Ecrire une actualité

    21 juin 2013, par

    Présentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
    Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
    Vous pouvez personnaliser le formulaire de création d’une actualité.
    Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)

Sur d’autres sites (8787)

  • (FFMPEG Error)Real-time buffer [USB cam's name] too full or near too full

    9 juin 2020, par ZzangWoo

    I am doing project about making rtsp stream of my USB Camera.
And my project environment is 
- OS : windows server 2019
- CPU : AMD Ryzen 7 3700X
- RAM : 64GB
- GPU : NVIDIA GeForce RTX 2070 SUPER

    



    My project goal is to detect object with YOLO and show original cam video, detected video to client. So I need to change my USB Camera to RTSP Stream. But I had an error below picture.
enter image description here

    



    And this is my command line.

    



    ffmpeg -re -f dshow -i video="JOYTRON HD20" -pix_fmt yuv420p -vsync 1 -threads 0 -vcodec libx264 -r 30 -g 60 -sc_threshold 0 -b:v 640k -bufsize 768k -maxrate 800k -preset veryfast -profile:v baseline -tune film -acodec aac -b:a 128k -ac 2 -ar 48000 -f rtsp rtsp ://localhost:8888/test

    



    I saw an answer that the problem is bandwidth. So I added parameter. It didnt help.

    



    I also added the -rtbufsize parameter and -thread_queue_size parameter. But it didnt help anything.

    



    What should I do ??

    


  • Memory leak when using av_frame_get_buffer()

    19 juillet 2018, par Alec Matthews

    I am making a simple video player with ffmpeg. I have noticed that there is a memory leak originating in libavutil. Because ffmpeg is a mature library I assume that I am allocating a new frame incorrectly. The documentation is also vague about freeing the buffer that is created when you call av_frame_get_buffer(). Below is the code I am using to decode the video and queue it up for display on the UI thread.

    DWORD WINAPI DecoderThread(LPVOID lpParam)
    {
       AVFrame *frame = NULL;
       AVPacket pkt;

       SwsContext *swsCtx = NULL;
       UINT8 *buffer = NULL;
       INT iNumBytes = 0;

       INT result = 0;

       frame = av_frame_alloc();

       av_init_packet(&pkt);
       pkt.data = NULL;
       pkt.size = 0;

       // Create scaling context
       swsCtx = sws_getContext(codecCtx->width, codecCtx->height, codecCtx->pix_fmt, codecCtx->width, codecCtx->height, AV_PIX_FMT_BGR24, SWS_BICUBIC, NULL, NULL, NULL);

      while (av_read_frame(fmtCtx, &pkt) >= 0) {
           if (pkt.stream_index == videoStream) {
               result = avcodec_send_packet(codecCtx, &pkt);

               while (result >= 0) {
                   result = avcodec_receive_frame(codecCtx, frame);
                   if (result == AVERROR(EAGAIN) || result == AVERROR_EOF) {
                       break;
                   } else if (result < 0) {
                       // another error.
                   }
                   // Create a new frame to store the RGB24 data.
                   AVFrame *pFrameRGB = av_frame_alloc();
                   // Allocate space for the new RGB image.
                   //av_image_alloc(pFrameRGB->data, pFrameRGB->linesize, codecCtx->width, codecCtx->height, AV_PIX_FMT_BGR24, 1);
                   // Copy all of the properties from the YUV420P frame.
                   av_frame_copy_props(pFrameRGB, frame);
                   pFrameRGB->width = frame->width;
                   pFrameRGB->height = frame->height;
                   pFrameRGB->format = AV_PIX_FMT_BGR24;
                   av_frame_get_buffer(pFrameRGB, 0);

                   // Convert fram from YUV420P to BGR24 for display.
                   sws_scale(swsCtx, (const UINT8* const *) frame->data, frame->linesize, 0, codecCtx->height, pFrameRGB->data, pFrameRGB->linesize);

                   // Queue thr BGR frame for drawing by the main thread.
                   AddItemToFrameQueue(pFrameRGB);

                   av_frame_unref(frame);
               }
           }
          while (GetQueueSize() > 100) {
               Sleep(10);
          }
      }

       CloseFrameQueue();

       av_frame_free(&frame);
      avcodec_close(codecCtx);
      avformat_close_input(&fmtCtx);

       return 0;
    }

    Is there a better way to allocate a new frame for holding the post sws_scale() transformation ?

    There is a similar stackoverflow question that uses mostly depreciated function calls. I can’t seem to find any answers that conform to the new version of ffmpeg in the documentation. Any help would be appreciated.

  • avformat/segafilmenc : Postpone check for existence of video stream

    14 janvier 2020, par Andreas Rheinhardt
    avformat/segafilmenc : Postpone check for existence of video stream
    

    Up until now, the Sega FILM muxer complained if the first stream wasn't a
    video stream that there is no video stream at all which is of course
    nonsense. So postpone this check.

    Signed-off-by : Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
    Signed-off-by : Michael Niedermayer <michael@niedermayer.cc>

    • [DH] libavformat/segafilmenc.c