Recherche avancée

Médias (91)

Autres articles (83)

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

  • Amélioration de la version de base

    13 septembre 2013

    Jolie sélection multiple
    Le plugin Chosen permet d’améliorer l’ergonomie des champs de sélection multiple. Voir les deux images suivantes pour comparer.
    Il suffit pour cela d’activer le plugin Chosen (Configuration générale du site > Gestion des plugins), puis de configurer le plugin (Les squelettes > Chosen) en activant l’utilisation de Chosen dans le site public et en spécifiant les éléments de formulaires à améliorer, par exemple select[multiple] pour les listes à sélection multiple (...)

  • Emballe médias : à quoi cela sert ?

    4 février 2011, par

    Ce plugin vise à gérer des sites de mise en ligne de documents de tous types.
    Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ;

Sur d’autres sites (7753)

  • typeError when using ffmpeg with buffer in NodeJS ["argument must be of type string or an instance of Buffer"]

    16 mars 2021, par coolps811

    I am trying to covert buffer data into the correct mp4 video format. However I am getting an error : "UnhandledPromiseRejectionWarning : TypeError [ERR_INVALID_ARG_TYPE] : The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received an instance of FfmpegCommand". How can I fix this ?

    


    router.post("/download", (req, res, next) => {
  axios({
    method: "get",
    url: req.body.url,
    responseType: "arraybuffer",
  }).then(function (response) {
    const data = new Uint8Array(Buffer.from(response.data));

    const proc = new ffmpeg(data)
      .videoCodec("libx264")
      .outputOptions(["-movflags isml+frag_keyframe"])
      .toFormat("mp4")
      //.seekInput(offset) this is a problem with piping
      .on("error", function (err, stdout, stderr) {
        console.log("an error happened: " + err.message);
        console.log("ffmpeg stdout: " + stdout);
        console.log("ffmpeg stderr: " + stderr);
      })
      .on("end", function () {
        console.log("Processing finished !");
      })
      .on("progress", function (progress) {
        console.log("Processing: " + progress.percent + "% done");
      });

    fs.writeFile("Assets/test.mp4", proc, callback);
  });

  const callback = (err) => {
    if (err) throw err;
    console.log("It's saved!");
  };
});


    


  • How do I read an mp4 file directly into moviepy from S3 ?

    9 novembre 2022, par racket99

    Any idea how to read an S3 mp4 file directly into moviepy ?

    



    I have tried,

    



    import boto3
from io import BytesIO
from moviepy.editor import *

client = boto3.client('s3')
obj =  client.get_object(Bucket='some-bucket', Key='some-file')
VideoFileClip(BytesIO(obj['Body'].read())) 


    



    but I am getting,

    



    Traceback (most recent call last):&#xA;File "<stdin>", line 1, in <module>&#xA;File "/<path>/lib/python3.6/site-packages/moviepy/video/io/VideoFileClip.py", line 91, in __init__&#xA;fps_source=fps_source)&#xA;File "/<path>/lib/python3.6/site-packages/moviepy/video/io/ffmpeg_reader.py", line 33, in __init__&#xA;fps_source)&#xA;File "/<path>/lib/python3.6/site-packages/moviepy/video/io/ffmpeg_reader.py", line 243, in ffmpeg_parse_infos&#xA;is_GIF = filename.endswith(&#x27;.gif&#x27;)&#xA;AttributeError: &#x27;_io.BytesIO&#x27; object has no attribute &#x27;endswith&#x27;&#xA;</path></path></path></module></stdin>

    &#xA;&#xA;

    where path is my virtual environment

    &#xA;

  • nginx ffmpeg mpegts http

    6 mars 2024, par michel

    i can't understand how to serve .ts files from nginx.&#xA;for hls it works without problems (m3u8).

    &#xA;&#xA;

    http://127.0.0.1/hls/stream_name.m3u8

    &#xA;&#xA;

    http://127.0.0.1/stream_name

    &#xA;&#xA;

    I tried to compile nginx with the 2 modules :

    &#xA;&#xA;

    nginx-live-module

    &#xA;&#xA;

    nginx-ts-module

    &#xA;&#xA;

    It works in part, if I send a stream it works, if I send for example 10 it doesn't work.

    &#xA;&#xA;

    ffmpeg -re -f concat -safe 0 -i stream.txt -c copy -map 0 -f mpegts "http://127.0.0.1/stream_name?buffer_size=1048576"

    &#xA;&#xA;

    with VLC I open the stream and it works but if I try to open more streams it doesn't open even if ffmpeg is sending to the nginx server.

    &#xA;&#xA;

    what am I doing wrong ?

    &#xA;&#xA;

    user  www;&#xA;worker_processes  auto;&#xA;worker_rlimit_nofile 300000;&#xA;events {&#xA;    worker_connections  16000;&#xA;    use epoll;&#xA;        accept_mutex on;&#xA;        multi_accept on;&#xA;}&#xA;&#xA;error_log  logs/error.log  notice;&#xA;&#xA;http {&#xA;    live_zone zone=foo:100m;&#xA;&#xA;    server {&#xA;        listen 8080;&#xA;&#xA;        location / {&#xA;            live foo;&#xA;            live_methods GET POST;&#xA;&#xA;            # enable endless request body&#xA;            client_max_body_size 0m;&#xA;        }&#xA;    }&#xA;&#xA;}&#xA;&#xA;

    &#xA;