Recherche avancée

Médias (2)

Mot : - Tags -/doc2img

Autres articles (14)

  • Installation en mode ferme

    4 février 2011, par

    Le mode ferme permet d’héberger plusieurs sites de type MediaSPIP en n’installant qu’une seule fois son noyau fonctionnel.
    C’est la méthode que nous utilisons sur cette même plateforme.
    L’utilisation en mode ferme nécessite de connaïtre un peu le mécanisme de SPIP contrairement à la version standalone qui ne nécessite pas réellement de connaissances spécifique puisque l’espace privé habituel de SPIP n’est plus utilisé.
    Dans un premier temps, vous devez avoir installé les mêmes fichiers que l’installation (...)

  • Taille des images et des logos définissables

    9 février 2011, par

    Dans beaucoup d’endroits du site, logos et images sont redimensionnées pour correspondre aux emplacements définis par les thèmes. L’ensemble des ces tailles pouvant changer d’un thème à un autre peuvent être définies directement dans le thème et éviter ainsi à l’utilisateur de devoir les configurer manuellement après avoir changé l’apparence de son site.
    Ces tailles d’images sont également disponibles dans la configuration spécifique de MediaSPIP Core. La taille maximale du logo du site en pixels, on permet (...)

  • La sauvegarde automatique de canaux SPIP

    1er avril 2010, par

    Dans le cadre de la mise en place d’une plateforme ouverte, il est important pour les hébergeurs de pouvoir disposer de sauvegardes assez régulières pour parer à tout problème éventuel.
    Pour réaliser cette tâche on se base sur deux plugins SPIP : Saveauto qui permet une sauvegarde régulière de la base de donnée sous la forme d’un dump mysql (utilisable dans phpmyadmin) mes_fichiers_2 qui permet de réaliser une archive au format zip des données importantes du site (les documents, les éléments (...)

Sur d’autres sites (4168)

  • Restrict FFmpeg/FFserver stream to logged user

    11 juillet 2018, par Homero Bonomini

    I have a live feed setup with FFmpeg streaming audio/video from a webcam through a FFserver. Also, I have a Apache server running a website with a login page, all on the same machine.

    The question is : how can I protect this live stream over a user authentication, so that my camera doesn’t go public ?

    The goal is to provide the resource over http://myexternalip/camera-for-auth-user, for example. The login routes are working fine, but anyone with the stream link (e.g. http://myexternalip:1099/camera.webm) can watch the stream.

    In the website adding a video element with a local reference, after a user authentication :

    <video controls="controls">
    </video>

    obviously fails, since the remote client tries to access the resource on itself. However, I think some sort of local redirect, or maybe don’t use FFServer at all, would meet my needs, but I couldn’t manage to find out how.

  • ffmpeg reduce mp4 size errors : 'Unknown encoder libx264' and 'Unable to find a suitable output format for'

    25 juillet 2018, par martins

    I am quite new to ffmpeg and video editing. I try to reduce the size of various mp4 files. I followed a pretty straightforward tutorial (link) and also copy the audio. In Terminal (Mac user) I write :

    ffmpeg -i inputfile.mp4 -c:a copy -c:v libx264 -crf 24 outputfile.mp4

    The error here is : Unknown encoder 'libx264' and even when I omit the ’libx264’ from the code above, it still gives me the following error : [NULL @ 0x7f9a21814c00] Unable to find a suitable output format for '24' 24: Invalid argument

    As long as I know, 24 is a totally valid value for crf. Of course I tried with others (20, 14, 30) and the error is still there.

    I would very much appreciate a bit of guidance. Thanks for your time in advance.

  • How to add an album cover to an mp3 stream using FFmpeg ?

    29 décembre 2022, par Daniel LAPIDES

    I'm having a bit of an issue and I'd really appreciate it if I could get some insights.

    &#xA;&#xA;

    What I am trying to do is to add an album cover to the mp3 file that will be downloaded from the front-end.

    &#xA;&#xA;

    Context

    &#xA;&#xA;

    I'm downloading a video stream from YouTube and converting it to mp3 using fluent-ffmpeg.
    &#xA;To get the video I use the ytdl npm module.

    &#xA;&#xA;

    I then pipe this stream to the front-end.

    &#xA;&#xA;

    What I've found

    &#xA;&#xA;

    fluent-ffmpeg offers either pipe() or saveToFile().

    &#xA;&#xA;

    What I figured is that when I use the saveToFile() function and actually save my stream into an mp3 file, it works, I do get the album cover.

    &#xA;&#xA;

    But when I pipe the stream to front-end or even into a file, the song is saved properly into a file but without the album cover.

    &#xA;&#xA;

    Here is my code

    &#xA;&#xA;

    Back-end (NodeJS)

    &#xA;&#xA;

    let video = ytdl(`http://youtube.com/watch?v=${videoId}`, {&#xA;  filter: (format) => format.container === &#x27;mp4&#x27; &amp;&amp; format.audioEncoding,&#xA;  quality: &#x27;lowest&#x27;&#xA;});&#xA;&#xA;let stream = new FFmpeg()&#xA;  .input(video)&#xA;  .addInput(`https://i.ytimg.com/vi/${videoId}/default.jpg`)&#xA;  .outputOptions([&#xA;      &#x27;-map 0:1&#x27;,&#xA;      &#x27;-map 1:0&#x27;,&#xA;      &#x27;-c copy&#x27;,&#xA;      &#x27;-c:a libmp3lame&#x27;,&#xA;      &#x27;-id3v2_version 3&#x27;,&#xA;      &#x27;-metadata:s:v title="Album cover"&#x27;,&#xA;      &#x27;-metadata:s:v comment="Cover (front)"&#x27;&#xA;  ])&#xA;  .format(&#x27;mp3&#x27;);&#xA;

    &#xA;&#xA;

    And then piping it to my front-end.

    &#xA;&#xA;

    stream.pipe(res);&#xA;stream&#xA;  .on(&#x27;end&#x27;, () => {&#xA;    console.log(&#x27;******* Stream end *******&#x27;);&#xA;    res.end.bind(res);&#xA;  })&#xA;  .on(&#x27;error&#x27;, (err) => {&#xA;    console.log(&#x27;ERR&#x27;, err);&#xA;    res.status(500).end.bind(res);&#xA;  });&#xA;

    &#xA;&#xA;

    Front-end (React)

    &#xA;&#xA;

    axios.get(url)&#xA;  .then(res => {&#xA;    axios(`${url}/download`, {&#xA;      method: &#x27;GET&#x27;,&#xA;      responseType: &#x27;blob&#x27;&#xA;    })&#xA;      .then(stream => {&#xA;        const file = new Blob(&#xA;          [stream.data],&#xA;          { type: &#x27;audio/mpeg&#x27; });&#xA;        //Build a URL from the file&#xA;        const fileURL = URL.createObjectURL(file);&#xA;      })&#xA;      .catch(err => {&#xA;        console.log(&#x27;ERROR&#x27;, err);&#xA;      });&#xA;    })&#xA;    .catch(err => {&#xA;      console.log(&#x27;ERROR&#x27;, err);&#xA;    });&#xA;

    &#xA;