Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. International
  3. Chinese
  4. QCameraImageCapture在Windows下很多接口返回不正确

QCameraImageCapture在Windows下很多接口返回不正确

Scheduled Pinned Locked Moved Chinese
4 Posts 4 Posters 3.9k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    l4ever
    wrote on last edited by
    #1

    我最近在Windows 7上用QCameraImageCapture做一些摄像头视频抓图,基本上是基于QT5.2中自带的示例camera,但在设置一些属性时,发现很多接口都不支持。如imagecapture->supportedBufferFormats(),imagecapture->supportedImageCodecs(),imagecapture->supportedImageCodecs()这几个返回的列表都是空的,设置抓图到缓冲区imageCapture->setCaptureDestination(QCameraImageCapture::CaptureToFile)的调用也是失败的等。我想请问一下各位,是不是QCamera没有实现这些接口?我查看源代码,发现QCameraImageCaptureControl等控制类的实现都是纯虚函数,不知道这其中的原理是怎样的?谢谢解答!

    F 1 Reply Last reply
    0
    • L l4ever

      我最近在Windows 7上用QCameraImageCapture做一些摄像头视频抓图,基本上是基于QT5.2中自带的示例camera,但在设置一些属性时,发现很多接口都不支持。如imagecapture->supportedBufferFormats(),imagecapture->supportedImageCodecs(),imagecapture->supportedImageCodecs()这几个返回的列表都是空的,设置抓图到缓冲区imageCapture->setCaptureDestination(QCameraImageCapture::CaptureToFile)的调用也是失败的等。我想请问一下各位,是不是QCamera没有实现这些接口?我查看源代码,发现QCameraImageCaptureControl等控制类的实现都是纯虚函数,不知道这其中的原理是怎样的?谢谢解答!

      F Offline
      F Offline
      Ferryun
      wrote on last edited by
      #2

      @l4ever 是啊,最近我也碰到这些问题,你后来搞定了么,官方提供的这个Demo很不完善,camera->isCaptureModeSupported(QCamera::CaptureVideo)这个函数在windows下面工作不正常,一直返回false,苹果下面是true
      你最近还有搞camera方面的开发么,希望多交流

      1 Reply Last reply
      0
      • jiancaiyangJ Offline
        jiancaiyangJ Offline
        jiancaiyang
        wrote on last edited by
        #3

        看换成Qt 5.5 beta能否解决问题?

        我们自己的论坛:http://qtdream.com
        擅长三维角色仿真动画。

        1 Reply Last reply
        0
        • Z Offline
          Z Offline
          zhxt
          wrote on last edited by
          #4
          1. Qt Multimedia功能在window平台主要有两个插件实现: DirectShow(Microsoft DirectShow API, )和 WMF (Windows Media Foundation)框架。
            这两个实现目前都不完善。 WMF没有提供Camera backend。 DirectShow的Camera backend仅有很少的基本功能实现。
            详见:
            http://doc.qt.io/qt-5/qtmultimedia-windows.html
            https://wiki.qt.io/Qt_Multimedia_Backends

          2. controls 是通过service的 requestControl() 来获取对应backend实现的。

          Qt Developer

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved