Recherche avancée

Médias (1)

Mot : - Tags -/stallman

Autres articles (76)

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

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

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

  • Chrome, ffmpeg, and ogg

    13 novembre 2016, par porton

    We need to convert mp4 into ogg by ffmpeg (or maybe some other converter) in such a way that the ogg file to be compatible with Chrome browser.

    The command like

    ffmpeg -i x.mp4 x.ogg

    produces an ogg file which does not work in Chrome.

    ffmpeg -i video_mp4_01_vlublennaya_mama.mp4 x.ogg 2>&1 | tee log.txt

    produces

    ffmpeg version 3.2-2 Copyright (c) 2000-2016 the FFmpeg developers
     built with gcc 6.2.0 (Debian 6.2.0-10) 20161027
     configuration: --prefix=/usr --extra-version=2 --toolchain=hardened --libdir=/usr/lib/i386-linux-gnu --incdir=/usr/include/i386-linux-gnu --enable-gpl --disable-libtesseract --disable-stripping --disable-decoder=libschroedinger --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libebur128 --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librubberband --enable-libschroedinger --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-opengl --enable-sdl2 --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-openal --enable-frei0r --enable-libopencv --enable-libx264 --enable-chromaprint --enable-shared
     libavutil      55. 34.100 / 55. 34.100
     libavcodec     57. 64.100 / 57. 64.100
     libavformat    57. 56.100 / 57. 56.100
     libavdevice    57.  1.100 / 57.  1.100
     libavfilter     6. 65.100 /  6. 65.100
     libavresample   3.  1.  0 /  3.  1.  0
     libswscale      4.  2.100 /  4.  2.100
     libswresample   2.  3.100 /  2.  3.100
     libpostproc    54.  1.100 / 54.  1.100
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'video_mp4_01_vlublennaya_mama.mp4':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
       encoder         : Lavf54.63.104
     Duration: 00:01:23.87, start: 0.000000, bitrate: 840 kb/s
       Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p, 304x224 [SAR 1:1 DAR 19:14], 762 kb/s, 25 fps, 25 tbr, 12800 tbn, 50 tbc (default)
       Metadata:
         handler_name    : VideoHandler
       Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 22050 Hz, stereo, fltp, 74 kb/s (default)
       Metadata:
         handler_name    : SoundHandler
    Output #0, ogg, to 'x.ogg':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
       encoder         : Lavf57.56.100
       Stream #0:0(und): Video: theora (libtheora), yuv420p, 304x224 [SAR 1:1 DAR 19:14], q=2-31, 200 kb/s, 25 fps, 25 tbn, 25 tbc (default)
       Metadata:
         handler_name    : VideoHandler
         encoder         : Lavc57.64.100 libtheora
         major_brand     : isom
         minor_version   : 512
         compatible_brands: isomiso2avc1mp41
       Stream #0:1(und): Audio: vorbis (libvorbis), 22050 Hz, stereo, fltp (default)
       Metadata:
         handler_name    : SoundHandler
         encoder         : Lavc57.64.100 libvorbis
         major_brand     : isom
         minor_version   : 512
         compatible_brands: isomiso2avc1mp41
    Stream mapping:
     Stream #0:0 -> #0:0 (h264 (native) -> theora (libtheora))
     Stream #0:1 -> #0:1 (aac (native) -> vorbis (libvorbis))
    Press [q] to stop, [?] for help
    frame=  117 fps=0.0 q=-0.0 size=     124kB time=00:00:04.96 bitrate= 205.4kbits/s speed=9.91x    
    frame=  247 fps=247 q=-0.0 size=     291kB time=00:00:10.12 bitrate= 235.9kbits/s speed=10.1x    
    frame=  376 fps=250 q=-0.0 size=     438kB time=00:00:15.28 bitrate= 234.9kbits/s speed=10.2x    
    frame=  501 fps=250 q=-0.0 size=     605kB time=00:00:20.30 bitrate= 244.0kbits/s speed=10.1x    
    frame=  635 fps=253 q=-0.0 size=     756kB time=00:00:25.58 bitrate= 241.9kbits/s speed=10.2x    
    frame=  762 fps=253 q=-0.0 size=     901kB time=00:00:30.74 bitrate= 240.0kbits/s speed=10.2x    
    frame=  895 fps=255 q=-0.0 size=    1087kB time=00:00:35.99 bitrate= 247.3kbits/s speed=10.3x    
    frame= 1018 fps=254 q=-0.0 size=    1219kB time=00:00:40.92 bitrate= 244.0kbits/s speed=10.2x    
    frame= 1149 fps=255 q=-0.0 size=    1367kB time=00:00:46.21 bitrate= 242.3kbits/s speed=10.2x    
    frame= 1275 fps=254 q=-0.0 size=    1527kB time=00:00:51.26 bitrate= 244.0kbits/s speed=10.2x    
    frame= 1407 fps=255 q=-0.0 size=    1709kB time=00:00:56.47 bitrate= 247.9kbits/s speed=10.2x    
    frame= 1533 fps=255 q=-0.0 size=    1865kB time=00:01:01.58 bitrate= 248.0kbits/s speed=10.2x    
    frame= 1667 fps=256 q=-0.0 size=    2018kB time=00:01:06.88 bitrate= 247.2kbits/s speed=10.3x    
    frame= 1798 fps=256 q=-0.0 size=    2171kB time=00:01:12.12 bitrate= 246.6kbits/s speed=10.3x    
    frame= 1923 fps=256 q=-0.0 size=    2334kB time=00:01:17.13 bitrate= 247.9kbits/s speed=10.3x    
    [h264 @ 0x81dd77e0] error while decoding MB 8 10, bytestream -13
    [h264 @ 0x81dd77e0] concealing 117 DC, 117 AC, 117 MV errors in P frame
    [aac @ 0x81dbc020] channel element 2.6 is not allocated
    Error while decoding stream #0:1: Invalid data found when processing input
    [h264 @ 0x81e11840] Invalid nal size -352448305
    [h264 @ 0x81e11840] Error splitting the input into NAL units.
    [aac @ 0x81dbc020] Sample rate index in program config element does not match the sample rate index configured by the container.
    [aac @ 0x81dbc020] Inconsistent channel configuration.
    [aac @ 0x81dbc020] get_buffer() failed
    Error while decoding stream #0:1: Invalid argument
    [h264 @ 0x81e55860] Invalid nal size 127321414
    [h264 @ 0x81e55860] Error splitting the input into NAL units.
    Error while decoding stream #0:0: Invalid data found when processing input
       Last message repeated 1 times
    frame= 2045 fps=255 q=-0.0 size=    2483kB time=00:01:22.05 bitrate= 247.9kbits/s dup=2 drop=0 speed=10.2x    
    frame= 2096 fps=255 q=-0.0 Lsize=    2549kB time=00:01:23.86 bitrate= 249.0kbits/s dup=2 drop=0 speed=10.2x    
    video:2046kB audio:472kB subtitle:0kB other streams:0kB global headers:7kB muxing overhead: 1.239568%
  • Playing Live Audio Stream in HTML5 - MediaSource Errors in Chrome

    18 octobre 2016, par user882807

    I need a way to play a live audio stream using HTML5 (primarily in Google Chrome), so I tried using the following :

    <audio>
       <source src="my-live-stream.ogg" type="audio/ogg">
    </source></audio>

    While this does work for a live stream, there seems to be a very large, uncontrollable delay/buffer of around 30 seconds or so when this is played.

    I need the delay to be a couple of seconds or less so this method doesn’t work.

    As an alternative I have tried sending the audio over a WebSocket connection as 1 second individual audio files, which are then appended to a SourceBuffer and played in an audio element using Media Source Extensions.

    After experimenting with a number of formats (MediaSource.isTypeSupported seems to be rather limited in audio support), I got this working using a Vorbis audio stream in a WebM container, which sounds perfect with no audible gaps. Other formats worked less well as they need to be gapless - e.g. MP3 and AAC end up with tiny audible gaps between each 1 second segment.

    While this seems to work at first, when looking at chrome://media-internals, the following errors repeatedly appear :

    00:00:09 544    info    Estimating WebM block duration to be 3ms for the last (Simple)Block in the Cluster for this Track. Use BlockGroups with BlockDurations at the end of each Track in a Cluster to avoid estimation.
    00:00:09 585    error   Large timestamp gap detected; may cause AV sync to drift. time:8994999us expected:9231000us delta:-236001us
    00:01:05 239    debug   Skipping splice frame generation: not enough samples for splicing new buffer at 65077997us. Have 1us, but need 1000us.

    Eventually the playback stops as though the pause button has been pressed on the audio element. It still shows the pause rather than play button, but the current time stops advancing :

    Audio element

    Pressing the pause button and then the play button that replaces it doesn’t make it start playing again, but manually dragging the position slider further ahead makes it continue playing.

    I have tried setting sourceBuffer.mode = 'sequence'; but this doesn’t seem to help.

    Is there anything that needs to be changed in how the audio files are being encoded, or how they are played back in JavaScript to fix this ?


    Additional details :

    1. The audio stream is encoded into 1 second WebM/Vorbis files using FFmpeg on Windows.
    2. A background worker is used in the browser to receive the audio segments and pass them to the main page thread, which appends them to the audio stream. Otherwise the playback freezes.

    Source code :

  • Audio recorded with MediaRecorder on Chrome missing duration

    27 octobre 2016, par suppp111

    I am recording audio (oga/vorbis) files with MediaRecorder. When I record these file through Chrome I get problems : I cannot edit the files on ffmpeg and when I try to play them on Firefox it says they are corrupt (they do play fine on Chrome though).

    Looking at their metadata on ffmpeg I get this :

    Input #0, matroska,webm, from '91.oga':
     Metadata:
       encoder         : Chrome
     Duration: N/A, start: 0.000000, bitrate: N/A
       Stream #0:0(eng): Audio: opus, 48000 Hz, mono, fltp (default)
    [STREAM]
    index=0
    codec_name=opus
    codec_long_name=Opus (Opus Interactive Audio Codec)
    profile=unknown
    codec_type=audio
    codec_time_base=1/48000
    codec_tag_string=[0][0][0][0]
    codec_tag=0x0000
    sample_fmt=fltp
    sample_rate=48000
    channels=1
    channel_layout=mono
    bits_per_sample=0
    id=N/A
    r_frame_rate=0/0
    avg_frame_rate=0/0
    time_base=1/1000
    start_pts=0
    start_time=0.000000
    duration_ts=N/A
    duration=N/A
    bit_rate=N/A
    max_bit_rate=N/A
    bits_per_raw_sample=N/A
    nb_frames=N/A
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=1
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    TAG:language=eng
    [/STREAM]
    [FORMAT]
    filename=91.oga
    nb_streams=1
    nb_programs=0
    format_name=matroska,webm
    format_long_name=Matroska / WebM
    start_time=0.000000
    duration=N/A
    size=7195
    bit_rate=N/A
    probe_score=100
    TAG:encoder=Chrome

    As you can see there are problems with the duration. I have looked at posts like this :
    How can I add predefined length to audio recorded from MediaRecorder in Chrome ?

    But even trying that, I got errors when trying to chop and merge files.For example when running :

    ffmpeg -f concat  -i 89_inputs.txt -c copy final.oga

    I get a lot of this :

    [oga @ 00000000006789c0] Non-monotonous DTS in output stream 0:0; previous: 57612, current: 1980; changing to 57613. This may result in incorrect timestamps in the output file.
    [oga @ 00000000006789c0] Non-monotonous DTS in output stream 0:0; previous: 57613, current: 2041; changing to 57614. This may result in incorrect timestamps in the output file.
    DTS -442721849179034176, next:42521 st:0 invalid dropping
    PTS -442721849179034176, next:42521 invalid dropping st:0
    [oga @ 00000000006789c0] Non-monotonous DTS in output stream 0:0; previous: 57614, current: 2041; changing to 57615. This may result in incorrect timestamps in the output file.
    [oga @ 00000000006789c0] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
    DTS -442721849179031296, next:42521 st:0 invalid dropping
    PTS -442721849179031296, next:42521 invalid dropping st:0

    Does anyone know what we need to do to audio files recorded from Chrome for them to be useful ? Or is there a problem with my setup ?

    Recorder js :

    if (navigator.getUserMedia) {
     console.log('getUserMedia supported.');

     var constraints = { audio: true };
     var chunks = [];

     var onSuccess = function(stream) {
       var mediaRecorder = new MediaRecorder(stream);

       record.onclick = function() {
         mediaRecorder.start();
         console.log(mediaRecorder.state);
         console.log("recorder started");
         record.style.background = "red";

         stop.disabled = false;
         record.disabled = true;

         var aud = document.getElementById("audioClip");
         start = aud.currentTime;
       }

       stop.onclick = function() {
         console.log(mediaRecorder.state);
         console.log("Recording request sent.");
         mediaRecorder.stop();
       }

       mediaRecorder.onstop = function(e) {
         console.log("data available after MediaRecorder.stop() called.");

         var audio = document.createElement('audio');
         audio.setAttribute('controls', '');
         audio.setAttribute('id', 'audioClip');

         audio.controls = true;
         var blob = new Blob(chunks, { 'type' : 'audio/ogg; codecs="vorbis"' });
         chunks = [];
         var audioURL = window.URL.createObjectURL(blob);
         audio.src = audioURL;

         sendRecToPost(blob);   // this just send the audio blob to the server by post
         console.log("recorder stopped");

       }