Recherche avancée

Médias (1)

Mot : - Tags -/musée

Autres articles (111)

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

  • Ajouter des informations spécifiques aux utilisateurs et autres modifications de comportement liées aux auteurs

    12 avril 2011, par

    La manière la plus simple d’ajouter des informations aux auteurs est d’installer le plugin Inscription3. Il permet également de modifier certains comportements liés aux utilisateurs (référez-vous à sa documentation pour plus d’informations).
    Il est également possible d’ajouter des champs aux auteurs en installant les plugins champs extras 2 et Interface pour champs extras.

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

  • Merge commit ’458446acfa1441d283dacf9e6e545beb083b8bb0’

    15 novembre 2013, par Michael Niedermayer
    Merge commit ’458446acfa1441d283dacf9e6e545beb083b8bb0’
    

    * commit ’458446acfa1441d283dacf9e6e545beb083b8bb0’ :
    lavc : Edge emulation with dst/src linesize

    Conflicts :
    libavcodec/cavs.c
    libavcodec/h264.c
    libavcodec/hevc.c
    libavcodec/mpegvideo_enc.c
    libavcodec/mpegvideo_motion.c
    libavcodec/rv34.c
    libavcodec/svq3.c
    libavcodec/vc1dec.c
    libavcodec/videodsp.h
    libavcodec/videodsp_template.c
    libavcodec/vp3.c
    libavcodec/vp8.c
    libavcodec/wmv2.c
    libavcodec/x86/videodsp.asm
    libavcodec/x86/videodsp_init.c

    Changes to the asm are not merged, they are left for volunteers or
    in their absence for later.
    The changes this merge introduces are reordering of the function
    arguments

    See : face578d56c2d1375e40d5e2a28acc122132bc55
    Merged-by : Michael Niedermayer <michaelni@gmx.at>

    • [DH] libavcodec/cavs.c
    • [DH] libavcodec/diracdec.c
    • [DH] libavcodec/h264.c
    • [DH] libavcodec/hevc.c
    • [DH] libavcodec/mpegvideo.c
    • [DH] libavcodec/mpegvideo_enc.c
    • [DH] libavcodec/mpegvideo_motion.c
    • [DH] libavcodec/rv34.c
    • [DH] libavcodec/snow.c
    • [DH] libavcodec/svq3.c
    • [DH] libavcodec/vc1dec.c
    • [DH] libavcodec/videodsp.h
    • [DH] libavcodec/videodsp_template.c
    • [DH] libavcodec/vp3.c
    • [DH] libavcodec/vp56.c
    • [DH] libavcodec/vp8.c
    • [DH] libavcodec/vp9.c
    • [DH] libavcodec/wmv2.c
    • [DH] libavcodec/x86/dsputil_mmx.c
    • [DH] libavcodec/x86/videodsp_init.c
  • VLC RTSP HTML5 transcoding

    30 mai 2022, par Pierogi

    I'm trying to get audio streaming on an HTML page from an RTSP server.

    &#xA;

    The RTSP server is the rtsp-simple-server running a command line below.
    &#xA;./rtsp-simple-server rtsp-simple-server.yml.
    &#xA;The configure file is the default.

    &#xA;

    The stream player is FFmpeg running a command line below.
    &#xA;ffmpeg -re -stream_loop -1 -i myaudio.mp3 -c copy -f rtsp -rtsp_transport tcp rtsp://localhost:8554/mystream

    &#xA;

    The console log at the time the rtsp-simple-server and the ffmpeg are started is below.

    &#xA;

    2022/05/29 19:06:38 INF rtsp-simple-server v0.18.4&#xA;2022/05/29 19:06:38 INF [RTSP] listener opened on :8554 (TCP), :8000 (UDP/RTP), :8001 (UDP/RTCP)&#xA;2022/05/29 19:06:38 INF [RTMP] listener opened on :1935&#xA;2022/05/29 19:06:38 INF [HLS] listener opened on :8888&#xA;2022/05/29 19:09:16 INF [RTSP] [conn [::1]:62737] opened&#xA;2022/05/29 19:09:16 INF [RTSP] [session 271690815] created by [::1]:62737&#xA;2022/05/29 19:09:16 INF [RTSP] [session 271690815] is publishing to path &#x27;mystream&#x27;, 1 track with TCP&#xA;

    &#xA;

    And the time the rtsp path(rtsp ://localhost:8554/mystream) is opened by VLC, the contents can be played properly. The additional console log at the time is below.

    &#xA;

    2022/05/29 19:13:19 INF [RTSP] [conn 127.0.0.1:62780] opened&#xA;2022/05/29 19:13:19 INF [RTSP] [session 734209460] created by 127.0.0.1:62780&#xA;2022/05/29 19:13:19 INF [RTSP] [session 734209460] is reading from path &#x27;mystream&#x27;, 1 track with UDP&#xA;2022/05/29 19:13:29 INF [RTSP] [session 734209460] destroyed (teared down by 127.0.0.1:62780)&#xA;2022/05/29 19:13:29 INF [RTSP] [conn 127.0.0.1:62780] closed (EOF)&#xA;2022/05/29 19:13:29 INF [RTSP] [conn 127.0.0.1:62781] opened&#xA;2022/05/29 19:13:29 INF [RTSP] [session 445756113] created by 127.0.0.1:62781&#xA;2022/05/29 19:13:29 INF [RTSP] [session 445756113] is reading from path &#x27;mystream&#x27;, 1 track with TCP&#xA;

    &#xA;

    However, I open the rtsp streaming from the VLC's "Network" tab like below,&#xA;enter image description here

    &#xA;

    and configure the "Stream output" like below,&#xA;enter image description here

    &#xA;

    and I tried to get this streaming from an HTML page like below,

    &#xA;

    &#xA;&#xA;  &#xA;    &#xA;    &#xA;  &#xA;  &#xA;    <h1>transcode test</h1>&#xA;    <audio src="http://localhost:9999/mystream" autoplay="autoplay"></audio>&#xA;  &#xA;&#xA;

    &#xA;

    the browser console displays Failed to load resource: the server responded with a status of 404 (Not found). I've already tried other ports(etc. 8080).

    &#xA;

    So, how can I get the rtsp stream from the RTSP server on an HTML page.&#xA;Any idea ?

    &#xA;

    My environment.

    &#xA;

      &#xA;
    • Browser : Microsoft edge
    • &#xA;

    • OS : MacOS 11.6.5
    • &#xA;

    • rtsp-simple-server : 0.18.4
    • &#xA;

    • FFmpeg : 5.0.1
    • &#xA;

    • VLC : 3.0.17.3
    • &#xA;

    &#xA;

  • Why is the last frame not showing in an MP4 generated by libav ?

    31 octobre 2023, par Ben

    Note : I have a working example of the problem here.

    &#xA;

    I'm using the libav/ffmpeg API to generate an MP4 with the h264 codec. In my specific situation I'm generating the files with a max number of 2 "B" frames. I'm able to generate an Mp4 with the right number of frames so that a single, lone "B" frame is the very last frame being written. When this happens, the encoder sets that frame's packet to be discarded (I've verified this with ffprobe). The net result is that some players (say, when dropping the MP4 into Edge or Chrome) will display only n-1 total frames (ignoring the discarded packet). Other players, such as VLC, will play the full n frames (not ignoring the discarded packet). So, the result is inconsistent.

    &#xA;

    ffmpeg.exe itself doesn't appear to have this problem. Instead, it will set what would be the lone "B" frame to a "P" frame. This means the file will play the same regardless of what player is used.

    &#xA;

    The problem is : I don't know how to mimic ffmpeg's behavior using the SDK so the last frame will play regardless of the player. As far as I can tell I'm closing out the file properly by flushing out the encoder buffers. I must be doing something wrong somewhere.

    &#xA;

    I provided a link to the full source above, but at a high level I'm initializing the codec context and stream like this :

    &#xA;

    newStream->codecpar->codec_id = AV_CODEC_ID_H264;&#xA;newStream->codecpar->codec_type = AVMEDIA_TYPE_VIDEO;&#xA;newStream->codecpar->width = Width;&#xA;newStream->codecpar->height = Height;&#xA;newStream->codecpar->format = AV_PIX_FMT_YUV420P;&#xA;newStream->time_base = { 1, 75 };&#xA;avcodec_parameters_to_context(codecContext, newStream->codecpar);&#xA;&#xA;&#xA;codecContext->time_base = { 1, 75 };&#xA;codecContext->gop_size = 30;&#xA;

    &#xA;

    I then sit in a loop and use OpenCV to generate frames (each frame has its frame number drawn on it) :

    &#xA;

    auto matrix = cv::Mat(Height, Width, CV_8UC3, cv::Scalar(0, 0, 0));&#xA;&#xA;std::stringstream ss;&#xA;ss &lt;&lt; f; &#xA;&#xA;cv::putText(matrix, ss.str().c_str(), textOrg, fontFace, fontScale, cv::Scalar(255, 255, 255), thickness, 8);&#xA;

    &#xA;

    I then write out the frame like this (looping if more data is needed) :

    &#xA;

    if ((ret = avcodec_send_frame(codecContext, frame)) == 0) {&#xA;&#xA;   ret = avcodec_receive_packet(codecContext, &amp;pkt); &#xA;&#xA;   if (ret == AVERROR(EAGAIN))&#xA;   {&#xA;       continue; &#xA;   }&#xA;   else&#xA;   {&#xA;       av_interleaved_write_frame(pFormat, &amp;pkt);&#xA;   }&#xA;   av_packet_unref(&amp;pkt);&#xA;}&#xA;

    &#xA;

    And finally I flush out the file at the end like this :

    &#xA;

    if ((ret = avcodec_send_frame(codecContext, NULL)) == 0)&#xA;{&#xA;  for (;;)&#xA;  {&#xA;     if ((ret = avcodec_receive_packet(codecContext, &amp;pkt)) == AVERROR_EOF)&#xA;     {&#xA;       break;&#xA;     }&#xA;     else&#xA;     {&#xA;       ret = av_interleaved_write_frame(pFormat, &amp;pkt);&#xA;       av_packet_unref(&amp;pkt);&#xA;     }&#xA;  }&#xA;&#xA;  av_write_trailer(pFormat);&#xA;  avio_close(pFormat->pb);&#xA;}&#xA;

    &#xA;

    Yet when I play in Chrome, the player ends on frame 6758,

    &#xA;

    enter image description here

    &#xA;

    And in VLC, the player ends on frame 6759.

    &#xA;

    enter image description here

    &#xA;

    What am I doing wrong ?

    &#xA;