Process compressed video capture frame on iOS

Viewed 65

here's my problem.

I'm working on a real-time machine learning software in which I process image returned by the camera.

I'd like to process compressed video frame instead of raw image from :

(void)captureOutput:(AVCaptureOutput *)captureOutput didOutputSampleBuffer:(CMSampleBufferRef)sampleBuffer fromConnection:(AVCaptureConnection *)connecti  

I tried to modify directly the input by not using AVCaptureSession sessionPreset to set manually the bitrate.

Only the changes made with the sessionPreset property actually change something.

1st question: Is it possible to have a sampleBuffer with 1280x720 resolution and 4Mb/s bitrate quality and not a specific config made with sessionPreset?

2nd question: if this is not possible, can I process at runtime compressed frame made by AVAssetWriter?

Thx for all

Polpot

0 Answers
Related