Recherche avancée

Médias (91)

Autres articles (70)

  • Support de tous types de médias

    10 avril 2011

    Contrairement à beaucoup de logiciels et autres plate-formes modernes de partage de documents, MediaSPIP a l’ambition de gérer un maximum de formats de documents différents qu’ils soient de type : images (png, gif, jpg, bmp et autres...) ; audio (MP3, Ogg, Wav et autres...) ; vidéo (Avi, MP4, Ogv, mpg, mov, wmv et autres...) ; contenu textuel, code ou autres (open office, microsoft office (tableur, présentation), web (html, css), LaTeX, Google Earth) (...)

  • MediaSPIP v0.2

    21 juin 2013, par

    MediaSPIP 0.2 est la première version de MediaSPIP stable.
    Sa date de sortie officielle est le 21 juin 2013 et est annoncée ici.
    Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
    Comme pour la version précédente, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
    Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...)

  • Les tâches Cron régulières de la ferme

    1er décembre 2010, par

    La gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
    Le super Cron (gestion_mutu_super_cron)
    Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...)

Sur d’autres sites (4717)

  • Image sequence to video stream ?

    22 août 2015, par Hauns TM

    Like many people already seem to have (there are several threads on this subject here) I am looking for ways to create video from a sequence of images.

    I want to implement my functionality in C# !

    Here is what I wan’t to do :

    /*Pseudo code*/
    void CreateVideo(List<image> imageSequence, long durationOfEachImageMs, string outputVideoFileName, string outputFormat)
    {
       // Info: imageSequence.Count will be > 30 000 images
       // Info: durationOfEachImageMs will be &lt; 300 ms

       if (outputFormat = "mpeg")
       {
       }
       else if (outputFormat = "avi")
       {      
       }
       else
       {
       }

       //Save video file do disk
    }
    </image>

    I know there’s a project called Splicer (http://splicer.codeplex.com/) but I can’t find suitable documentation or clear examples that I can follow (these are the examples that I found).

    The closest I want to do, which I find here on CodePlex is this :
    How can I create a video from a directory of images in C# ?

    I have also read a few threads about ffmpeg (for example this : C# and FFmpeg preferably without shell commands ? and this : convert image sequence using ffmpeg) but I find no one to help me with my problem and I don’t think ffmpeg-command-line-style is the best solution for me (because of the amount of images).

    I believe that I can use the Splicer-project in some way (?).

    In my case, it is about about > 30 000 images where each image should be displayed for about 200 ms (in the videostream that I want to create).

    (What the video is about ? Plants growing ...)

    Can anyone help me complete my function ?

  • GStreamer : How to set "stream-number" pad property of mpegtsmux element ? [closed]

    8 novembre 2024, par TishSerg

    Accroding to gst-inspect-1.0 mpegtsmux, mpegtsmux's sink pads have writable stream-number property :

    &#xA;

    ...&#xA;Pad Templates:&#xA;  SINK template: &#x27;sink_%d&#x27;&#xA;    Availability: On request&#xA;    Capabilities:&#xA;      ...&#xA;    Type: GstBaseTsMuxPad&#xA;    Pad Properties:&#xA;      ...&#xA;&#xA;      stream-number       : stream number&#xA;                            flags: readable, writable&#xA;                            Integer. Range: 0 - 31 Default: 0&#xA;

    &#xA;

    But when I try to set it, GStreamer says there's no such property. The following listing shows I can run multi-stream pipeline without setting that property, but when I add that property it doesn't work.

    &#xA;

    PS C:\gstreamer\1.0\msvc_x86_64\bin> ./gst-launch-1.0 mpegtsmux name=mux ! udpsink host=192.168.144.255 port=5600 sync=no `&#xA;>> videotestsrc is-live=true pattern=ball ! "video/x-raw, width=1920, height=1080, profile=main" ! x264enc ! mux.sink_300 `&#xA;>> videotestsrc is-live=true ! "video/x-raw, width=720, height=576" ! x264enc ! mux.sink_301&#xA;Use Windows high-resolution clock, precision: 1 ms&#xA;Setting pipeline to PAUSED ...&#xA;Pipeline is live and does not need PREROLL ...&#xA;Pipeline is PREROLLED ...&#xA;Setting pipeline to PLAYING ...&#xA;New clock: GstSystemClock&#xA;Redistribute latency...&#xA;Redistribute latency...&#xA;Redistribute latency...&#xA;handling interrupt.9.&#xA;Interrupt: Stopping pipeline ...&#xA;Execution ended after 0:00:03.773243400&#xA;Setting pipeline to NULL ...&#xA;Freeing pipeline ...&#xA;PS C:\gstreamer\1.0\msvc_x86_64\bin> ./gst-launch-1.0 mpegtsmux name=mux sink_300::stream-number=1 ! udpsink host=192.168.144.255 port=5600 sync=no `&#xA;>> videotestsrc is-live=true pattern=ball ! "video/x-raw, width=1920, height=1080, profile=main" ! x264enc ! mux.sink_300 `&#xA;>> videotestsrc is-live=true ! "video/x-raw, width=720, height=576" ! x264enc ! mux.sink_301&#xA;WARNING: erroneous pipeline: no property "sink_300::stream-number" in element "mpegtsmux"&#xA;PS C:\gstreamer\1.0\msvc_x86_64\bin> .\gst-launch-1.0.exe --version&#xA;gst-launch-1.0 version 1.24.8&#xA;GStreamer 1.24.8&#xA;Unknown package origin&#xA;PS C:\gstreamer\1.0\msvc_x86_64\bin> .\gst-launch-1.0.exe --version&#xA;gst-launch-1.0 version 1.24.9&#xA;GStreamer 1.24.9&#xA;Unknown package origin&#xA;PS C:\gstreamer\1.0\msvc_x86_64\bin> ./gst-launch-1.0 mpegtsmux name=mux sink_300::stream-number=1 ! udpsink host=192.168.144.255 port=5600 sync=no `&#xA;>> videotestsrc is-live=true pattern=ball ! "video/x-raw, width=1920, height=1080, profile=main" ! x264enc ! mux.sink_300 `&#xA;>> videotestsrc is-live=true ! "video/x-raw, width=720, height=576" ! x264enc ! mux.sink_301&#xA;WARNING: erroneous pipeline: no property "sink_300::stream-number" in element "mpegtsmux"&#xA;

    &#xA;

    I even updated GStreamer, but still no luck. I tried that because I found news saying there were updates regarding that property :

    &#xA;

      397 ### MPEG-TS improvements&#xA;  398 &#xA;  399 -   mpegtsdemux gained support for&#xA;  400     -   segment seeking for seamless non-flushing looping, and&#xA;  401     -   synchronous KLV&#xA;  402 -   mpegtsmux now&#xA;  403     -   allows attaching PCR to non-PES streams&#xA;  404     -   allows setting of the PES stream number for AAC audio and AVC video streams via a new “stream-number” property on the&#xA;  405         muxer sink pads. Currently, the PES stream number is hard-coded to zero for these stream types.&#xA;

    &#xA;

    The syntax seems correct (pad_name::pad_prop_name on the element). I ran out of ideas about what I'm doing wrong with that property.

    &#xA;

    Broader context :

    &#xA;

    I want to set that property because I want an exact sequence of streams I mixing.

    &#xA;

    When I feed mpegtsmux with two video streams and one audio stream (from capture devices) without specifying the stream numbers I get them muxed in a random sequence (checking it using ffprobe). Sometimes they are in the desired sequence, but sometimes they aren't. The worst case is when the audio stream is the first stream in the file, so video players get mad when trying to play such .ts file. I have to remux such files using -map key of ffmpeg. If I could set exact stream indices in mpegtsmux (not to be confused with stream PID) I could avoid analyzing actual stream layout and remuxing.

    &#xA;

    Example of the real layout of the streams (ffprobe output) :

    &#xA;

    Input #0, mpegts, from &#x27;████████████████████████████████████████&#x27;:&#xA;  Duration: 00:20:09.64, start: 3870.816656, bitrate: 6390 kb/s&#xA;  Program 1&#xA;  Stream #0:2[0x41]: Video: h264 (Baseline) (HDMV / 0x564D4448), yuvj420p(pc, bt709, progressive), 1920x1080, 30 fps, 30 tbr, 90k tbn&#xA;  Stream #0:1[0x4b]: Audio: aac (LC) ([15][0][0][0] / 0x000F), 48000 Hz, mono, fltp, 130 kb/s&#xA;  Program 2&#xA;  Stream #0:0[0x42]: Video: h264 (High) (HDMV / 0x564D4448), yuv420p(progressive), 720x576, 25 fps, 25 tbr, 90k tbn&#xA;

    &#xA;

    You can see 3 streams :

    &#xA;

      &#xA;
    • FullHD video with PID 0x41 (defined by me as mpegtsmux0.sink_65) has index 2 while I want it to be 0
    • &#xA;

    • PAL video with PID 0x42 (defined by me as mpegtsmux0.sink_66) has index 0 while I want it to be 1
    • &#xA;

    • Audio with PID 0x4b (defined by me as mpegtsmux0.sink_75) has index 1 while I want it to be 2
    • &#xA;

    &#xA;

  • Unable to set "stream-number" pad property of mpegtsmux

    8 novembre 2024, par TishSerg

    Accroding to gst-inspect-1.0 mpegtsmux, mpegtsmux's sink pads have writable stream-number property :

    &#xA;

    ...&#xA;Pad Templates:&#xA;  SINK template: &#x27;sink_%d&#x27;&#xA;    Availability: On request&#xA;    Capabilities:&#xA;      ...&#xA;    Type: GstBaseTsMuxPad&#xA;    Pad Properties:&#xA;      ...&#xA;&#xA;      stream-number       : stream number&#xA;                            flags: readable, writable&#xA;                            Integer. Range: 0 - 31 Default: 0&#xA;

    &#xA;

    But when I try to set it, GStreamer says there's no such property. The following listing shows I can run multi-stream pipeline without setting that property, but when I add that property it doesn't work.

    &#xA;

    PS C:\gstreamer\1.0\msvc_x86_64\bin> ./gst-launch-1.0 mpegtsmux name=mux ! udpsink host=192.168.144.255 port=5600 sync=no `&#xA;>> videotestsrc is-live=true pattern=ball ! "video/x-raw, width=1920, height=1080, profile=main" ! x264enc ! mux.sink_300 `&#xA;>> videotestsrc is-live=true ! "video/x-raw, width=720, height=576" ! x264enc ! mux.sink_301&#xA;Use Windows high-resolution clock, precision: 1 ms&#xA;Setting pipeline to PAUSED ...&#xA;Pipeline is live and does not need PREROLL ...&#xA;Pipeline is PREROLLED ...&#xA;Setting pipeline to PLAYING ...&#xA;New clock: GstSystemClock&#xA;Redistribute latency...&#xA;Redistribute latency...&#xA;Redistribute latency...&#xA;handling interrupt.9.&#xA;Interrupt: Stopping pipeline ...&#xA;Execution ended after 0:00:03.773243400&#xA;Setting pipeline to NULL ...&#xA;Freeing pipeline ...&#xA;PS C:\gstreamer\1.0\msvc_x86_64\bin> ./gst-launch-1.0 mpegtsmux name=mux sink_300::stream-number=1 ! udpsink host=192.168.144.255 port=5600 sync=no `&#xA;>> videotestsrc is-live=true pattern=ball ! "video/x-raw, width=1920, height=1080, profile=main" ! x264enc ! mux.sink_300 `&#xA;>> videotestsrc is-live=true ! "video/x-raw, width=720, height=576" ! x264enc ! mux.sink_301&#xA;WARNING: erroneous pipeline: no property "sink_300::stream-number" in element "mpegtsmux"&#xA;PS C:\gstreamer\1.0\msvc_x86_64\bin> .\gst-launch-1.0.exe --version&#xA;gst-launch-1.0 version 1.24.8&#xA;GStreamer 1.24.8&#xA;Unknown package origin&#xA;PS C:\gstreamer\1.0\msvc_x86_64\bin> .\gst-launch-1.0.exe --version&#xA;gst-launch-1.0 version 1.24.9&#xA;GStreamer 1.24.9&#xA;Unknown package origin&#xA;PS C:\gstreamer\1.0\msvc_x86_64\bin> ./gst-launch-1.0 mpegtsmux name=mux sink_300::stream-number=1 ! udpsink host=192.168.144.255 port=5600 sync=no `&#xA;>> videotestsrc is-live=true pattern=ball ! "video/x-raw, width=1920, height=1080, profile=main" ! x264enc ! mux.sink_300 `&#xA;>> videotestsrc is-live=true ! "video/x-raw, width=720, height=576" ! x264enc ! mux.sink_301&#xA;WARNING: erroneous pipeline: no property "sink_300::stream-number" in element "mpegtsmux"&#xA;

    &#xA;

    I even updated GStreamer, but still no luck. I tried that because I found news saying there were updates regarding that property :

    &#xA;

      397 ### MPEG-TS improvements&#xA;  398 &#xA;  399 -   mpegtsdemux gained support for&#xA;  400     -   segment seeking for seamless non-flushing looping, and&#xA;  401     -   synchronous KLV&#xA;  402 -   mpegtsmux now&#xA;  403     -   allows attaching PCR to non-PES streams&#xA;  404     -   allows setting of the PES stream number for AAC audio and AVC video streams via a new “stream-number” property on the&#xA;  405         muxer sink pads. Currently, the PES stream number is hard-coded to zero for these stream types.&#xA;

    &#xA;

    The syntax seems correct (pad_name::pad_prop_name on the element). I ran out of ideas about what I'm doing wrong with that property.

    &#xA;

    Broader context :

    &#xA;

    I want to set that property because I want an exact sequence of streams I mixing.

    &#xA;

    When I feed mpegtsmux with two video streams and one audio stream (from capture devices) without specifying the stream numbers I get them muxed in a random sequence (checking it using ffprobe). Sometimes they are in the desired sequence, but sometimes they aren't. The worst case is when the audio stream is the first stream in the file, so video players get mad when trying to play such .ts file. I have to remux such files using -map key of ffmpeg. If I could set exact stream indices in mpegtsmux (not to be confused with stream PID) I could avoid analyzing actual stream layout and remuxing.

    &#xA;

    Example of the real layout of the streams (ffprobe output) :

    &#xA;

    Input #0, mpegts, from &#x27;████████████████████████████████████████&#x27;:&#xA;  Duration: 00:20:09.64, start: 3870.816656, bitrate: 6390 kb/s&#xA;  Program 1&#xA;  Stream #0:2[0x41]: Video: h264 (Baseline) (HDMV / 0x564D4448), yuvj420p(pc, bt709, progressive), 1920x1080, 30 fps, 30 tbr, 90k tbn&#xA;  Stream #0:1[0x4b]: Audio: aac (LC) ([15][0][0][0] / 0x000F), 48000 Hz, mono, fltp, 130 kb/s&#xA;  Program 2&#xA;  Stream #0:0[0x42]: Video: h264 (High) (HDMV / 0x564D4448), yuv420p(progressive), 720x576, 25 fps, 25 tbr, 90k tbn&#xA;

    &#xA;

    You can see 3 streams :

    &#xA;

      &#xA;
    • FullHD video with PID 0x41 (defined by me as mpegtsmux0.sink_65) has index 2 while I want it to be 0
    • &#xA;

    • PAL video with PID 0x42 (defined by me as mpegtsmux0.sink_66) has index 0 while I want it to be 1
    • &#xA;

    • Audio with PID 0x4b (defined by me as mpegtsmux0.sink_75) has index 1 while I want it to be 2
    • &#xA;

    &#xA;