linux v4l2 開發筆記

jpeg庫 安裝

缺少libjpeg 錯誤
fatal error: jpeglib.h: No such file or directory
解決方法
Ubuntu Software Center -> search -> libjpeg -> install libjpeg8-dev


yuv查看工具

sudo apt-get install imagemagick
convert -size widthxheight input.yuv output.bmp 

v4l2grab

This is a small command line utility for grabbing JPEGs form V4L2 devices (e.g. USB webcams).

v4l2grap 代碼,依賴包安裝,v4l2grap 用於在v4l2的基礎上使用攝像頭拍攝照片,編譯成功後,使用下面的命令拍攝照片

./v4l2grap -o image.jpg
 1. Install the required libraries (libv4l and libjpeg) and autotools
	 sudo apt-get install libjpeg8-dev libv4l-dev autoconf automake libtool

 2. Clone the repository
	git clone https://github.com/twam/v4l2grab.git
 
 3. Creating autotools files
	./autogen.sh
 
 4. Run configure
	./configure
 
 5. Run make
	make
 
 6. Run make install
	sudo make install
 
安裝方法,參照地址

https://github.com/twam/v4l2grab/tree/master <--- 源碼

https://github.com/twam/v4l2grab/wiki/Installation <--- 安裝方法

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章