怎么用java获取摄像头的图片的流??

qq_34384284 2017-03-29 11:02:59
我想做人脸识别,想要在摄像头开启之后获取图片的流,将图片传到接口,然后返回我需要的值,但是我百度了半天都没找到怎么获取图片的流,求大神~~
...全文
505 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
attilax 2017-03-29
  • 打赏
  • 举报
回复
java调用opencv类库即可。。 private static void t2() { OpencvUtil.ini(); //open camera source VideoCapture capture=new VideoCapture(1); //获取整个帧数 Mat frame=new Mat(); boolean stop=false; // 遍历每一帧 while (true) { // 尝试读取下一帧 boolean read = capture.read(frame); System.out.println(" cap read rzt:"+read); // if (!read) // break; Highgui.imwrite("d:\\0clr\\video"+filex.getUUidName()+".jpg", frame); // Highgui..imshow("Extracted Frame",frame); // 引入延迟 core.sleep(1000); System.out.println( filex.getUUidName()); } } OpenCV成长之路(10):视频的处理 - 文章 - 伯乐在线.html 作者:: 绰号:老哇的爪子claw of Eagle 偶像破坏者Iconoclast image-smasher 捕鸟王"Bird Catcher  kok  虔诚者Pious 宗教信仰捍卫者 Defender Of the Faith. 卡拉卡拉红斗篷 Caracalla red cloak 万兽之王 简称:: Emir Attilax Akbar 埃米尔 阿提拉克斯 阿克巴 全名::Emir Attilax Akbar bin Mahmud bin  attila bin Solomon bin adam Al Rapanui 埃米尔 阿提拉克斯 阿克巴 本 马哈茂德 本 阿提拉 本 所罗门 本亚当  阿尔 拉帕努伊 常用名:艾提拉(艾龙),  EMAIL:1466519819@qq.com     头衔:uke总部o2o负责人,全球网格化项目创始人, uke交友协会会长  uke捕猎协会会长 Emir Uke部落首席大酋长,   uke宗教与文化融合事务部部长, uke宗教改革委员会副主席 uke制度与重大会议委员会委员长,uke保安部首席大队长,uke制度检查委员会副会长,   uke 首席cto   软件部门总监 技术部副总监  研发部门总监主管  产品部副经理 项目部副经理   uke科技研究院院长uke软件培训大师   uke波利尼西亚区大区连锁负责人 汤加王国区域负责人 uke克尔格伦群岛区连锁负责人,莱恩群岛区连锁负责人,uke布维岛和南乔治亚和南桑威奇群岛大区连锁负责人  Uke软件标准化协会理事长理事长 Uke 数据库与存储标准化协会副会长   uke终身教育学校副校长   Uke医院 与医学院方面的创始人  uec学院校长, uecip图像处理机器视觉专业系主任   uke文档检索专业系主任 Uke图像处理与机器视觉学院首席院长 Uke 户外运动协会理事长  度假村首席大村长   uke出版社编辑总编   转载请注明来源:attilax的专栏  ?http://blog.csdn.net/attilax --Atiend  v8
attilax 2017-03-29
  • 打赏
  • 举报
回复
Atitit 获取本机图像设备视频设备列表 设备检索列表解决方案 设备管理器 用“wmic” 命令检测被感染主机是否有摄像头。 检测列表图像设备摄像头 wmic path win32_pnpsigneddriver where DeviceClass='image' wmic path win32_pnpsigneddriver where DeviceClass='image' get Description,DeviceClass,DeviceName,FriendlyName Description DeviceClass DeviceName FriendlyName USB 视频设备 IMAGE USB 视频设备 Integrated Camera USB 视频设备 IMAGE USB 视频设备 USB2.0 PC CAMERA [global switches] <command> The following global switches are available: /NAMESPACE Path for the namespace the alias operate against. /ROLE Path for the role containing the alias definitions. /NODE Servers the alias will operate against. /IMPLEVEL Client impersonation level. /AUTHLEVEL Client authentication level. /LOCALE Language id the client should use. /PRIVILEGES Enable or disable all privileges. /TRACE Outputs debugging information to stderr. /RECORD Logs all input commands and output. /INTERACTIVE Sets or resets the interactive mode. /FAILFAST Sets or resets the FailFast mode. /USER User to be used during the session. /PASSWORD Password to be used for session login. /OUTPUT Specifies the mode for output redirection. /APPEND Specifies the mode for output redirection. /AGGREGATE Sets or resets aggregate mode. /AUTHORITY Specifies the <authority type> for the connection. /?[:<BRIEF|FULL>] Usage information. For more information on a specific global switch, type: switch-name /? The following alias/es are available in the current role: ALIAS - Access to the aliases available on the local system BASEBOARD - Base board (also known as a motherboard or system board) management. BIOS - Basic input/output services (BIOS) management. BOOTCONFIG - Boot configuration management. CDROM - CD-ROM management. COMPUTERSYSTEM - Computer system management. CPU - CPU management. CSPRODUCT - Computer system product information from SMBIOS. DATAFILE - DataFile Management. DCOMAPP - DCOM Application management. DESKTOP - User's Desktop management. DESKTOPMONITOR - Desktop Monitor management. DEVICEMEMORYADDRESS - Device memory addresses management. DISKDRIVE - Physical disk drive management. DISKQUOTA - Disk space usage for NTFS volumes. DMACHANNEL - Direct memory access (DMA) channel management. ENVIRONMENT - System environment settings management. FSDIR - Filesystem directory entry management. GROUP - Group account management. IDECONTROLLER - IDE Controller management. IRQ - Interrupt request line (IRQ) management. JOB - Provides access to the jobs scheduled using the schedule service. LOADORDER - Management of system services that define execution dependencies. LOGICALDISK - Local storage device management. LOGON - LOGON Sessions. MEMCACHE - Cache memory management. MEMORYCHIP - Memory chip information. MEMPHYSICAL - Computer system's physical memory management. NETCLIENT - Network Client management. NETLOGIN - Network login information (of a particular user) management. NETPROTOCOL - Protocols (and their network characteristics) management. NETUSE - Active network connection management. NIC - Network Interface Controller (NIC) management. NICCONFIG - Network adapter management. NTDOMAIN - NT Domain management. NTEVENT - Entries in the NT Event Log. NTEVENTLOG - NT eventlog file management. ONBOARDDEVICE - Management of common adapter devices built into the motherboard (system board). OS - Installed Operating System/s management. PAGEFILE - Virtual memory file swapping management. PAGEFILESET - Page file settings management. PARTITION - Management of partitioned areas of a physical disk. PORT - I/O port management. PORTCONNECTOR - Physical connection ports management. PRINTER - Printer device management. PRINTERCONFIG - Printer device configuration management. PRINTJOB - Print job management. PROCESS - Process management. PRODUCT - Installation package task management. QFE - Quick Fix Engineering. QUOTASETTING - Setting information for disk quotas on a volume. RDACCOUNT - Remote Desktop connection permission management. RDNIC - Remote Desktop connection management on a specific network adapter. RDPERMISSIONS - Permissions to a specific Remote Desktop connection. RDTOGGLE - Turning Remote Desktop listener on or off remotely. RECOVEROS - Information that will be gathered from memory when the operating system fails. REGISTRY - Computer system registry management. SCSICONTROLLER - SCSI Controller management. SERVER - Server information management. SERVICE - Service application management. SHADOWCOPY - Shadow copy management. SHADOWSTORAGE - Shadow copy storage area management. SHARE - Shared resource management. SOFTWAREELEMENT - Management of the elements of a software product installed on a system. SOFTWAREFEATURE - Management of software product subsets of SoftwareElement. SOUNDDEV - Sound Device management. STARTUP - Management of commands that run automatically when users log onto the computer system. SYSACCOUNT - System account management. SYSDRIVER - Management of the system driver for a base service. SYSTEMENCLOSURE - Physical system enclosure management. SYSTEMSLOT - Management of physical connection points including ports, slots and peripherals, and proprietary connections points. TAPEDRIVE - Tape drive management. TEMPERATURE - Data management of a temperature sensor (electronic thermometer). TIMEZONE - Time zone data management. UPS - Uninterruptible power supply (UPS) management. USERACCOUNT - User account management. VOLTAGE - Voltage sensor (electronic voltmeter) data management. VOLUME - Local storage volume management. VOLUMEQUOTASETTING - Associates the disk quota setting with a specific disk volume. VOLUMEUSERQUOTA - Per user storage volume quota management. WMISET - WMI service operational parameters management. For more information on a specific alias, type: alias /? CLASS - Escapes to full WMI schema. PATH - Escapes to full WMI object paths. CONTEXT - Displays the state of all the global switches. QUIT/EXIT - Exits the program. For more information on CLASS/PATH/CONTEXT, type: (CLASS | PATH | CONTEXT) /? 作者:: 绰号:老哇的爪子claw of Eagle 偶像破坏者Iconoclast image-smasher 捕鸟王"Bird Catcher  kok  虔诚者Pious 宗教信仰捍卫者 Defender Of the Faith. 卡拉卡拉红斗篷 Caracalla red cloak 万兽之王 简称:: Emir Attilax Akbar 埃米尔 阿提拉克斯 阿克巴 全名::Emir Attilax Akbar bin Mahmud bin  attila bin Solomon bin adam Al Rapanui 埃米尔 阿提拉克斯 阿克巴 本 马哈茂德 本 阿提拉 本 所罗门 本亚当  阿尔 拉帕努伊 常用名:艾提拉(艾龙),  EMAIL:1466519819@qq.com     头衔:uke总部o2o负责人,全球网格化项目创始人, uke交友协会会长  uke捕猎协会会长 Emir Uke部落首席大酋长,   uke宗教与文化融合事务部部长, uke宗教改革委员会副主席 uke制度与重大会议委员会委员长,uke保安部首席大队长,uke制度检查委员会副会长,   uke 首席cto   软件部门总监 技术部副总监  研发部门总监主管  产品部副经理 项目部副经理   uke科技研究院院长uke软件培训大师   uke波利尼西亚区大区连锁负责人 汤加王国区域负责人 uke克尔格伦群岛区连锁负责人,莱恩群岛区连锁负责人,uke布维岛和南乔治亚和南桑威奇群岛大区连锁负责人  Uke软件标准化协会理事长理事长 Uke 数据库与存储标准化协会副会长   uke终身教育学校副校长   Uke医院 与医学院方面的创始人  uec学院校长, uecip图像处理机器视觉专业系主任   uke文档检索专业系主任 Uke图像处理与机器视觉学院首席院长 Uke 户外运动协会理事长  度假村首席大村长   uke出版社编辑总编   转载请注明来源:attilax的专栏  ?http://blog.csdn.net/attilax --Atiend  v8

50,530

社区成员

发帖
与我相关
我的任务
社区描述
Java相关技术讨论
javaspring bootspring cloud 技术论坛(原bbs)
社区管理员
  • Java相关社区
  • 小虚竹
  • 谙忆
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧