捕获图像时获取/设置视频分辨率 [英] Get/set video resolution when capturing image

查看:266
本文介绍了捕获图像时获取/设置视频分辨率的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用一些主要基于此的代码从网络摄像头捕获图像:使用示例抓取器

I'm capturing images from my webcam with some code that mainly bases on this: Using the Sample Grabber.

在这里,我仅获得默认分辨率640x480,而连接的相机能够显示更多(其他捕获应用程序显示更高的分辨率)。

Here I only get the default resolution of 640x480 while the connected camera is able to show more (other capture applications show a bigger resolution).

因此,我该如何:


  1. 检索可用分辨率的列表

  2. 设置这些分辨率之一以便捕获的图像附带?


推荐答案

IAMStreamConfig 接口列出功能,并允许您选择感兴趣的分辨率。枚举未连接但尚未固定的针脚上的媒体类型将列出您相机支持的广告特定媒体类型(AMD分辨率)。

IAMStreamConfig interface lists capabilities and lets you select resolution of interest. enumerating media types on an unconnected yet pin will list you specific media types (amd resolutions) the camera advertises as supported.

更多信息(链接):


  • 使用DirectShow的视频录制分辨率

  • < a href = https://stackoverflow.com/questions/8213574/video-capture-output-always-in-320x240-despite-changing-resolution/8216359#8216359>尽管分辨率有所变化,视频捕获输出仍始终为320x240

  • Video recording resolution using DirectShow
  • Video Capture output always in 320x240 despite changing resolution

这篇关于捕获图像时获取/设置视频分辨率的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆