meta données pour cette page
OpenCV 3.2 + GStreamer Linux
Installer CMake
sudo apt-get install cmake
Installer GStreamer 1.0
sudo apt-get install libgstreamer-plugins-bad1.0-0 libgstreamer-plugins-base1.0-0 libgstreamer-plugins-base1.0-0-dev libgstreamer1.0 libgstreamer1.0dev libgstreamer-plugins-base1.0-dev libgtk-3-dev
Récuperer les sources d'OpenCV
cd ~/<my_working_directory> git clone https://github.com/opencv/opencv.git git clone https://github.com/opencv/opencv_contrib.git
Créer un répertoire Temporaire de construction :
cd ~/opencv mkdir build cd build
Préparer la compilation CMake :
cmake -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=/usr/local -D OPENCV_EXTRA_MODULES_PATH=../../opencv_contrib/modules -D WITH_GSTREAMER=ON .
Compiler
make -j8
Installer opencv:
sudo make install
Sources :
http://docs.opencv.org/trunk/d7/d9f/tutorial_linux_install.html
OpenCV 3.2 + GStreamer Windows
Téléchargez et installez cmake
Téléchargez et Installez GStreamer https://gstreamer.freedesktop.org/
Téléchargez les sources d'OpenCV
git clone https://github.com/opencv/opencv.git
Ajoutez la variable d’environnement GSTREAMER_DIR à votre PATH (exemple GSTREAMER_DIR=C:\Gstreamer\1.0\x86)
lancez cmake-gui
Dans la case where is the source code renseignez l'emplacement des sources clonées. (Dans mon cas D:/opencv)
Dans la case where to build the binaries renseignez l'emplacement où builder. (Dans mon cas D:/opencv/build)
Appuyez sur Configure (Plusieurs lignes en rouge devrait apparaitre)
Verifiez que les emplacement de GStreamer ont bel et bien été renseignés en déroulant la ligne GSTREAMER
Rappuyez sur Configure les lignes rouges devrait se transformer en blanches
Puis appuyez sur Generate
Ouvrez la solution OpenCV.sln dans le répertoire build
Choisissez “Debug” puis “Build” et enfin “Build Solution”
Répetez l'opération en choissant “Release”
Monter un dossier local sur une lettre de lecteur
Ajouter un lecteur local
subst S: C:\Windows
Supprimer un lecteur local
subst S: /D
Lister les associations aux lecteurs actives
subst
Documentation :
Associe un chemin à une lettre de lecteur. SUBST [lect1: [lect2:]chemin] SUBST lect1: /D lect1: Lecteur virtuel auquel vous voulez affecter un chemin. [lect2:]chemin Lecteur physique et chemin que vous voulez affecter à un lecteur virtuel. /D Supprime un lecteur substitué (virtuel). SUBST sans paramètres affiche la liste des lecteurs virtuels en cours.
https://forum.pcastuces.com/monter_un_dossier_local_sur_une_lettre_de_lecteur-f3s19119.htm
Git ignore all bin directories
The way to ignore all directories called bin anywhere below the current level in a directory tree is with a .gitignore file with the pattern:
bin/
In the man page, there an example of ignoring a directory called foo using an analogous pattern.
Edit: If you already have any bin folders in your git index which you no longer wish to track then you need to remove them explicitly. Git won't stop tracking paths that are already being tracked just because the now match a new .gitignore pattern. Execute a folder remove (rm) from index only (–cached) recursivelly (-r). Command line example for root bin folder:
git rm -r --cached bin
http://stackoverflow.com/questions/1470572/gitignore-ignore-any-bin-directory
Ffmpeg X265
Low rate high latencyy 1280×720 ffmpeg x265 encoding
ffmpeg.exe -f dshow -video_size 1280x720 -framerate 5 -rtbufsize 702000k -pixel_format yuyv422 -i video="Trust HD Webcam" -c:v libx265 -preset medium -bufsize 1000k -crf 46 output.mp4
Low rate high latency 640×360 ffmpeg x265 encoding
ffmpeg.exe -f dshow -video_size 1280x720 -framerate 5 -rtbufsize 702000k -pixel_format yuyv422 -i video="Trust HD Webcam" -c:v libx265 -preset slow -bufsize 1000k -vf scale=-1:360 -crf 35 output.mp4
Low rate high latency 1280×720 ffmpeg vp9 encoding
ffmpeg.exe -f dshow -video_size 1280x720 -framerate 5 -rtbufsize 702000k -pixel_format yuyv422 -i video="Trust HD Webcam" -c:v libvpx-vp9 -b:v 30k output.webm
sources :
https://trac.ffmpeg.org/wiki/DirectShow
https://trac.ffmpeg.org/wiki/Encode/H.265
https://www.virag.si/2012/01/web-video-encoding-tutorial-with-ffmpeg-0-9/