Questions tagged [avvideocomposition]

80 questions
3
votes
1 answer

Memory Crash Issue with Create Video From array of UImages in Swift

I am working with Video, I create video from array of Uimage. Its works fine with low quantity of images, but with big quantity (ex: 100+ images) it crash because of memory Issue. I have tested when video is creating, memory is growing big but…
Anna
  • 181
  • 3
  • 8
3
votes
0 answers

iOS Video Filter very slow for AVVideoComposition, CIFilter, CIImage

I want to filter selected video from Photos so use CIFilter and AVVideoComposition but it take too much time. it take 3 minute for 30 second video. How to reduce time for filter. - (void)imagePickerController:(UIImagePickerController *)picker…
Bhaumik Surani
  • 1,730
  • 3
  • 19
  • 40
3
votes
1 answer

Swift: Message from debugger: Terminated due to memory issue

This question is different that in Ios Xcode Message from debugger: Terminated due to memory issue . I am using different device and my app is being killed in foreground, besides that I cannot use Instruments to see allocations. I am trying to merge…
Tomáš Černý
  • 101
  • 1
  • 6
3
votes
0 answers

transform portrait video to be aspectFit while preview and exporting

I have been trying to get portrait video to transform in a such what that it could be aspect fit in center of player while keep rest of the screen empty. Example of How the video should look like here is the code : Few thing : …
Solid
  • 307
  • 1
  • 12
3
votes
1 answer

Resize video and keeping 1:1 scale

I have a 800x800 video and I want to transform this video in 375x375. It should looks like this: But the final result is it: What am I doing wrong? My Code: let mixComposition = AVMutableComposition() // 2 - Create video tracks let…
Klevison
  • 3,342
  • 2
  • 19
  • 32
3
votes
0 answers

AVAsset preferred transform for a custom AVVideoComposition

I have created a custom AVVideoComposition class and used it like this: AVAsset *asset = ... AVMutableVideoComposition *videoComposition = [AVMutableVideoComposition…
Tomasz Bąk
  • 6,124
  • 3
  • 34
  • 48
2
votes
2 answers

AVVideoComposition Failure

As in mine. To use it. I am string several different video clips together into an AVMutableComposition and attempting to correct their orientation if needed. Here is my code: composition = [[AVMutableComposition alloc]…
Lane
  • 21
  • 2
2
votes
0 answers

AVPlayerItemVideoOutput stops delivering frames after seek with video composition

I want to play a video and process it using Core Image filters. I have the following setup: the video as an AVAsset an AVPlayer for controlling the video playback the AVAsset is passed via AVPlayerItem to the player the Core Image filters are…
Frank Rupprecht
  • 9,191
  • 31
  • 56
2
votes
0 answers

Creating slideshow using Core Image and AVFoundation

I have a number of images that would be shown in a slideshow and each image is displayed for 1 second or more using AVPlayer. I used the following technique before (around iOS 6 time) that I would like to improve upon. Downscaled each image to…
Deepak Sharma
  • 5,577
  • 7
  • 55
  • 131
2
votes
2 answers

CATextLayer on video pixelated text

I am creating video from images and adding overlay to them. Problem is when I try to add CATextLayer to video. Text is pixelated, take a look at the image This is the code used to generate CATextLayer: private func generateTextLayer(for text:…
Baki
  • 490
  • 4
  • 19
2
votes
0 answers

Displaying a filtered video File with a preferredTransform that is not identity swift

For the app I'm working on, I need to provide a functionality that lets users apply filters to their videos( not real time, applying filters on a saved video and filePath is provided). addFilterToVideo is called when the user taps on a filter, a…
Anirudh Bandi
  • 1,171
  • 10
  • 20
2
votes
0 answers

Updating AVPlayerItem video composition

Me and my team are stuck on an issue for a few days now. We have AVPlayer which plays AVPlayerItem with a custom AVVideoComposition. player.currentItem?.videoComposition = getUpdatedVideoComisition() The user can decide if to remove or keep the…
Roi Mulia
  • 5,626
  • 11
  • 54
  • 105
2
votes
2 answers

AVVideoComposition applying filter handler not call

I want to add an overlay image into a video. I use AVVideoComposition and CIFilter to do this, but AVAsynchronousCIImageFilteringRequest handler not called. I put some breakpoints (line debugPrint"Here", request.finish), but XCode doesn't hit the…
Thien Chu
  • 90
  • 7
2
votes
0 answers

Cropping a specified CGRect from a video in ios

I want to crop a specified region of CGRect from my video file. I followed this Tutorial . I'm using renderSize property of AVMutableVideoComposition to get to a specified size. Here is my code that I use to crop a video to a specified size. -…
Jaffer Sheriff
  • 1,444
  • 13
  • 33
2
votes
2 answers

How do you access the frame number inside AVAsynchronousCIImageFilteringRequest?

When using a CIFilter with an AVVideoComposition, how can I access the current frame number in the AVAsynchronousCIImageFilteringRequest callback? The best I was able to do is estimate the frame number from the…
Matthew Self
  • 321
  • 1
  • 10