
Recherche avancée
Autres articles (50)
-
XMP PHP
13 mai 2011, parDixit Wikipedia, XMP signifie :
Extensible Metadata Platform ou XMP est un format de métadonnées basé sur XML utilisé dans les applications PDF, de photographie et de graphisme. Il a été lancé par Adobe Systems en avril 2001 en étant intégré à la version 5.0 d’Adobe Acrobat.
Étant basé sur XML, il gère un ensemble de tags dynamiques pour l’utilisation dans le cadre du Web sémantique.
XMP permet d’enregistrer sous forme d’un document XML des informations relatives à un fichier : titre, auteur, historique (...) -
Déploiements possibles
31 janvier 2010, parDeux types de déploiements sont envisageable dépendant de deux aspects : La méthode d’installation envisagée (en standalone ou en ferme) ; Le nombre d’encodages journaliers et la fréquentation envisagés ;
L’encodage de vidéos est un processus lourd consommant énormément de ressources système (CPU et RAM), il est nécessaire de prendre tout cela en considération. Ce système n’est donc possible que sur un ou plusieurs serveurs dédiés.
Version mono serveur
La version mono serveur consiste à n’utiliser qu’une (...) -
Ajouter notes et légendes aux images
7 février 2011, parPour pouvoir ajouter notes et légendes aux images, la première étape est d’installer le plugin "Légendes".
Une fois le plugin activé, vous pouvez le configurer dans l’espace de configuration afin de modifier les droits de création / modification et de suppression des notes. Par défaut seuls les administrateurs du site peuvent ajouter des notes aux images.
Modification lors de l’ajout d’un média
Lors de l’ajout d’un média de type "image" un nouveau bouton apparait au dessus de la prévisualisation (...)
Sur d’autres sites (5435)
-
How to combine software and hardware video filters in FFmpeg, e.g. using CUDA/nvenc ? [closed]
3 novembre 2020, par bemoOne function of my Windows software project requires capturing video at 100fps for 10 seconds simultaneously from 4 machine vision cameras. I'm initially storing the video data in uncompressed/raw video files, one per camera, where these files are just concatenated raw frame data from the camera (in Bayer rggb8 format).


After capturing, I need to convert these into a compressed format (I don't do this at the time of capture to avoid clogging up the CPU and minimise the risk of dropping frames). I'm using ffmpeg for this and I've arrived at this command that gives satisfactory results :


ffmpeg.exe -y -an -f rawvideo -pixel_format bayer_rggb8 -video_size 2048x1536 -framerate 100 -i input.raw -codec:v libx264 -preset medium -crf 17 -vf "vignette=mode=backward:a=PI/7,lenscorrection=k1=-0.14,unsharp=13:13:1.5:5:5:0,hqdn3d,format=yuv420p" output.mp4


Since the above uses software encoding it is pretty slow and takes several minutes to complete the 4x10s videos. I need it to be a lot faster to avoid the user having to wait too long within my app for transcoding to finish. So, I want to speed this up using ffmpeg's hardware acceleration.


I've purchased a nvenc/CUDA-compatible GeForce card, have compiled ffmpeg with CUDA support and have experimented with the
h264_nvenc
encoder. Basic encoding works (without encoding parameters and filters) but I've got two specific problems :

- 

-crf
(and possibly-present
) aren't supported by h264_nvenc, so what is the hardware-accelerated equivalent to-preset medium -crf 17
?- How can I apply filters to reduce vignetting, correct lens distortion (2 cameras are using fish-eye lenses), sharpen the images and then de-noise them, whilst still significantly improving overall encoding speed ? I understand some filters aren't supported by hardware so I need to use
hwupload_cuda
andhwdownload
to move data between video memory and main memory, but I can't get the exact encoding incantation working and I'm also worried I'll lose all the hardware-acceleration benefit if I have to do too much in software.






I'm open to using alternatives to nvenc if necessary - e.g. VAAPI, libmfx/QuickSync or OpenCL as mentioned on ffmpeg's hardware acceleration page.


-
How to split ffmpeg output into multiple files ?
15 novembre 2020, par Genius BillionaireWhat I want to happen : the equivalent of this :
split -n 4 output.mp4
, which generates 4 files. Only the first file is "valid mp4" that you can play. The other 3 files rely on the previous file.

A similar request can be seen here : https://lists.ffmpeg.org/pipermail/ffmpeg-user/2013-May/015090.html


Why I want this to happen : running FFMPEG in the browser, which means 1) file size limit, 2) I don't have the Linux command
split
to help me out, just FFMPEG. If I can get FFMPEG to output files of X MB each, I can iteratively delete files as soon as I've read them.

EDIT : as a commenter asked, yes it is possible to run several ffmpeg commands if necessary.


The right solution is not using segments. The following example command generates several 4 valid mp4 files. That's not exactly what I want.

ffmpeg -i ../flv.flv -segment_time 5 -f segment -t 20 %d.mp4


This other solution also does not work (it's the same output as previous incorrect solution) :


ffmpeg -i ../flv.flv -ss 00:00:00 -t 5 1.mp4


ffmpeg -i ../flv.flv -ss 00:00:05 -t 5 2.mp4


-
How to use sexagesimal syntax in arguments of FFmpeg or if impossible how to convert it in Windows CMD shell
6 décembre 2020, par Link-akroQuestion updated 2020-12-06 to enlarge the scope without discarding the prior answer which applies to both prior and larger cases.


I had trouble to provide a sexagesimal time (
HH:MM:SS.mm
) to a filter option that was not an expression. For instancetrim
filter.
It happens there is an escaping rule i did not know yet when i first asked, and was addressed in the first comment by @Gyan.

The problem is universal, but the solution may depend on the shell if we go the scripting route... and i am currently stuck with Windows's CMD.exe.


For instance the following skips one minute and 4 tenths of seconds in all streams as accurately as it can seek each, then invokes the trim filter to keep the segment between one and two minutes of the remaining duration, and do so with two different syntaxes. This example happens to be compatible with both CMD and BASH shells so no escaping hell.


ffmpeg -ss "1:00.4" -i INPUT -vf "trim=start='1\:00':end='120'" OUTPUT



Then how do we achieve the same in the expressions within the filters ?
If we cannot avoid using the scripting of the shell, i am looking for a Windows CMD solution.
I had posted one answer with a piece of script to convert a textual sexagesimal time to a textual decimal fractional time in seconds, which was not useful for the original case, but may apply to more generic cases and in particular to the expressions.


Example of failed attempt with one expression in the
select
filter.

ffmpeg -ss "1:00.4" -i INPUT -vf "select='between(t,1\:00',120)'" OUTPUT



The sexagesimal notation seems to not be supported by ffmpeg filter expressions as i found no reference of it in the documentation nor in SO/web.


I browsed through the list of functions defined in ffmpeg expression library but did not find any way to parse the sexagesimal input there yet, nor any way to use text in its semantics.


However i found some unrelated example that hard-coded some arithmetical expression to provide the numerical decimal amount of seconds equivalent to what was intended, such as
2*60+2
to mean2:02
.

The polynome used above to compute seconds may use preprocessing of shell variable, whichever shell it is, but we need to parse the components of
HH:MM:SS.mm
to put them in those variable first. You know, using bash$var
or cmd%var%
/%~1
styles. Otherwise we may compute the polynome completely in the shell instead of the expression but it is so much trouble for little gain.

So while CMD still exists like an undead and becomes really dead , and while i do not have the opportunity yet to replace it, i wish for an answer that either :


- 

- does not need the shell/script at all, OR
- provide a solution in Windows CMD, although relying on it as little as possible.






Reminder and clarification, the use case assumes that we are given a textual sexagesimal time as input and intend to use it in an expression of ffmpeg filter with as little shell dependency as possible or otherwise satisfy Windows CMD.