Add avfoundation support for normal OSX build, not just iOS (Bug #4187)
Description
When using QTKit, things like exposure settings and such aren't supported. AVFoundation supports doing this, however.
I hacked with the makefiles in a very minimal way, and I found the following:
- Can't enable QTKit and AVFoundation at the same time, otherwise link errors occur
- Have to add some frameworks in CMakeLists.txt in videoio -- here's what my line that worked was (not sure if there's too many frameworks there, I just copy/pasted settings from IOS):
list(APPEND VIDEOIO_LIBRARIES "-framework Accelerate" "-framework AVFoundation" "-framework CoreGraphics" "-framework CoreMedia" "-framework CoreVideo" )
Once I did this very minimal change, I compiled and was able to set the exposure on the webcam using PROP_IOS_DEVICE_EXPOSURE on my Macbook Pro. I haven't done extensive testing yet, but my understanding is that AVFoundation is mostly identical on iOS and OSX.
Associated revisions
Merge pull request #4187 from SpecLad:chessboard-png
History
Updated by Vadim Pisarevsky almost 10 years ago
- Category changed from imgproc, video to highgui-video
Updated by Maksim Shabunin over 9 years ago
Issue has been transferred to GitHub: https://github.com/Itseez/opencv/issues/4930