Questions tagged [avcapture]

iOS video capture API for both Swift and Objective-C

Some common high-level objects used with this API:

  • AVCaptureDevice
  • AVCaptureSession
  • AVCaptureVideoPreviewLayer

related tags:

223 questions
0
votes
1 answer

Called Delegate Method after Stopping Recording Video

When I stop recording video manually, using stopRecording() method of an instance of AVCaptureMovieFileOutput, it will call fileOutput(_:didFinishRecordingTo:from:error:) delegate method of AVCaptureFileOutputRecordingDelegate. But when I stop video…
rick
  • 1,009
  • 2
  • 10
  • 28
0
votes
0 answers

Swift How to take a photo and save with same button

I am a beginner. I have a question.... How can I write the code so that every time the photo is snap it will be saved to the photo gallery. I just want to logic that if man press the taking a photo button, right save the photo and if i want to see…
0
votes
1 answer

Why on iPhone the time for processing a video frame depends on the FPS rate?

I am capturing live video frames on iPhone and processing them to track in real-time color blobs using OpenCV. In an effort to minimize the processing time I discovered that the frame pure processing time depends on the preset FPS rate! I would have…
0
votes
0 answers

Crop Captured RAW Photo and save to file iOS

Im having a really hard time finding any way to crop my captured RAW image before I send it up to the server. Im using NSURLSession and background upload so I need the image to be written to a file. Im grabbing the RAW image data as NSData using…
Mike Zaki
  • 11
  • 1
0
votes
2 answers

Increase AVCapturePhotoOutput's maxBracketedCapturePhotoCount value

I'm trying to take more than 4 images during bracketed capture. Is there a way to edit the maxBracketedCapturePhotoCount from the AVCapturePhotoOutput class?
Gabriel Robert
  • 3,012
  • 2
  • 18
  • 36
0
votes
1 answer

Is there any neat way I can edit the content of camera preview and show?

I want to edit the camera preview stream, and directly show it on the screen. Now I can get the content through AVCaptureVideoDataOutput, but how can I edit it and use the edited stream instead of the original stream? I have tried convert the…
daquexian
  • 169
  • 3
  • 17
0
votes
1 answer

AVCaptureVideo not showing label

I am trying to retain the objects from the console to be shown in as a label(classifierText). The warning of "UILabel.text must be used from main thread only" appears. What seems to the problem as to why the items are being shown as the label? var…
Terril320
  • 11
  • 1
  • 6
0
votes
1 answer

How to switch camera while video recording? (Ex: Snapchat, Facebook..etc)

I'm trying to switch camera while recording video like 'Snapchat' and 'Facebook' behavior. Switch camera work fine before start record video, but need to handle it separately when recording. Any help appreciate... public func switchCamera() { …
Ishanw
  • 1
  • 1
0
votes
1 answer

AVCaptureMovieFileOutput Orientation In Landscape

My app uses the front facing camera to record video. I have the Preview Layer successfully set up to show it in landscape right mode, which is the only way the app will run. How do I make sure the Movie output displays correctly? session =…
user717452
  • 33
  • 14
  • 73
  • 149
0
votes
0 answers

Recursive Callback call crashing app after some iterations watchdog error iOS

I'm making an iOS app that continuously takes two pictures and does post processing on them, then displays it in UI. The only way I was able to capture two pictures synchronously was by using recursion inside the completionHandler of…
Abhishek Ravi
  • 137
  • 11
0
votes
2 answers

iOS AVFoundation read QRcode when vuforia using the AVCaptureDeviceInput

This the code read QRcode - (instancetype)init { if (self = [super init]) { if (self.session == nil) self.session = [[AVCaptureSession alloc] init]; //device if (self.device == nil) self.device =…
ChokWah
  • 105
  • 8
0
votes
1 answer

How to record the exact time stamp for Avcapture Record starts?

Am using AVCapture to recording the video and storing in documents directory. Right now We are storing the start time of video recording on click of the recording button click. We are observing some delay in milliseconds between the click of…
BhavikKama
  • 8,566
  • 12
  • 94
  • 164
0
votes
0 answers

SceneKit snapshot crashes if I put it in trackMotion, but not otherwise - timing issue?

I have a view with a SceneKit in the background and an AVCaptureVideoPreviewLayer in the foreground. I want a semi-transparent version of the background to be visible over the camera. So based on an older thread here, I added a UIImageView and put…
Maury Markowitz
  • 9,082
  • 11
  • 46
  • 98
0
votes
1 answer

self.startRunning doesn't function properly

I'm currently creating an iOS application that uses the camera to capture 15 frames per second for 30 seconds (a total of 450 frames). The problem is that [self.session startRunning] (the last line of the code provided) doesn't seem to be working; I…
fi12
  • 495
  • 11
  • 30
0
votes
2 answers

Display captured image from avcapture

I want to store and retrieve an image that was taken from my avcapturesession. I was able to do this with a button press but I want to have the image appear automatically after it is taken. It works fine with an IBAction press. Here's what I have…
Marc Matteo
  • 103
  • 2
  • 9