
Recherche avancée
Autres articles (109)
-
Le profil des utilisateurs
12 avril 2011, parChaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...) -
Websites made with MediaSPIP
2 mai 2011, parThis page lists some websites based on MediaSPIP.
-
Ajouter des informations spécifiques aux utilisateurs et autres modifications de comportement liées aux auteurs
12 avril 2011, parLa 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.
Sur d’autres sites (14942)
-
Ffmpeg merge videos from images with videos and audio cut
30 mars 2021, par Trofingot a question about fluent ffmpeg, i'm quite new to it so need some help.


I'm trying to get images and videos from S3 so i can make a full video from them.
So i'm making videos with .loop with certain video length from images.
Then i'm adding a normal video with it's audio.
Then i'm cutting audio length so the audio that was added will play only on the videos made from images.
When the video which was merged with the videos from images will come to play it will have his own audio.
The thing is that if i merge all videos i get this error :

An error occurred while merging video files: ffmpeg exited with code 1: Cannot find a matching stream for unlabeled input pad 7 on filter Parsed_concat_0.


So i need to add an audio to the video which was not made from images so that the stream could work. How can i avoid this and let that video have it's own audio ? what inputOptions should i add ? Also when i cut the audio it has a delay, what audioFilters can i add ?


``


const videosFromImages = [];
 VIDEO_CONFIG.fragments.forEach((fragment) => {
 videosFromImages.push(function (callback) {
 let ffmpegInstance = ffmpeg(
 `./images/images-with-same-size/${fragment.filename}`
 );

 if (fragment.duration && fragment.type === "image") {
 ffmpegInstance.loop(fragment?.duration);
 }

 if (fragment.type === "image") {
 ffmpegInstance
 .addInput("./audio/audio.mp3")
 .inputOptions(
 "-ss",
 time,
 "-to",
 time + fragment.duration,
 "-async",
 "1"
 );

 time = time + fragment.duration;
 console.log("time:", time);
 }

 ffmpegInstance
 .videoCodec("libx264") // Codec from api
 .videoBitrate("12000k") // Video Quality
 .videoFilters([
 {
 filter: "fade",
 options: "in:0:15",
 },
 ]) // Transitions
 .on("error", function (err) {
 console.error("An error occurred: " + err.message);
 })
 .on("end", function () {
 res.write(`<p>Processing finished for ${fragment.filename}</p>`);
 fragment.filePath = `./output/project-${VIDEO_CONFIG.projectId}/videos/video-${fragment.filename}.avi`;

 callback(null, fragment);
 })
 .save(
 `./output/project-${VIDEO_CONFIG.projectId}/videos/video-${fragment.filename}.avi`
 );
 });
 });

 async.series(videosFromImages, function (err, videosFromImages) {
 // result now equals 'done'
 async.waterfall(
 [
 (done) => {
 console.log("VIDEO_CONFIG", VIDEO_CONFIG.fragments);

 VIDEO_CONFIG.fragments
 .reduce((prev, curr) => prev.input(curr.filePath), ffmpeg())
 .outputFPS(60)
 .on("error", (err) => {
 res.end();
 console.log(
 `An error occurred while merging video files: ${err.message}`
 );
 })
 .on("end", () => {
 res.write("FINAL VIDEO END");
 res.end();
 console.log("end:");
 })
 .mergeToFile(
 `./output/project-${VIDEO_CONFIG.projectId}/final-video-${VIDEO_CONFIG.projectId}.mp4`
 );
 done(null);
 },
 ],
 (err) => {
 if (err) {
 console.log("err:", err);
 }
 }
 );
 });

 res.write("<p>Processing</p>");
} catch (error) {
 console.error("error:", error);
}



``


-
ffmpeg - concatenate mp4 files + audio from a folder structure
17 septembre 2022, par Ionut BejinariuI use this batch file to concatenate several .mp4 files and then join them with an audio song.


@echo off

mkdir ".\Export" 
set "sourcedir=" 
set "outputdir=Export" 

for %%i in (*.mp4) do echo file '%%i'>> lista.txt
ffmpeg -f concat -safe 0 -i lista.txt -c copy mergedmp4.mp4

for %%F in (*.wav *.mp3) DO ( 
 ffmpeg -i mergedmp4.mp4 -i "%%F" -map 0:v -map 1:a -vcodec copy -c:a aac -b:a 320k "%outputdir%\%%~nF.mp4"
)

del lista.txt
del mergedmp4.mp4



So far so good, It's working


I would describe what will help me more and I need to happen :


I have this folder structure
\Video-15-sec\Canal-1\Videos-1, Videos-2 .. Videos-15
or sometimes can be until Videos-20 or more, depends how I organize them.

All of Videos folders have .mp4 files in them and are renamed all the time
1.mp4, 2.mp4, 3.mp4 ... 25.mp4 ... 35.mp4 ..etc
each of the Videos folders respect the name of file starting with 1.mp4 to how many are in the folder.

The directory structure is like this :




──Video-15-sec
│ ├───Canal-1
│ │ ├───Videos-1 (.mp4 files in it)
│ │ ├───Videos-2 (.mp4 files in it)
│ │ ├───Videos-3 (.mp4 files in it)
│ │ ├───Videos-4 ...
│ │ ├───Videos-5
│ │ ├───Videos-6
│ │ ├───Videos-7
│ │ ├───Videos-8
│ │ ├───Videos-9
│ │ ├───Videos-10
│ │ ├───Videos-11
│ │ ├───Videos-12
│ │ ├───Videos-13
│ │ ├───Videos-14
│ │ └───Videos-15
│ ├───Canal-2
│ │ ├───Videos-1 (.mp4 files in it)
│ │ ├───Videos-2 (.mp4 files in it)
│ │ ├───Videos-3 (.mp4 files in it)
│ │ ├───Videos-4 ...
│ │ ├───Videos-5
│ │ ├───Videos-6
│ │ ├───Videos-7
│ │ ├───Videos-8
│ │ ├───Videos-9
│ │ ├───Videos-10
│ │ ├───Videos-11
│ │ ├───Videos-12
│ │ ├───Videos-13
│ │ ├───Videos-14
│ │ └───Videos-15
│ ├───Canal-3
│ │ ├───Videos-1 (.mp4 files in it)
│ │ ├───Videos-2 (.mp4 files in it)
│ │ ├───Videos-3 (.mp4 files in it)
│ │ ├───Videos-4 ...
│ │ ├───Videos-5
│ │ ├───Videos-6
│ │ ├───Videos-7
│ │ ├───Videos-8
│ │ ├───Videos-9
│ │ ├───Videos-10
│ │ ├───Videos-11
│ │ ├───Videos-12
│ │ ├───Videos-13
│ │ ├───Videos-14
│ │ └───Videos-15
│ ├───Canal-4



I want to have a separate folder
\allmusic
where I will have all the music, and the batch file will always export with the name of the song.

all the mp4 files of each separate folder
Videos-1, Videos-2 ... Videos-10...
, will be concatenated separately and then joined with a single song, each separate folder, with one song each. All the songs andVideos
folders in loop, until all my songs are done.

The video created will be exported in a separate folder
\Export-all-Videos


Actions of Batch file :


─Video-15-sec
│ ├───Canal-1
│ │ ├───Videos-1 (concatenate.mp4 files from) + 1 song -> Folder \Export-all-Videos\name of the song.mp4
│ │ ├───Videos-2 (concatenate.mp4 files from) + 1 song -> Folder \Export-all-Videos\name of the song.mp4
│ │ ├───Videos-3 (concatenate.mp4 files from) + 1 song -> Folder \Export-all-Videos\name of the song.mp4
│ │ ├───Videos-4 ...
│ │ ├───Videos-5
│ │ ├───Videos-6
│ │ ├───Videos-7



I hope someone has a solution for this.


Thank you very much


-
ffmpeg generate thumbnail every interval including the first second
24 décembre 2018, par SalmanI am current using this
ffmpeg -i original.mp4 -ss 00:00:01 -vframes 1 posters/poster%d.png
to generate a poster after each 20 seconds.
Currently its generating at 00:20 - 00:40 - 00:60 time, but, i want to take image at 00:01 also
for example : 00:01 - 00:20 - 00:40 - 00:60