Questions tagged [avcomposition]

72 questions
1
vote
1 answer

Adding watermark to video is extremely slow

I am using AVComposition to render a watermark to a video. This process takes around 15 seconds, which doesn't seem ok for a 20 seconds video. My export settings are: let exporter = AVAssetExportSession.init(asset: mixComposition, presetName:…
thelearner
  • 1,440
  • 3
  • 27
  • 58
1
vote
0 answers

Merge videos at specific frame or time

Here is my scenario: Step 1: user selects video A from the list Step 2: user plays video A Step 3: user pauses video A Step 4: user selects video B from a secondary list Step 5: user inserts video B after the last frame where video A was paused…
Bogdan R
  • 51
  • 7
1
vote
0 answers

Avfundation Video Array swift 3

Good afternoon I have a question about a function I'm doing in swift 3. I'm making an app that uses the camera and records video but the bed will record continuously and at the time you press a button it will be saved the last minute it was recorded…
1
vote
1 answer

Rendering CALayers with CoreAnimations

How is it possible to render CALayer that has lots of animations to a mov file? I know how to render it with AVVideoCompositionCoreAnimationTool videoCompositionCoreAnimationToolWithPostProcessingAsVideoLayer but therefore i need a dummy video (i…
1
vote
0 answers

custom resourceLoader with AVComposition

Is there any way to use a custom resourceLoader with an AVComposition? I get the AVAssetResourceLoaderDelegate callbacks when I set the resourceLoader on an AVURLAsset and create an AVPlayerItem with that asset. But if I use that same AVURLAsset in…
1
vote
1 answer

Weird behaviour of AVPlayer

I am merging multiple videos and playing it in AVPlayer. Video starts fine, but after sometime video freezes and only audio plays. I have a UISlider which helps to go forward or backward in video using seekToTime:. So the weird part is that after…
blancos
  • 1,576
  • 2
  • 16
  • 38
1
vote
4 answers

How to merge multiple videos and audio using AVAsset

Hi I am trying to merge videos together using AVMutableComposition . The problem I am having is that the AVAsset tracksWithMediaTypes method returns an empty array and the app crashed. Can someone point out what I am doing wrong. Thanks Here is…
Kaitis
  • 628
  • 9
  • 21
1
vote
1 answer

Loosing audio after processing in AVComposition

I am using AVMutableComposition to combine two pieces of media (one video one graphic overlay). The video was captured using UIImagePickerController. Video records fine and audio is there when previewing the recording. Process with Composition, and…
nibeck
  • 669
  • 1
  • 8
  • 15
1
vote
2 answers

tracks in AVComposition losing time when paused

I've created an AVMutableComposition that consists of a bunch of audio tracks that start at specific times. From there, following Apple recommendations, i turned it into an AVComposition before playing it with AVPlayer. It all works fine playing…
James Morris
  • 163
  • 1
  • 10
0
votes
1 answer

AVAsynchronousVideoCompositionRequest sourceFrameByTrackID nil for video with alpha

I'm trying to add some transparent animation videos to my composition as a transition but in my custom compositor (AVVideoCompositing) when I try to get pixel buffer via AVAsynchronousVideoCompositionRequest.sourceFrame it returns nil. If I use non…
manikal
  • 953
  • 7
  • 30
0
votes
1 answer

Getting black screen during image compose with custom compositor

I'm trying to make movie from still image, for that i use custom compositor with custom instructions. Actually i get movie and length is as expected, but after one frame (5 second) i get black screen(for another frames) What i did is in my demo…
SPatel
  • 4,768
  • 4
  • 32
  • 51
0
votes
1 answer

Equal-Power Crossfade in AVMutableVideoCompositionLayerInstruction

How can I get an equal-power crossfade working in an AVVideoComposition? I'm using something like the following to fade between video tracks, but when looping the same video over and over there is a very noticeable brightness dip during the…
Dan Halliday
  • 725
  • 6
  • 22
0
votes
0 answers

ffmpeg HLS stream audio is out of sync when input video are multiple clips joined using AVComposition

I am having problems with HLS stream creation that seems to be either on FFMPEG or iOS AVFoundation side. I am currently working on a video app which allows user to record, cut and merge multiple clips together. That is done using…
0
votes
0 answers

AVVideoComposition fails while trying to read video frame

I have a source video and I want to generate a new video from it by taking a region of each frame of the source video. For example, if I have a video with resolution A x B, a content size of X x Y and an output resolution of C x D, then I want to…
Reynaldo Aguilar
  • 1,906
  • 1
  • 15
  • 29
0
votes
0 answers

How to implement iMovie Trimming View?

I need to merge multiple videos before that I want to trim Videos and place Text overlay over Videos. I want to create simply another iMovie app with all functionality. Could you please suggest any library is available in GitHub or please share your…