Recherche avancée

Médias (0)

Mot : - Tags -/metadatas

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

Autres articles (60)

  • 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 ;

  • Mise à jour de la version 0.1 vers 0.2

    24 juin 2013, par

    Explications des différents changements notables lors du passage de la version 0.1 de MediaSPIP à la version 0.3. Quelles sont les nouveautés
    Au niveau des dépendances logicielles Utilisation des dernières versions de FFMpeg (>= v1.2.1) ; Installation des dépendances pour Smush ; Installation de MediaInfo et FFprobe pour la récupération des métadonnées ; On n’utilise plus ffmpeg2theora ; On n’installe plus flvtool2 au profit de flvtool++ ; On n’installe plus ffmpeg-php qui n’est plus maintenu au (...)

  • Soumettre améliorations et plugins supplémentaires

    10 avril 2011

    Si vous avez développé une nouvelle extension permettant d’ajouter une ou plusieurs fonctionnalités utiles à MediaSPIP, faites le nous savoir et son intégration dans la distribution officielle sera envisagée.
    Vous pouvez utiliser la liste de discussion de développement afin de le faire savoir ou demander de l’aide quant à la réalisation de ce plugin. MediaSPIP étant basé sur SPIP, il est également possible d’utiliser le liste de discussion SPIP-zone de SPIP pour (...)

Sur d’autres sites (10987)

  • OpenCV to ffplay from named pipe (fifo)

    13 juillet 2017, par Betsalel Williamson

    I’ve been working on piping video from OpenCV in C++. I’ve tried to pipe the image after processing from OpenCV to a named pipe with the end goal of republishing the stream using a webserver either with VLC or a NodeJS server.

    Where I’m stuck is that the output from OpenCV doesn’t seem to be processing correctly. The video always has artifacts even though it should be the raw video.

    enter image description here

    int main(int argc, char** argv)
    {

       VideoCapture camera(argv[1]);

       float fps = 15;

       // VLC raw video
       printf("Run command:\n\ncat /tmp/myfifo | cvlc --demux=rawvideo --rawvid-fps=%4.2f --rawvid-width=%.0f --rawvid-height=%.0f  --rawvid-chroma=RV24 - --sout \"#transcode{vcodec=h264,vb=200,fps=30,width=320,height=240}:std{access=http{mime=video/x-flv},mux=ffmpeg{mux=flv},dst=:8081/stream.flv}\""
           ,fps
           ,camera.get(CV_CAP_PROP_FRAME_WIDTH)
           ,camera.get(CV_CAP_PROP_FRAME_HEIGHT)
           );


       // ffplay raw video
       printf("Run command:\n\ncat /tmp/myfifo | ffplay -f rawvideo -pixel_format bgr24 -video_size %.0fx%.0f -framerate %4.2f -i pipe:"
           ,camera.get(CV_CAP_PROP_FRAME_WIDTH)
           ,camera.get(CV_CAP_PROP_FRAME_HEIGHT)
           ,fps
           );

       int fd;
       int status;

       char const * myFIFO = "/tmp/myfifo";

       if ((status = mkfifo(myFIFO, 0666)) < 0) {
           // printf("Fifo mkfifo error: %s\n", strerror(errno));
           // exit(EXIT_FAILURE);
       } else {
           cout << "Made a named pipe at: " << myFIFO << endl;
       }

       cout << "\n\nHit any key to continue after running one of the previously listed commands..." << endl;
       cin.get();

       if ((fd = open(myFIFO,O_WRONLY|O_NONBLOCK)) < 0) {
           printf("Fifo open error: %s\n", strerror(errno));
           exit(EXIT_FAILURE);
       }  

       while (true)
       {
           if (waitKey(1) > 0)
           {
               break;    
           }

           Mat colorImage;
           camera >> colorImage;

           // method: named pipe as matrix writes data to the named pipe, but image has glitch
           size_t bytes = colorImage.total() * colorImage.elemSize();

           if (write(fd, colorImage.data, bytes) < 0) {
               printf("Error in write: %s \n", strerror(errno));
           }            
       }

       close(fd);

       exit(EXIT_SUCCESS);
    }
  • All audios should be played after combing using ffmpeg. But there is only audio for the first part

    6 mai 2020, par Eric Z

    This code is combining 3 mp4 files using ffmpeg command. Each file has audio. 
After combining, I can listen audio for only first part. 
How can I solve this problem ?

    



    ===========================================================================

    



    ffmpeg -y -i "tmp/titled-0c33a83dc70534c67f66.mp4" -i "tmp/titled-1c2fc9a95e644ab135a3.mp4" -i "tmp/titled-73c3fb1a3ea435cacdd2.mp4" -i "logo/logo.png"  -filter_complex "
nullsrc=s=1280x720[bg];
[0:v]setpts=PTS-STARTPTS+0/TB[v0];
[1:v]setpts=PTS-STARTPTS+4.039/TB[v1];
[2:v]setpts=PTS-STARTPTS+8.078/TB[v2];
[bg][v0]overlay=x='if(lte(t,4.039),0,min(0,-w*min(1,max(0,0.98*(t-4.039)^2))))':y=0,trim=duration=13.145[bg];
[bg][v1]overlay=x='if(gte(t,8.078),-w*min(1,max(0,0.98*(t-8.078)^2)),max(0,1280*(1-min(1,max(0,0.69*(atan(8*(t-4.039)^2.7)))))))':y=0[bg];
[bg][v2]overlay=x='max(0,1280*(1-min(1,max(0,0.69*(atan(8*(t-8.078)^2.7))))))':y=0"
-y -vcodec h264 -crf 13 -acodec aac -strict -2 "out.mp4"


    


  • Segmentation fault when media played using libavcodec

    20 août 2013, par sarah john

    Myself trying to play media using libavcodec as backend.I downloaded ffmpeg-2.0.1 and installed using ./configure,make and make install.
    While trying to run an application to play an audio file, i'm getting segmentation fault while checking for the first audio stream.my program is like

    AVFormatContext* container = avformat_alloc_context();
    if (avformat_open_input(&container, input_filename, NULL, NULL) < 0) {
       die(“Could not open file”);
    }

    if (av_find_stream_info(container) < 0) {
       die(“Could not find file info”);
    }

    av_dump_format(container, 0, input_filename, false);
    int stream_id = -1;
    int i;

    for (i = 0; i < container->nb_streams; i++) {
       if (container->streams[i]->codec->codec_type==AVMEDIA_TYPE_AUDIO) {
           stream_id = i;
           break;
       }
    }

    Segmentation fault occurs at if(container->streams[i]->codec->codec_type==AVMEDIA_TYPE_AUDIO)

    How can i fix this ? I am working in ubuntu 12.04.