Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
38 views

DockKit tracking becomes erratic with increased zoom factor in iOS app

I'm developing an iOS app using DockKit to control a motorized stand. I've noticed that as the zoom factor of the AVCaptureDevice increases, the stand's movement becomes increasingly erratic up and ...
andreas.teich's user avatar
1 vote
0 answers
97 views

How to correctly use RotationCoordiantor and its videoRotationAngleForHorizonLevelPreview to set camera preview orientation

So I'm trying to set camera orientation for AVCaptureVideoPreviewLayer in SwiftUI without deprecated methods (AVCaptureConnection.videoOrientation is deprecated now) but it doesn't work correct: ...
user924's user avatar
  • 11.9k
0 votes
0 answers
17 views

How to select high frame rate to capture Live Photos?

I'm borrowing some code to get higher framerate than the default 30, but not all of these formats support Live Photo and I can't find a way to check for it - any ideas? var bestFormat: AVCaptureDevice....
hyouuu's user avatar
  • 2,501
0 votes
0 answers
49 views

Wanted to add lipstick like effect on lips using Vision and AVFoundation for camera

I wanted to add lipstick like effect on lips using CGMutable path. Detecting face landmarks using vision kit. Landmark.outer lips fill the whole lips, even opened mouth. i wanted to apply on the lips ...
user25559454's user avatar
0 votes
1 answer
78 views

Why is `isDepthDataDeliverySupported` returning false on an iPad Pro using `builtInDualWideCamera`?

I am trying to use the AVCamFilter Apple sample project discussed in this WWDC session to get depth data using the dual camera. The project has built-in features to get depth data from the dual camera....
shim's user avatar
  • 10.1k
0 votes
0 answers
173 views

Can iPhones create a AVCaptureDevice.DiscoverySession with .external devices

With iOS 17, we saw the introduction of using external cameras on iPads. We can get these external cameras as AVCaptureDevices via AVCaptureDevice.DiscoverySession(deviceTypes: [AVCaptureDevice....
David Chopin's user avatar
  • 3,024
2 votes
1 answer
136 views

What is the AVCaptureSession.Preset.photo preset for iPhone 14/15 Pro/Max 48MP main camera?

My iOS app for iPhone configures a capture session with the .builtInWideAngleCamera and AVCaptureSession.Preset.photo. Most modern iPhones have a 12MP main camera, however, the iPhone 14 Pro and 15 ...
jbdev's user avatar
  • 513
1 vote
0 answers
39 views

Collect output devices on c#

Previously i used this code to collect all output devices, but recently i update my code and know this code is not working at the moment because i receive this message error Installing "...
Carl's user avatar
  • 11
1 vote
0 answers
103 views

How to relate intrinsics and distortion from AVDepthData to the current video stream?

I am writing a small test app in the context of Computer Vision. The final application will require using the camera calibration, so for now my test app creates a capture session, enables the delivery ...
sansuiso's user avatar
  • 9,379
2 votes
1 answer
119 views

Shadow moving across camera after setting activeFormat of AVCaptureDevice

So I have a function that essentially walks through the formats of a device, finds the one I want with high resolution and frame rate, then sets that after the camera device inputs have been ...
nickcoding2's user avatar
0 votes
1 answer
106 views

How to scan a barcode with all available back cameras of an iphone at the same time?

What I want: I want to scan for barcodes with all available back cameras of an iPhone at the same time. So the user don't have to care about the distance of the barcode so much. What I tried: I ...
tuvok's user avatar
  • 195
1 vote
0 answers
150 views

Can we control optical zoom value manually for iOS camera?

I want to add an optical zoom level to the custom value for the ios camera, Can we achieve this for all iPhone devices depending on their camera type? I have tried this but I am not sure about this is ...
Akash S's user avatar
  • 27
1 vote
0 answers
96 views

iPhone camera angle difference between iOS15 and iOS16

Hi i'm working on develop iOS custom camera app. Recently I discovered that my camera app works differently on iOS 15 and iOS 16. On iOS 15, the video was recorded without any cropped images, and on ...
chamcham's user avatar
6 votes
0 answers
147 views

Audio Recording Mac app with Visualizations unable to select input device with AudioKit

Hey I wonder if someone can point me in the right direction. I am building a Mac Audio App that I need to perform the following actions Select audio input device Show a live audio graph of device ...
user499846's user avatar
1 vote
0 answers
113 views

How can set Zoom In AVCaptureDevice in Mac OS

I want to add Zoom factor in AVcaptureDevice. But for mac OS i didn't get any solution. in iOS we can use videoZoomFactor this property. but for macOS nothing any property for set zoom. can you please ...
Hiren Dhamecha's user avatar
0 votes
1 answer
140 views

How to get WhiteBalance (Kelvin) from captureOutput

Apple has various ways to change and view the Kelvin of using AVCaptureDevice https://developer.apple.com/documentation/avfoundation/avcapturedevice/white_balance Example: guard let videoDevice = ...
Paul S.'s user avatar
  • 1,352
0 votes
1 answer
144 views

AVCaptureDevice isTorchActive does not work for React Native

I've tried to write my own module to detect is torch turned on/off. According to documentation I've tried to run KVC as below - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object ...
Jaroslaw K.'s user avatar
  • 5,374
0 votes
0 answers
122 views

The issue with Pylance expecting an expression or "." or "(" not being closed is likely due to syntax errors in my code, but where?

Someone suggested this but it DOESN'T work either. In the line AVCaptureDevice.requestAccess (for: .video), the parenthesis around for: .video should be removed as it is not a valid syntax in Python. ...
DSamuelHodge's user avatar
2 votes
1 answer
955 views

Detect when builtInTripleCamera changes lenses?

Background: I'm working on an app that uses videoZoomFactor to zoom in on the camera view by a specific, user-specified amount. I'd like to incorporate using the telephoto and ultra wide lenses. I ...
zakray's user avatar
  • 181
2 votes
0 answers
170 views

iPad Pro M2 model ProRes video recording

I have the following code to determine ProRes and HDR support on iOS devices: extension AVCaptureDevice.Format { var supports10bitHDR:Bool { let mediaType = CMFormatDescriptionGetMediaType(...
Deepak Sharma's user avatar
1 vote
1 answer
102 views

Requesting access with AVCaptureDevice causes a switch in selected tab in tab view

I am trying to add a QR scanner to my app that has a Tab View at the root. It sort of works except for one thing; When the dialog appears to ask the user for permission to use the camera, it also ...
annakodarpa's user avatar
0 votes
1 answer
843 views

Camera zoom level

Is it possible to get the camera zoom level on various device models in iPhone like in built in camera programmatically example 0.5x, 1x, 2x etc? I am unable to find the solution. Anyone can you ...
Ajay K's user avatar
  • 3
1 vote
0 answers
59 views

AVFoundation crash when setting isEnabled on AVCaptureAudioChannel

For some AVCaptureDevices, trying to set isEnabled on an AVCaptureAudioChannel results in a crash: Assertion failed: (pSrcASBD->mChannelsPerFrame == [_internal->audioChannels count]), function -[...
DanM's user avatar
  • 141
0 votes
1 answer
419 views

Why is AVCaptureDevice.maxAvailableVideoZoomFactor so large?

On my iPad with a digital zoom of 5x, the reported captureDevice.maxAvailableVideoZoomFactor for the camera device is 153. Shouldn't it be 5? Am I using the right property to get the max zoom factor?
Denis's user avatar
  • 53
1 vote
0 answers
78 views

AVCapturePhotoOutput with 60 fps and flash on causes image to be over brightened

When using AVCapturePhotoOutput with flashMode On and AVCaptureDevice with minimum frame rate set to 60 fps results in an image that is very over brightened. Using the same configuration with 30 fps ...
Jacob Zyla's user avatar
1 vote
0 answers
42 views

How to detect iPhone device flattened usig camera

I am trying to detect the device flattened to the surface to take pictures like the native camera. Like below Screenshot I tried using CMMotionManager, let motioManager = CMMotionManager() ...
sudheer's user avatar
  • 428
0 votes
1 answer
2k views

How to modify FPS, Bit rate and resolution for the video programmatically in iOS?

I am implementing the functionality for to record the video in my iOS application, Also, i am using ReplayKit to record a full screen instead of the camera's default capturing In that there is a ...
Keval Gajjar's user avatar
0 votes
1 answer
407 views

Optimal handling of AVCaptureSession through app's lifecycle

After reading a lot of Camera App related Apple examples/internet tutorials/random articles I am left with one uncertainty: What is the optimal way of handling your Session setup, while taking into ...
Thirsty4K's user avatar
2 votes
0 answers
165 views

AVFoundation crash in fetching averagePowerLevel from audio connection

I have the following code to update power level meters from AVAudioConnection periodically. func updateMeters() { var channelCount = 0 var decibels:[Float] = [] let audioConnection =...
Deepak Sharma's user avatar
1 vote
1 answer
560 views

Having trouble with flipping camera in swiftui / avfoundation / AVCaptureDeviceInput

I am coding a camera with swiftui using avfoundation and was able to get the setup to work as intended. However, as I'm implementing a flip camera functionality I'm running into an error where after ...
krish's user avatar
  • 77
1 vote
0 answers
639 views

is the zoom factor for builtInTripleCamera's .5 zoom 1.0?

I'm working on a camera app and I currently don't have a device with a triple camera (so I cannot test). When an app initially configures a camera, I want the camera setting with no zoom in and out ...
Yuuu's user avatar
  • 879
3 votes
1 answer
3k views

Difference between builtInDualCamera and builtInDualWideCamera

I know only a little about iPhone's camera, and I'm bit confused with the differences between builtInDualCamera and builtInDualWideCamera. (so as builtInWideAngleCamera and builtInUltraWideCamera) ...
Yuuu's user avatar
  • 879
2 votes
0 answers
374 views

How to handle a video overexposure in Swift

I'm working on a camera app, and I think the behavior of my app and the iPhone default camera app against overexposure is very different. Like the image below, the default camera app adjusts the ...
Yuuu's user avatar
  • 879
0 votes
1 answer
99 views

Duplicate names detected for capture devices

I am using some capture devices for my application, which keep getting detected with the same name by my code which I have written following the link : https://learn.microsoft.com/en-us/windows/win32/...
s_om's user avatar
  • 681
0 votes
1 answer
223 views

AVCaptureDeviceSubjectAreaDidChange when this notification is post in swift

I'm working on a camera app and I'm trying to center the focus of the camera to the center using this notification, AVCaptureDeviceSubjectAreaDidChange. NotificationCenter.default.addObserver(self, ...
Yuuu's user avatar
  • 879
8 votes
1 answer
3k views

iPhone 13 Pro / swift / AVFoundation builtInTripleCamera : how to enable automatic switching between cameras?

I am currently making a custom camera app for iOS with swiftUI AVFoundation. I also just bought iPhone 13 Pro. On the native Camera App, cameras automatically switch depending on FOCUS (ultrawide for ...
Mourad's user avatar
  • 81
1 vote
1 answer
1k views

Set resolution for camera in IOS for AI

I am working on a project where I start the camera and then capture images live to image processing. This project has guided me TensorFlow - Image Classification. One thing I can't figure out despite ...
El_Loco's user avatar
  • 1,868
1 vote
1 answer
508 views

AVCaptureDevice's exposurePointOfInterest does not work

I'm trying to change the exposure in my camera app according to certain point of the image. I'm using the following code that is triggered when the user taps on screen. For now I simply try to expose ...
meaning-matters's user avatar
0 votes
0 answers
606 views

How to fix AVCapturevideopreviewlayer being smaller than actual camera view

I'm working on an app that periodically takes pictures as part of a research job but I'm new to OOP and swift and am a little confused on what can cause this issue. I think it's because the UIView's ...
DanielVides's user avatar
6 votes
2 answers
1k views

macOS: Accessing a virtual Cameras (OBS) as AVFoundation CaptureDevice

On macOS, is it possible to see a virtual Camera, such as OBS, as a CaptureDevice? I see that, for example, Google Chrome or Zoom can use this camera, but using AVCaptureDevice.DiscoverySession I am ...
below's user avatar
  • 958
0 votes
1 answer
710 views

iOS capturePhoto() not taking highest resolution photos only on iPad 11" 3rd gen front camera

The goal is to take the highest resolution photo the camera is capable of. The camera selected is the iPad 11" 3rd gen (w/M1) front camera: the new 12MP TrueDepth camera. Although this code does ...
xaphod's user avatar
  • 6,774
2 votes
1 answer
1k views

Set AVCaptureDevice format range

I am able to query and find formats for slo-mo at 240FPS. There are two, with 420v and 420f each, at Full HD (correct me if I'm wrong that they only differ in the pixel value range). I was wondering ...
jackxujh's user avatar
  • 1,023
1 vote
0 answers
278 views

Why scan 1D Barcode only get result in middle of view by Swift?

I have a question about scan 1D barcode. Why I set the yellow border about scanning region view, only I put it in the middle of the region and get the result successfully? It works fine when I put my ...
JimmyLee's user avatar
  • 559
0 votes
0 answers
95 views

How do I keep my flash light code running while the app is put into background?

Button(action: { DispatchQueue.global(qos: .userInteractive).async { self.lightOn.toggle() let cam = AVCaptureDevice.default(.builtInWideAngleCamera, for: .video, position:...
Ernest Tan's user avatar
0 votes
1 answer
72 views

IOS catalyst avcapturedevice can't realize the function of scanning QR code. It happened in Catalina

IOS catalyst avcapturedevice can't realize the function of scanning QR code. It happened in Catalina. How to realize the function of uiimagepickercontroller scanning QR code This is Catalina's error ...
xiyangxixia720's user avatar
1 vote
0 answers
414 views

Swift. macOS. Record sound from speakers

I want to make the macOS-app for recording the audio from system and other apps (music, video, etc). Not microphone. How can I make that? I see only options the recording from microphone. Thanks in ...
The Tronuo's user avatar
0 votes
1 answer
534 views

iOS barcode scanner App crashes with no crash log

I am trying to make a barcode scanner app. As soon as the camera session begins, the app crashes within a few seconds. I am unable to find the reason behind this. and, how to fix this one. I have ...
Akaanksha's user avatar
  • 171
2 votes
1 answer
1k views

iOS camera output rotated 90 degrees left

I am following this tutorial to build a simple deep learning app for traffic sign recognition. link I made an own model, and I also tried it with the model in this repository: link When I run the app ...
Dániel Anderle's user avatar
0 votes
3 answers
1k views

iOS 14 AVCaptureSession capturing stereo audio with video recording

I was wondering is there's a way to capture stereo audio using an AVCaptureSession. iOS 14 adds support for stereo audio for AVAudioRecorder, but so far I have been unsuccessful is capturing stereo ...
user1752054's user avatar
3 votes
1 answer
1k views

Understanding AVCaptureDevice exposureDuration, exposureTargetOffset, exposureTargetBias

Come from Android os, I'm trying to understand the AVCaptureDevice API and find a match between the different parameters of the IOS and Android. I'm working with auto-continuous exposure mode. I'm ...
Yair Buchbletter's user avatar

1
2 3 4 5
7