
Recherche avancée
Autres articles (67)
-
Personnaliser en ajoutant son logo, sa bannière ou son image de fond
5 septembre 2013, parCertains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;
-
Les tâches Cron régulières de la ferme
1er décembre 2010, parLa gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
Le super Cron (gestion_mutu_super_cron)
Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...) -
Les autorisations surchargées par les plugins
27 avril 2010, parMediaspip core
autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs
Sur d’autres sites (10189)
-
ffmpeg crop with negative offset
12 août 2020, par AjouveI have a nodejs application which is cropping videos using ffmpeg


From time to time I have an error because I am trying to crop out of the video, see attached image where the black is the video and in red the crop zone. My final video has to be a square.




If I am replacing the negative offset with 0 the final result will not be a square.


I just need to add a black background on the non-existing part


This is my actual code


const cropVideo = (buffer, width, height, x, y) => {

 const inputFile = tmp.fileSync();
 const outputFile = tmp.fileSync();

 fs.writeFileSync(inputFile.name, buffer);

 return new Promise((resolve, reject) => {
 ffmpeg(inputFile.name)
 .videoFilters(`crop=${width}:${height}:${x}:${y}`)
 .format('mp4')
 .on('error', reject)
 .on('end', () => resolve(fs.readFileSync(outputFile.name)))
 .save(outputFile.name);
 })
}



-
How to record all dynamic videos in the process of capturing screen video with ffmpeg from a python program ?
4 décembre 2020, par fengnixI have many robotframework test cases and in the first case, a ffmpeg command like the following is invoked to record the whole running process :


ffmpeg -framerate 30 -f gdigrab -i desktop -c:v libx264rgb -crf 0 -preset ultrafast output.mkv



Whenever I firstly run all cases and then manuually run the above command from an addition command console, the recorded video always looks fine, it looks like all contents on the screen can be correctly captured.


However, once I execute the command the same as the above one in the first case by call the following code :


p=subprocess.Popen(cmd, shell=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE)



and then in the final test case the record process is stopped by calling the following code to tell ffmpeg that we want to stop the recording :


p.stdin.write(bytes("q",'UTF-8')) 



the final result video only contain correct contents of the "start" and the "end" of the whole process, but all other contents no longer changed and seemd just a static image, which means all the dynamic effects on the screen cannot be captured.


Could anyone be so kind as to let me know what the matter is and how to solve it ?


-
Crop video into a 4x4 grid/tiles/matrix efficiently via command-line ffmpeg ?
22 avril 2017, par DylanHello Stackoverflow community !
I dread having to ask questions, but there seems to be no efficient way to take a single input video and apply a matrix transformation/split the video into equal sized pieces, preferably 4x4=16 segments per input.
I tried using all the libraries such as ffmpeg and mencoder, but having 16 outputs can be as slow as 0.15x. The goal of my project is the split the video into 16 segments, rearrange those segments and combine back into a final video ; later reversing the process in HTML5 canvas. Here is a picture to help you understand what I am talking about :
the source but also the final destination after reorganizing the piecesI do not believe you can do this all in one command, so my goal is to crop into 16 mapped outputs quickly, then reassemble them in a different order. But I can do the other parts myself. Ideally there would be a way to move pixel blocks eg 100x100 and just move them around. My math is not strong enough..
I really appreciate the work you guys do !admin@dr.com