一、参考资料

How to Capture and Display Camera Video with Python on Jetson TX2
tegra-cam.py
gstreamer基础教程
英伟达Jetson TX2 /NX/AGX上使用 Python 硬解码网络相机h264视频流

二、板载摄像头相关信息

tx2@tx2:~/Desktop$ python tele_gram.py
Called with args:
Namespace(image_height=1080, image_width=1920, rtsp_latency=200, rtsp_uri=None, use_rtsp=False, use_usb=False, video_dev=1)
OpenCV version: 4.4.0
GST_ARGUS: Creating output stream
CONSUMER: Waiting until producer is connected...
GST_ARGUS: Available Sensor modes :
GST_ARGUS: 2592 x 1944 FR = 29.999999 fps Duration = 33333334 ; Analog Gain range min 1.000000, max 16.000000; Exposure Range min 34000, max 550385000;GST_ARGUS: 2592 x 1458 FR = 29.999999 fps Duration = 33333334 ; Analog Gain range min 1.000000, max 16.000000; Exposure Range min 34000, max 550385000;GST_ARGUS: 1280 x 720 FR = 120.000005 fps Duration = 8333333 ; Analog Gain range min 1.000000, max 16.000000; Exposure Range min 22000, max 358733000;GST_ARGUS: Running with following settings:Camera index = 0 Camera mode  = 1 Output Stream W = 2592 H = 1458 seconds to Run    = 0 Frame Rate = 29.999999
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.
CONSUMER: Producer has connected; continuing.
[ WARN:0] global /home/tx2/panbo/software/opencv-4.4.0/modules/videoio/src/cap_gstreamer.cpp (935) open OpenCV | GStreamer warning: Cannot query video position: status=0, value=-1, duration=-1
Gtk-Message: 17:42:26.830: Failed to load module "canberra-gtk-module"
GST_ARGUS: Cleaning up
CONSUMER: Done Success
GST_ARGUS: Done Success

三、打开板载摄像头

def open_cam_onboard(width, height):gst_elements = str(subprocess.check_output('gst-inspect-1.0'))if 'nvcamerasrc' in gst_elements:# On versions of L4T prior to 28.1, add 'flip-method=2' into gst_strgst_str = ('nvcamerasrc ! ''video/x-raw(memory:NVMM), ''width=(int)2592, height=(int)1458, ''format=(string)I420, framerate=(fraction)30/1 ! ''nvvidconv ! ''video/x-raw, width=(int){}, height=(int){}, ''format=(string)BGRx ! ''videoconvert ! appsink').format(width, height)elif 'nvarguscamerasrc' in gst_elements:gst_str = ('nvarguscamerasrc ! ''video/x-raw(memory:NVMM), ''width=(int)1920, height=(int)1080, ''format=(string)NV12, framerate=(fraction)30/1 ! ''nvvidconv flip-method=2 ! ''video/x-raw, width=(int){}, height=(int){}, ''format=(string)BGRx ! ''videoconvert ! appsink').format(width, height)else:raise RuntimeError('onboard camera source not found!')return cv2.VideoCapture(gst_str, cv2.CAP_GSTREAMER)
参数解释:
gst_str = ('nvarguscamerasrc ! ''video/x-raw(memory:NVMM), ''width=(int)1920, height=(int)1080, ''format=(string)NV12, framerate=(fraction)30/1 ! ''nvvidconv flip-method=2 ! ''video/x-raw, width=(int){}, height=(int){}, ''format=(string)BGRx ! ''videoconvert ! appsink').format(960, 640)
return cv2.VideoCapture(gst_str, cv2.CAP_GSTREAMER)视频流:1920*1080 @30fps
显示窗口:960*640

四、板载摄像头工具包

参考博客 Jetson TX2板载摄像头(二)

Jetson TX2板载摄像头(一)相关推荐

  1. Jetson TX2板载摄像头(二)

    一.参考资料 Jetson TX2板载摄像头(一) 二.板载摄像头工具包 # -------------------------------------------------------- # Ca ...

  2. Jetson TX1板载摄像头测试

    Data: 2016.12.21 Author: cjh Theme: Test the default camera 继上一篇完成了Jetson TX1的刷机之后,想测测板子上相关的硬件,自己最好奇 ...

  3. Jetson TX2板载相机opencv调用打开

    查看全文 http://www.taodudu.cc/news/show-1217164.html 相关文章: 单独像对相对定向的部分基本概念 单独像对相对定向元素解析 模型点计算 连续法相对定向元素 ...

  4. 【玩转Jetson TX2 NX】(七)TX2 NX YoLoV4环境搭建+板载摄像头实时目标检测(详细教程+错误解决)

    1 YoLoV4环境搭建 直接下载,然后解压,最后移动到Jetson TX2 NX,如图所示,darknet下载链接: https://github.com/AlexeyAB/darknet 将解压的 ...

  5. Jetson nano 入手系列之2—板载摄像头IMX219启动

    Jetson nano 入手系列之2-板载摄像头IMX219启动 1.亚克力板安装 2.摄像头启动 3.nvgstcapture常用命令 3.1 Set sensor orientation 3.2 ...

  6. ESP32-CAM 板载摄像头模块进行简单的图像采集和网络传输。

    ESP32-CAM 是一款集成了 Wi-Fi 和图像传感器的开发板,它可以用于实现基于 Arduino 平台的物联网应用和图像处理等项目.本文将介绍如何使用 ESP32-CAM 板载摄像头模块进行简单 ...

  7. Jetson TX2使用USB摄像头

    我使用的是aoni奥尼免驱USB摄像头,在TX2下的ubuntu系统中也不用安装驱动,使用方便配置简单. 输入: ls /dev/video* 将检测到两个摄像头,/dev/video0 是 TX2 ...

  8. Jetson TX1板载相机opencv调用打开

    Jetson TX1 打开板载相机方式. 相关链接1:https://devtalk.nvidia.com/default/topic/987537/jetson-tx1/videocapture-f ...

  9. Jetson TX1板载相机调用测试

    在Jetson TX1用Jetpack2.3.1刷了机,一些软件已经自动安装上. 在终端上输入:  nvgstcapture-1.0   即可打开板子上的自带相机. 通过mo:1或者mo:2可以切换i ...

最新文章

  1. 深入理解CSS线性渐变linear-gradient
  2. Hark的数据结构与算法练习之图书馆排序
  3. 将类的定义放在头文件中,把成员函数的实现代码放在一个cpp文件中
  4. java oracle数据备份_Java后台备份oracle数据库脚本
  5. mysql 正则 换行符_MySQL 正则表达式
  6. db2v9/9.5高级应用开发_使用 Vue.js 2.0 开发单页应用
  7. Nginx web服务器搭建
  8. 《编译系统透视:图解编译原理》
  9. java语言的输入输出_java语言的输入输出
  10. macOS 安装postman 中文语言包
  11. oracle11204补丁包,Oracle 11.2.0.4 RAC 最新补丁下载(11.2.0.4.200714)
  12. vfp python_Python dbfpy和FoxPro
  13. 【Mind+ 玩转Maixduino系列0】工欲善其事必先利其器
  14. 12个CSS高级技巧汇总
  15. 数据湖和数据仓库的区别是什么?
  16. 易语言多线程任务分配让不同的线程账号执行不同的多个任务
  17. 2021亚太数学建模竞赛A题简要思路
  18. CAN 错误帧和原理
  19. 微信如何添加企业微信信息服务器地址,企业微信怎么添加管理员 设置方法介绍...
  20. CSDN-Markdown LateX 数学公式

热门文章

  1. android LeanCloud SDK部署
  2. ​高中毕业后应该做些什么才更有意义?
  3. 正确搭配食物让饮食更有营养
  4. 使用dd整盘克隆jetson nano tf卡
  5. 材料与化学数据库分享
  6. 统计学术语及解释(一)
  7. matlab 运动分析,实验二基于matlab的运动分析
  8. java 画正方体直观图_画棱长为2cm的正方体的直观图。
  9. Wiki.js安装部署实操手册
  10. k8s中的Volume