
Recherche avancée
Médias (91)
-
Les Miserables
9 décembre 2019, par
Mis à jour : Décembre 2019
Langue : français
Type : Textuel
-
VideoHandle
8 novembre 2019, par
Mis à jour : Novembre 2019
Langue : français
Type : Video
-
Somos millones 1
21 juillet 2014, par
Mis à jour : Juin 2015
Langue : français
Type : Video
-
Un test - mauritanie
3 avril 2014, par
Mis à jour : Avril 2014
Langue : français
Type : Textuel
-
Pourquoi Obama lit il mes mails ?
4 février 2014, par
Mis à jour : Février 2014
Langue : français
-
IMG 0222
6 octobre 2013, par
Mis à jour : Octobre 2013
Langue : français
Type : Image
Autres articles (90)
-
L’utiliser, en parler, le critiquer
10 avril 2011La première attitude à adopter est d’en parler, soit directement avec les personnes impliquées dans son développement, soit autour de vous pour convaincre de nouvelles personnes à l’utiliser.
Plus la communauté sera nombreuse et plus les évolutions seront rapides ...
Une liste de discussion est disponible pour tout échange entre utilisateurs. -
Mediabox : ouvrir les images dans l’espace maximal pour l’utilisateur
8 février 2011, parLa visualisation des images est restreinte par la largeur accordée par le design du site (dépendant du thème utilisé). Elles sont donc visibles sous un format réduit. Afin de profiter de l’ensemble de la place disponible sur l’écran de l’utilisateur, il est possible d’ajouter une fonctionnalité d’affichage de l’image dans une boite multimedia apparaissant au dessus du reste du contenu.
Pour ce faire il est nécessaire d’installer le plugin "Mediabox".
Configuration de la boite multimédia
Dès (...) -
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 (9831)
-
Pause a FFmpeg encoding in a Python Popen subprocess on Windows
5 décembre 2020, par CasualDemonI am trying to pause an encode of FFmpeg while it is in a non-shell subprocess (This is important to how it plays into a larger program). This can be done by presssing the "Pause / Break" key on the keyboard by itself, and I am trying to send that to Popen.


The command itself must be cross platform compatible, so I cannot wrap it in any way, but I can send signals or run functions that are platform specific as needed.


I looked at how to send a "Ctrl+Break" to a subprocess via pid or handler and it suggested to send a signal, but that raised a "ValueError : Unsupported signal : 21"


from subprocess import Popen, PIPE
import signal


if __name__ == '__main__':
 command = "ffmpeg.exe -y -i example_video.mkv -map 0:v -c:v libx265 -preset slow -crf 18 output.mkv"
 proc = Popen(command, stdin=PIPE, shell=False)

 try:
 proc.send_signal(signal.SIGBREAK)
 finally:
 proc.wait()



Then attempted to use GenerateConsoleCtrlEvent to create a Ctrl+Break event as described here https://docs.microsoft.com/en-us/windows/console/generateconsolectrlevent


from subprocess import Popen, PIPE
import ctypes


if __name__ == '__main__':
 command = "ffmpeg.exe -y -i example_video.mkv -map 0:v -c:v libx265 -preset slow -crf 18 output.mkv"
 proc = Popen(command, stdin=PIPE, shell=False)

 try:
 ctypes.windll.kernel32.GenerateConsoleCtrlEvent(1, proc.pid)
 finally:
 proc.wait()



I have tried
psutil
pause feature, but it keeps the CPU load really high even when "paused".

Even though it wouldn't work with the program overall, I have at least tried setting
creationflags=CREATE_NEW_PROCESS_GROUP
which makes the SIGBREAK not error, but also not pause it. For the Ctrl-Break event will entirely stop the encode instead of pausing it.

-
c# RTSP audio to FFMPEG to SpeechRecognitionEngine
18 avril 2016, par MrH40XXI’m trying to get an audiostream (from any source file/other stream/...) into the microsoft speech recognition engine.
So far I’ve got :
ffmpeg.exe -rtsp_transport tcp -i rtsp ://%_return1%/audio -acodec pcm_u16le -f rtp rtp ://localhost:2222
Then I have inside my code :
SpeechRecognitionEngine _engine = new SpeechRecognitionEngine(CultureInfo.CurrentCulture);
this._engine.SetInputToAudioStream(this._rtpClient.AudioStream, new SpeechAudioFormatInfo(16000, AudioBitsPerSample.Sixteen, AudioChannel.Mono));Then I have the events registered :
this._engine.SpeechRecognized += this.SpeechRegocnized;
this._engine.SpeechDetected += this.EngineOnSpeechDetected;I’m not sure about the codec settings... I’ve tried other codecs but doesn’t work.
-
Using OpenCV 2.4.4 with FFmpeg in Windows
22 décembre 2015, par aardvarkkI know there are other questions dealing with FFmpeg usage in OpenCV, but most of them appear to be outdated.
By opening up the makefiles in CMake, I can verify that I’ve got the
WITH_FFMPEG
flag on. My output folder for the OpenCV build contains abin
folder, within which areDebug
andRelease
folders, each containing a copy of a .dll file entitledopencv_ffmpeg244.dll
. I can step into the source code of OpenCV when I create a VideoWriter and verify that the function pointers to the .dll get filled correctly. That much appears to be working.If I use the FOURCC code of CV_FOURCC_PROMPT, the following codecs work properly :
- Microsoft Video 1
- Intel IYUV codec
- Logitech Video (I420)
- Cinepak Codec by Radius
- Full Frames (Uncompressed)
The following codecs do not work properly (ie. produce a 0kb video file) :
- Microsoft RLE
If my understanding is correct, using FFMPEG should allow for encoding video using a whole bunch of new codecs (x264, DIVX, XVID, and so on). However, none of these appear in the prompt. Manually setting them by their FOURCC codes using the macro
CV_FOURCC(...)
also doesn’t work. For instance, using this :CV_FOURCC('X','2','6','4')
produces the message :Could not find encoder for codec id 28: Encoder not found
and makes a video file of size 0kb.
Using this :
CV_FOURCC('X','V','I','D')
produces no error message, and makes a video file of 6kb that will not play in Windows Media Player or VLC.I tried manually downloaded the Xvid codec from Xvid.org. Once that was installed, it appeared under the VFW selection in the prompt, and the encoding worked properly. So it’s close to a solution, but if I try to set the FOURCC code directly, it still fails as above ! I have to pick it from the prompt every time. Isn’t FFmpeg supposed to include a whole bunch of codecs ? If so, why am I manually downloading the codec instead of using the one built into FFmpeg ?
What am I missing here ? Is there a way to check that FFMPEG is "enabled" ? It seems like the only codecs available in the prompt are VFW codecs, not the FFMPEG ones. The
.dll
has been built and is sitting in the same folder as the executable, but it appears it’s not being used in any way.Lots of related questions here. Hoping to find somebody knowledgeable about the FFmpeg implementation in OpenCV and with some knowledge of how all of these pieces fit together.