on OS X API, you use an AVAssetWriter object to write media data to a new file of a specified audiovisual container type, such as a QuickTime movie file or an MPEG-4 file, with support for automatic interleaving of media data for multiple concurrent tracks
Questions tagged [avassetwriter]
529 questions
6
votes
0 answers
Video Compression ios : Reduce the size of a video usin AVAssetWriter
I am Successful in encoding a series of image captured by AVCaptureVideoPreviewLayer of AVFoundation Framework into a Video using AVAssetWriter and AVAssetWriterInput.
But the size of the video is too large, Can anyone of you suggest me a tutorial…

iAviatorJose
- 418
- 2
- 10
- 25
6
votes
1 answer
Removing buffer from AVAssetWriter before outputting to file
I have an app that is like Vine or Instagram Video and I am trying to delete the last recorded segment. I am using AVAssetWriter and appending the sample buffer to the asset writer input when recording but I want to allow users to delete the last…

Encore PTL
- 8,084
- 10
- 43
- 78
6
votes
1 answer
Change AVMetadataItem
I have some files, -m4a -mp4 -mp3 etc.
I want to change these details
AVMetadataItem
AVMetadataCommonKeyArtwork
AVMetadataCommonKeyArtist
I can do with AVAssetExportSession, But I need to change the directory. Is there a way I can write…

user1669335
- 143
- 10
6
votes
0 answers
Core Animations with AVAssetWriter possible?
I know about the AVVideoCompositionCoreAnimationTool method to use Core animations and I made it work using AVMutableComposition, but I'm looking for a way to do the same animations through AVAssetWriter. Basically I want to create CAAnimation(s)…

John Estropia
- 17,460
- 4
- 46
- 50
6
votes
1 answer
Get PTS from raw H264 mdat generated by iOS AVAssetWriter
I'm trying to simultaneously read and write H.264 mov file written by AVAssetWriter. I managed to extract individual NAL units, pack them into ffmpeg's AVPackets and write them into another video format using ffmpeg. It works and the resulting file…

kolyuchiy
- 5,465
- 2
- 23
- 31
5
votes
1 answer
Use AVFoundation to modify audio metadata
I'm working on an app which needs to modify metadata of audio files. I have played with Apple's official demo AVReaderWriterOSX. I have tried to set the metadata of AVAssetWriterInput and AVAssetWriter, but I still can't make it work to write…

nonamelive
- 6,510
- 8
- 40
- 47
5
votes
0 answers
Can someone explain source time, movie time, presentation time, etc.?
In my iOS app, I need to save an image as a short video segment. I have this working using AVAssetWriter and AVAssetWriterPixelBufferAdaptor, thanks to some of the great posts on this site, but I've had to fudge the start and end session times, and…

John
- 2,121
- 1
- 23
- 38
5
votes
2 answers
how to record screen video as like Talking Tomcat application does in iphone?
hey i m trying the record the gameplay of my game so that i can upload its video to youtube from device itself...m trying to do same thing as Talking tomcat app for iphone..recording the video then playing it ,etc...
i m using glReadPixels() for…

Tornado
- 1,069
- 12
- 28
5
votes
2 answers
Hold multiple Frames in Memory before sending them to AVAssetWriter
I need to hold some video frames from a captureSession in memory and write them to a file when 'something' happens.
Similar to this solution, i use this code to put a frame into a NSMutableArray:
- (void)captureOutput:(AVCaptureOutput…

jsB
- 51
- 1
- 2
5
votes
1 answer
Real-time AVAssetWriter synchronise audio and video when pausing/resuming
I am trying to record a video with sound using iPhone's front camera. As I need to also support pause/resume functionality, I need to use AVAssetWriter. I've found an example online, written in Objective-C, which almost achieves the desired…

Andriy Gordiychuk
- 6,163
- 1
- 24
- 59
5
votes
1 answer
Swift: Merge Videos back-to-back with AVAssetExportSession()
I have an array of video recordings stored as AVURLAsset and I want to merge the videos into 1 clip so that they play back to back with no time in-between videos. Below is what I'm hoping to do, but it is only showing the 1st video. Note: I want the…

nicksarno
- 3,850
- 1
- 13
- 33
5
votes
0 answers
How to add colorProfile with AVAssetWriter to video recorded from screen using CGDisplayStream
I've written a screen-recording app that writes out H.264 movie files using VideoToolbox and AVWriter. The colors in the recorded files are a bit dull compared to the original screen. I know that this if because the colorProfile is not stored in the…

Thies Ḉ Arntzen
- 83
- 5
5
votes
0 answers
Fastest way to record video from SCNView
I have SCNView with some object in the middle of screen, user can rotate it, scale, etc.
I want to record all this movements in video and add some sound in realtime. Also I want to record only middle part of SCNView (e.g. SCNView frame is 375x812…

Joker
- 263
- 2
- 16
5
votes
2 answers
AVAssetWriterInput with more than 2 channels
Does someone know how to use the AVAssetWriterInput init with more than 2 channels?
I'm trying to init an audioInput, to add it after on AVAssetWriter this way:
let audioInput = AVAssetWriterInput(mediaType: AVMediaTypeAudio, outputSettings:…

Anne Kariny Silva Freitas
- 85
- 1
- 9
5
votes
1 answer
How to set expected framerate to AVAssetWriterInput
I have an app which encodes videos in different ways and saves it to Photos library - it can cut specific time range, add pictures, text, etc. Everything is working perfectly till I try to encode video 120+ fps. The problem is that video appears to…

Eugene Alexeev
- 1,152
- 12
- 32