Recherche avancée

Médias (0)

Mot : - Tags -/utilisateurs

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

Autres articles (111)

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

  • Problèmes fréquents

    10 mars 2010, par

    PHP et safe_mode activé
    Une des principales sources de problèmes relève de la configuration de PHP et notamment de l’activation du safe_mode
    La solution consiterait à soit désactiver le safe_mode soit placer le script dans un répertoire accessible par apache pour le site

  • Prérequis à l’installation

    31 janvier 2010, par

    Préambule
    Cet article n’a pas pour but de détailler les installations de ces logiciels mais plutôt de donner des informations sur leur configuration spécifique.
    Avant toute chose SPIPMotion tout comme MediaSPIP est fait pour tourner sur des distributions Linux de type Debian ou dérivées (Ubuntu...). Les documentations de ce site se réfèrent donc à ces distributions. Il est également possible de l’utiliser sur d’autres distributions Linux mais aucune garantie de bon fonctionnement n’est possible.
    Il (...)

Sur d’autres sites (11451)

  • Firefox doesn't play mp4 file in HTML5 video

    21 janvier 2016, par Developer

    I recorded a video with my mobile which had the format ".mp4". Now if I load that video in HTML5 video tag, I get an error HTTP "Content-Type" of "video/3gpp" is not supported. Why does Firefox consider the file as 3gpp although it is an mp4 file ?
    If I log the file properties when it is loaded on to browser, I see the following

    { name: "test.mp4", lastModified: 1434536249000, lastModifiedDate: Date 2015-06-17T10:17:29.000Z, size: 41151959, type: "video/mp4" }

    This means firefox identifies the type as mp4 only. But doesn’t play it giving the error HTTP "Content-Type" of "video/3gpp" is not supported.

  • Play h.264 video stream in html page

    12 juin 2017, par e2l3n

    I am using ffmpeg and vlc on linux to produce MPEG transport stream (mpegts) over HTTP. Basically ffmpeg captures the screen and produces h.264 stream using mpegts and then vlc is used as a server that delivers the stream over http. That’s how I manage to accomplish this.

    ffmpeg -f x11grab -s 1280x800 -r 30 -i :0.0+0,0  -f alsa -ac 2 -i pulse -vcodec libx264 -preset ultrafast -s 1280x800 -threads 0 -f mpegts - | vlc -I dummy - --sout '#std{access=http,mux=ts,dst=:3030}

    And some useful log about the resulting stream :

    Output #0, mpegts, to 'pipe:':
     Metadata:
       encoder         : Lavf57.72.101
       Stream #0:0: Video: h264 (libx264), yuv444p(progressive), 1280x800, q=-1--1, 30 fps, 90k tbn, 30 tbc
       Metadata:
         encoder         : Lavc57.96.101 libx264
       Side data:
         cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
       Stream #0:1: Audio: mp2, 48000 Hz, stereo, s16, 384 kb/s
       Metadata:
         encoder         : Lavc57.96.101 mp2

    All looks good except for that I am unable to play the stream in a HTML page. Could someone point me at some solution to either render the stream in HTML page or change the stream type so that it gets rendered.
    Thank you in advance !

    EDIT :
    I’ve noticed something weird. The <video></video> fails to play mp4 files on Firefox (51.0.1) for Ubuntu (I have also tested on Windows 8 with Chrome).
    I simply use ffmpeg to record screen for 10 seconds and produce .mp4 video (see below).

    ffmpeg -video_size 1280x800 -framerate 25 -f x11grab -i :0.0+0,0 -t 00:00:10 ~/Workspace/videostream/output.mp4

    And then play the output.mp4 video with the following snippet.

    <video width="480" height="320" controls="controls">
       <source src="output.mp4" type="video/mp4">
    </source></video>

    This simply does not play although I can open the video with any other media player. The media info (using MediaInfo, v0.7.96) of the output.mp4 file is :

    GENERAL: MPEG-4 (Base Media): 1.007 MiB, 10s 0ms; 1 Video stream: AVC; Overall bit rate: 825 Kbps; Writing application: Lavf57.72.101
    VIDEO: 2 343 Kbps, 1280*800(16:10), at 25.000 fps, MPEG Video (Version 2) (Main@High 1440)

    However, if I replace the output.mp4 with any other .mp4 file, it does play in Firefox. So, this leads me to conclude that it is not a browser issue but something with the way I exploit ffmpeg. Below is the media info of a proper .mp4 file that successfully runs in the browser.

    GENERAL: MPEG-4 (Base Media/Version 2): 48.4 MiB, 2mn 50s; 1 Video stream: AVC; 1 Audio stream: AAC; Overall bit mode rate: Variable; Overall bit rate: 2 385 Kbps;
    VIDEO: 2 256 Kbps, 1280*720(16:9), at 25.000 fps, AVC (Main@L3.1) (CABAC / 3 Ref Frames); ISO media produced by Google Inc.
    AUDIO:
    126 Kbps, 44.1 KHz, 2 channels, AAC (LC), ISO media produced by Google Inc.

    And here is the media info of the output file that results from redirecting the h.264 mpegts stream using the ffmpeg command with -pix_fmt yuv420p ./ffmpeg -t 00:00:10 -f x11grab -s 1280x800 -r 30 -i :0.0+0,0 -pix_fmt yuv420p -vcodec libx264 -preset ultrafast -s 1280x800 -threads 0 -f mpegts - > ~/Workspace/file.ts :

    GENERAL: MPEG-TS: 2.93 MiB, 9s 960ms; 1 Video stream: MPEG Video; 1 Menu stream: MPEG Video; Overall bit rate mode: Variable; Overall bit rate: 2 465 Kbps;
    VIDEO: 2 343 Kbps, 1280*800(16:10), at 25.000 fps, MPEG Video (Version 2) (Main@High 1440)
  • QML multimedia cannot play m3u8 that is generated with ffmpeg

    5 juin 2023, par LeXela-ED

    With the following command, I am trying to stream an IP camera over web :

    &#xA;

    ffmpeg -re -i "rtsp://<user>:<password>@<ip>:<port>" -c:v copy -c:a copy -hls_segment_type mpegts -hls_list_size 5 -hls_wrap 5 -hls_time 2 -hls_flags split_by_time -segment_time_delta 1.00 -reset_timestamps 1 -hls_allow_cache 0 -movflags faststart live.m3u8```&#xA;</port></ip></password></user>

    &#xA;

    This command, produces live.m3u8 and five ts files : live0.ts, live1.ts, live2.ts, live3.ts, and live4. And conversion goes smoothly. At some random point, the content of live.m3u8 is as follows :

    &#xA;

    #EXTM3U&#xA;#EXT-X-VERSION:3&#xA;#EXT-X-TARGETDURATION:2&#xA;#EXT-X-MEDIA-SEQUENCE:92&#xA;#EXTINF:2.000000,&#xA;live2.ts&#xA;#EXTINF:2.000000,&#xA;live3.ts&#xA;#EXTINF:2.035800,&#xA;live4.ts&#xA;#EXTINF:2.000000,&#xA;live0.ts&#xA;#EXTINF:1.963278,&#xA;live1.ts&#xA;

    &#xA;

    However, when I tried to play live.m3u8 with the following QML code, it only played a very first segments of it :

    &#xA;

    import QtQuick 2.15&#xA;import QtQuick.Window 2.15&#xA;import QtQuick.Controls 2.15&#xA;import QtQuick.Layouts 1.15&#xA;import QtMultimedia 5.15&#xA;&#xA;Window&#xA;{&#xA;    width: 640&#xA;    height: 480&#xA;    visible: true&#xA;&#xA;    Item&#xA;    {&#xA;        anchors.fill: parent&#xA;&#xA;        MediaPlayer&#xA;        {&#xA;            id: mediaplayer&#xA;            source: "path-to-live/live.m3u8"&#xA;            videoOutput: videoOutput&#xA;        }&#xA;&#xA;        VideoOutput&#xA;        {&#xA;            id: videoOutput&#xA;            anchors.fill: parent&#xA;        }&#xA;&#xA;        MouseArea&#xA;        {&#xA;            anchors.fill: parent&#xA;            onPressed: mediaplayer.play();&#xA;        }&#xA;    }&#xA;}&#xA;&#xA;

    &#xA;

    The interesting thing is : I manually deleted live.m3u8, and obviously, ffmpeg generated another one after ! Then I clicked on the QML program window, and surprisingly, it played the stream nonstop as it was expected at the first run !

    &#xA;

    What is the problem here ? What I am missing ? Should I change the ffmpeg command or do something with my qml code ? Any idea or help ?

    &#xA;

    Thank you in advance.

    &#xA;