I need to make every recorded frame a keyframe, but with AVCaptureSession
I can only use a few presets. AVAssetWriter
should be able to do what I need but how do I connect it with the capture session?
Asked
Active
Viewed 923 times
2

Gabi Purcaru
- 30,940
- 9
- 79
- 95
-
you want to record say, 20 frames per second opposed to a presumed 30? – Rob Sep 20 '13 at 07:08
-
@Rob I want to record 30 frames / second, but every one of those frames would be keyframes. – Gabi Purcaru Sep 20 '13 at 13:58
-
here are some video frame durations: https://developer.apple.com/library/ios/documentation/AVFoundation/Reference/AVCaptureDevice_Class/Reference/Reference.html#jumpTo_4 still looking for information on key frames – Rob Sep 20 '13 at 16:56
-
@Dimitri no, unfortunately – Gabi Purcaru Jan 02 '15 at 14:52
-
2I'm trying to do the same and stumbled upon this AVVideoMaxKeyFrameIntervalKey in AV. If set to 1 it means only Keyframes. Apple has some example code: https://developer.apple.com/library/ios/samplecode/RosyWriter/Introduction/Intro.html#//apple_ref/doc/uid/DTS40011110 but I didn't find the time to try it yet. Another post on here: http://stackoverflow.com/questions/11296642/avassetwriter-how-to-create-mov-video-with-no-compression – Jan Jan 02 '15 at 15:04