<!--
{
  "availability" : [
    "Xcode: 12.0.0 -",
    "macOS: 11.0.0 -"
  ],
  "documentType" : "article",
  "framework" : "AVFoundation",
  "identifier" : "/documentation/AVFoundation/writing-fragmented-mpeg-4-files-for-http-live-streaming",
  "metadataVersion" : "0.1.0",
  "role" : "sampleCode",
  "title" : "Writing fragmented MPEG-4 files for HTTP Live Streaming"
}
-->

# Writing fragmented MPEG-4 files for HTTP Live Streaming

Create an HTTP Live Streaming presentation by turning a movie file into a sequence of fragmented MPEG-4 files.

## Overview

> Note: This sample code project is associated with WWDC20 session [10011: Authoring Fragmented MPEG-4 with AVAssetWriter](https://developer.apple.com/videos/play/wwdc2020/10011).

### Configure the sample code project

Before you run the sample code project in Xcode:

1. Edit the shared scheme called `fmp4Writer`.
2. Open the Run action.
3. Replace the *<path to movie file on disk>* argument with the path to a movie file on your local hard drive.
4. Replace the *<path to output directory>* argument  with your desired output directory; for example `~/Desktop/fmp4writer/`.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)