Recherche avancée

Médias (2)

Mot : - Tags -/media

Autres articles (64)

  • Keeping control of your media in your hands

    13 avril 2011, par

    The vocabulary used on this site and around MediaSPIP in general, aims to avoid reference to Web 2.0 and the companies that profit from media-sharing.
    While using MediaSPIP, you are invited to avoid using words like "Brand", "Cloud" and "Market".
    MediaSPIP is designed to facilitate the sharing of creative media online, while allowing authors to retain complete control of their work.
    MediaSPIP aims to be accessible to as many people as possible and development is based on expanding the (...)

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

  • Ajouter notes et légendes aux images

    7 février 2011, par

    Pour pouvoir ajouter notes et légendes aux images, la première étape est d’installer le plugin "Légendes".
    Une fois le plugin activé, vous pouvez le configurer dans l’espace de configuration afin de modifier les droits de création / modification et de suppression des notes. Par défaut seuls les administrateurs du site peuvent ajouter des notes aux images.
    Modification lors de l’ajout d’un média
    Lors de l’ajout d’un média de type "image" un nouveau bouton apparait au dessus de la prévisualisation (...)

Sur d’autres sites (7851)

  • FFMPEG - Extract sequence while recording

    26 février 2020, par Vincent Carretero

    I have a ffmpeg process to record a webcam, thats very classic...
    I would like to extract a sequence from the recording file before the end of the record.

    example :
    - my recording start at 10:00 am and finish at 11:00 am
    - at 10:15 am, an event append, and an operator need to watch it quickly,
    - i would like to extract the sequence, and than he can watch at 10:20 am (but the video still recording and the Mp4.file not ended).

    is that possible ?

    thanks !!

  • How to fix 'Error : Write EOF' when running a nodejs file which spawns a child process running ffmpeg ?

    16 septembre 2022, par Prithivin Lakshminarayanan

    I am new to nodejs scripting and I am trying to create a program which receives a video file as a buffer and creates a thumbnail from it. This is my code :

    


    create_thumbnail.js :

    


    const { Readable } = require('stream');
const child_process = require('node:child_process');

async function generate_thumbnail(videoFile, callback) {

    const readable = new Readable();
    readable._read = () => {}
    readable.push(videoFile.data)
    readable.push(null)
    const ffmpeg = child_process.spawn('C:\\FFmpeg\\bin\\ffmpeg', ['-i', 'pipe:0', '-vframes', '1', '-vf', 'scale=iw*.5:ih*0.5', '-f', 'mjpeg', 'pipe:1'], { stdio: ['pipe', 'pipe', 'ignore'] })
    readable.pipe(ffmpeg.stdin);

    const buffer = [];

    ffmpeg.stdout.on('data', (data) => {
        buffer.push(data);
    });

    const thumbnail = ffmpeg.stdout.on('end', () => {
        console.log('There will be no more data.');
        var buf = Buffer.concat(buffer);
        callback (buf);
    });
}

module.exports = { generate_thumbnail };


    


    The program is creating a thumbnail successfully for a video which has a few seconds length. It is failing for larger videos with the following error :

    


    node:events:368
      throw er; // Unhandled 'error' event
      ^

Error: write EOF
    at WriteWrap.onWriteComplete [as oncomplete] (node:internal/stream_base_commons:98:16)
Emitted 'error' event on Socket instance at:
    at Socket.onerror (node:internal/streams/readable:773:14)
    at Socket.emit (node:events:390:28)
    at emitErrorNT (node:internal/streams/destroy:157:8)
    at emitErrorCloseNT (node:internal/streams/destroy:122:3)
    at processTicksAndRejections (node:internal/process/task_queues:83:21) {
  errno: -4095,
  code: 'EOF',
  syscall: 'write'


    


    Can someone please let me know the reason for getting this error. How can I fix it ?

    


  • ffmpeg replacing audio track with track from another video but different length (sync audio)

    27 août 2019, par Matt

    Background

    I have digitized some old Canon Video8 tapes. I used a SONY Digital8 camera (which is backwards compatible with Video8) to output DV (using it’s inbuilt ADC). The conversion process worked well for the video but the audio came through jumpy/distorted in places. This left me with a problem, was it the Camera or the tape ? So I bought another Samsung Video8 camera (just analog) and using the SONY’s passthrough feature output from the Samsung (Composite & mono audio) into the SONY which output the DV. Much to my delight it worked ! The audio was clear.

    Result

    DV01.avi - Good Video / Crap Audio
    DV02.avi - Crap Video / Good Audio

    Ok so obviously what I would like to do is take the video track from DV01 and the audio track from DV02 and join/mux ? them WITHOUT re-encoding.

    Problem 1 : They have different start times so just copying over the audio track will result it not being in sync.

    After some googling I found you can use ffmpeg to take care of this :

    Firstly here is the Video info using : ffmpeg -i DV01.avi

    Input #0, avi, from 'DV01.avi':
     Duration: 02:53:06.68, start: 0.000000, bitrate: 28878 kb/s
       Stream #0:0: Video: dvvideo, yuv420p, 720x576 [SAR 16:15 DAR 4:3], 25000 kb/s, 25 fps, 25 tbr, 25 tbn, 25 tbc
       Stream #0:1: Audio: pcm_s16le, 32000 Hz, stereo, s16, 1024 kb/s
       Stream #0:2: Audio: pcm_s16le, 32000 Hz, stereo, s16, 1024 kb/s

    Muxing :

    ffmpeg -itsoffset 4 -i DV01.avi -i DV02.avi -map 0:v -map 1:a -c copy output.avi

    In the example above I am delaying the start of the video 4 seconds (I think ?) This is just an example I haven’t actually tried it as the file sizes are 40Gb !

    So my QUESTION is :

    Given the background above what would be the best way to join/mux the two streams together (without re-encoding) with the audio being in sync. Given that syncing the audio to the video may need millisecond tweaking I don’t believe trial and error is a good idea (I don’t want to tweak it by 10ms then rinse and repeat for a 40Gb file) ?

    I just had a thought, could I say create a 10 second clip (from the start) of each video and use them to find the reference/sync start point then use that when muxing the 40Gb versions ?

    Anyway, you get the idea. Looking for ways to solve this problem. Thanks !