Recherche avancée

Médias (91)

Autres articles (111)

  • Script d’installation automatique de MediaSPIP

    25 avril 2011, par

    Afin de palier aux difficultés d’installation dues principalement aux dépendances logicielles coté serveur, un script d’installation "tout en un" en bash a été créé afin de faciliter cette étape sur un serveur doté d’une distribution Linux compatible.
    Vous devez bénéficier d’un accès SSH à votre serveur et d’un compte "root" afin de l’utiliser, ce qui permettra d’installer les dépendances. Contactez votre hébergeur si vous ne disposez pas de cela.
    La documentation de l’utilisation du script d’installation (...)

  • Ajouter des informations spécifiques aux utilisateurs et autres modifications de comportement liées aux auteurs

    12 avril 2011, par

    La manière la plus simple d’ajouter des informations aux auteurs est d’installer le plugin Inscription3. Il permet également de modifier certains comportements liés aux utilisateurs (référez-vous à sa documentation pour plus d’informations).
    Il est également possible d’ajouter des champs aux auteurs en installant les plugins champs extras 2 et Interface pour champs extras.

  • Librairies et binaires spécifiques au traitement vidéo et sonore

    31 janvier 2010, par

    Les logiciels et librairies suivantes sont utilisées par SPIPmotion d’une manière ou d’une autre.
    Binaires obligatoires FFMpeg : encodeur principal, permet de transcoder presque tous les types de fichiers vidéo et sonores dans les formats lisibles sur Internet. CF ce tutoriel pour son installation ; Oggz-tools : outils d’inspection de fichiers ogg ; Mediainfo : récupération d’informations depuis la plupart des formats vidéos et sonores ;
    Binaires complémentaires et facultatifs flvtool2 : (...)

Sur d’autres sites (9460)

  • How to merge multiple videos and audios in python ffpmeg [closed]

    18 décembre 2020, par Alireza Farzaneh

    I'm making a program for downloading Adobe connect based meetings' recordings using python.
I have managed to download Adobe connect sessions' recording.
    
Now I have multiple separate audios and videos.
    
I'm trying to merge them into one video using python and ffmpeg library.
    
The problem is that I want them to be in sync.
    

    
Here is an example :
    
I have four files :

    "cameraVoip_0_4.flv" : audio, started at "Sat Nov 07 13:36:11 2020" and lasted for 2888.128000 seconds.

    "cameraVoip_0_6.flv" : audio, started at "Sat Nov 07 14:26:42 2020" and lasted for 366.455 seconds.

    "screenshare_1_2.flv" : video, started at "Sat Nov 07 13:36:01 2020" and lasted for 2844.602000 seconds.

    "screenshare_3_7.flv" : video, started at "Sat Nov 07 14:26:51 2020" and lasted for 352.635000 seconds.


    
I want to merge them somehow that their timing would be correct.

    


  • Trim video into multiple sections ffmpeg

    24 décembre 2020, par fitzmode

    I need to trim a video into multiple sections of unequal duration and output them as separate files.

    


    For example a .mp4 100 seconds long and I need to extract and keep

    


      

    • output0.mp4 from 5 - 10sec
    • 


    • output1.mp4 from 10 - 20 sec
    • 


    • output2.mp4 from 35 - 60 sec
    • 


    


    Current Solution :

    


    ffmpeg -i video.mp4 -c copy  -t 5  output0.mp4 -ss 10 -c copy -t 10 output1.mp4 -ss 20 -c copy -ss 35 t 60  output2.mp4 -y


    


    Current solution works but is there a way to group process and index the output with a format specifier ?
Something like below or an alternative method without re-encoding ?

    


    ffmpeg -i video.mp4  -c copy -t 5 -ss 10  -t 10 -ss 20 -y output%d.mp4


    


    My alternative solution using segment has the problem that it also returns an output3.mp4 from 60 - 100sec and the durations aside from output0.mp4 do not match the expected values.

    


    ffmpeg -i video.mp4 -c copy -f segment -segment_times 5,10,20,35,60 output%d.mp4


    


  • Running ffmpeg (WASM/NodeJS) on multiple input files in a React App

    17 septembre 2024, par FlipFloop

    I recently followed a tutorial by Fireship.io going over making a React App that enables a user to input a video file and convert it into a gif. Here is the source GitHub Repo.

    


    The packages used by the project are @ffmpeg/ffmpeg and @ffmpeg/core, which take care of converting the video into a GIF (although this can be changed to whatever, like the FFmpeg CLI tool).

    


    I wanted to take this a step further and make it possible for me to convert multiple videos at once, each into their own separate gif, however, I am having trouble running the next task when the first is finished.

    


    Here is documentation I found about the ffmpeg wasm package. I also read this example given by the package providers to have multiple outputs from a single file.

    


    Here is my code (App.jsx) :

    


    import { createFFmpeg, fetchFile } from &#x27;@ffmpeg/ffmpeg&#x27;;&#xA;const ffmpeg = createFFmpeg({ log: true });&#xA;&#xA;function App() {&#xA;    const [ready, setReady] = useState(false);&#xA;    const [videos, setVideos] = useState([]);&#xA;    const [gifs, setGifs] = useState([]);&#xA;    const load = async () => {&#xA;         await ffmpeg.load();&#xA;         setReady(true);&#xA;    };&#xA;&#xA;   useEffect(() => {&#xA;       load();&#xA;   }, []);&#xA;&#xA;   const onInputChange = (e) => {&#xA;       for (let i = 0; i &lt; e.target.files.length; i&#x2B;&#x2B;) {&#xA;           const newVideo = e.target.files[i];&#xA;           setVideos((videos) => [...videos, newVideo]);&#xA;       }&#xA;   };&#xA;&#xA;   const batchConvert = async (video) => {&#xA;       const name = video.name.split(&#x27;.mp4&#x27;).join(&#x27;&#x27;);&#xA;&#xA;       ffmpeg.FS(&#x27;writeFile&#x27;, name &#x2B; &#x27;.mp4&#x27;, await fetchFile(video));&#xA;       await ffmpeg.run(&#xA;           &#x27;-i&#x27;,&#xA;           name &#x2B; &#x27;.mp4&#x27;,&#xA;           &#x27;-f&#x27;,&#xA;           &#x27;gif&#x27;,&#xA;            name &#x2B; &#x27;.gif&#x27;,&#xA;        );&#xA;&#xA;        const data = ffmpeg.FS(&#x27;readFile&#x27;, name &#x2B; &#x27;.gif&#x27;);&#xA;&#xA;        const url = URL.createObjectURL(&#xA;            new Blob([data.buffer], { type: &#x27;image/gif&#x27; }),&#xA;        );&#xA;&#xA;        setGifs((gifs) => [...gifs, url]);&#xA;    };&#xA;&#xA;    const convertToGif = async () => {&#xA;        videos.forEach((video) => {&#xA;            batchConvert(video);&#xA;        }&#xA;    );&#xA;&#xA;return ready ? (&#xA;<div classname="App">&#xA;  {videos &amp;&amp;&#xA;    videos.map((video) => (&#xA;      <video controls="controls" width="250" src="{URL.createObjectURL(video)}"></video>&#xA;    ))}&#xA;&#xA;  <input type="file" multiple="multiple" />&#xA;&#xA;  {videos &amp;&amp; <button>Convert to Gif</button>}&#xA;&#xA;  {gifs &amp;&amp; (&#xA;    <div>&#xA;      <h3>Result</h3>&#xA;      {gifs.map((gif) => (&#xA;        <img src="http://stackoverflow.com/feeds/tag/{gif}" width="250" style='max-width: 300px; max-height: 300px' />&#xA;      ))}&#xA;    </div>&#xA;  )}&#xA;</div>&#xA;) : (&#xA;    <p>Loading...</p>&#xA;);&#xA;}&#xA;&#xA;export default App;&#xA;

    &#xA;

    The error I am getting is along the lines of "Cannot run multiple instances of FFmpeg at once", which I understand, however, I have no idea how to make the batchConvert function only run one instance at a time, whether it's outside or inside the function.

    &#xA;

    Thank you !

    &#xA;