1) What is MP4? I have heard it is a "container format"? What's that?
A container format allows you to combine different multimedia streams (most of the time audio and video) into one single file.
Multimedia containers are for example the well known AVI (.avi), MPEG (.mpg, .mpeg), Matroska (.mkv, .mka), OGM (.ogm), Quicktime (.mov) or Realmedia (.rm, .rmvb)

MP4 is the global file extension for the official container format defined in the MPEG-4 standard (ISO 14496-14)
MP4 is streamable and supports all kinds of multimedia content (multiple audio-, video-, subtitlestreams, pictures, variable-framerates, -bitrates, -samplerates...) and advanced content (officially called "Rich Media" or "BIFS") like 2D and 3D animated graphics, user interactivity, DVD-like menus... - next to nothing handled by the often used AVI

2) What extension is MP4 using?
- .mp4: only official extension, for all audio and video and advanced content files (and combinations)

other related extensions:
- .m4v: .mp4 files with the WRONG extension introduced by apple for video+audio files, m4v can safely be renamed to .mp4
- .m4a: .mp4 files with the WRONG extension introduced by apple for audio-only files, m4a can safely be renamed to .mp4
- .m4p: DRM protected files sold in iTunes, using the DRM sheme developed by apple
- .m4e: renamed .sdp files used by Envivio for streaming
- .m4v, .mp4v, .cmp, .divx, .xvid, .264: normally raw mpeg-4 video streams (not inside MP4)
- .aac: raw aac audio streams/adts (not Inside MP4)
- .3gp, .3g2: used by mobile phones, can also include content not defined for .mp4 (H.263, AMR), see question 20
- .mov: technologically similar container, but not the same as MP4, see question 20

4) Is it also possible to place streams not covered by the MPEG-4 standard in MP4?
Yes, altough i dont like the idea of doing so, the MPEG-4 standard defines how to place any stream in MP4. Similar to how streams are marked in AVI with private FourCCs, in MP4 they get a "private track ID". Note that no player will be able to handle such streams in MP4, but will simply ignore them, if not explicitely specified to do so
the following streams, not covered by MPEG-4, can be placed in MP4 already:
- Ogg Vorbis and Ogg Theora, via MP4Box
- Ogg Vorbis, via a patched mp4creator
- Apple's Lossless Audio (ALAC/ALE - not compliant with MPEG-4 ALS), via iTunes
- DVD picture subtitles (Vobsubs), via Nero Recode2
only the future will show if these private streams will be widely accepted and supported...

5) What do i have to especially look at, when i mux MPEG-4 video from AVI to MP4?
there are potential problems when muxing from AVIs (especially with b-frames/B-VOPs/bi-directional encoding) into MP4:
1) "delay frames", caused by the old VFW interface some codecs still use (XviD, DivX5). only when encoding with VirtualDub/Mod these will be automatically dropped when using b-frames
2) "packed bitstream", caused by the old AVI container, which is not really capable of storing b-frames. PB is used in DivX5 (only with 1 consecutive b-frame set) and by default in new XviD builds (make sure the PB option is unticked in XviD) and packs b-frames together with other frames (read a more detailed description about B-frames in AVI here).
3) "userdata", which in the case of XviD and DivX PB streams signals the useage of PB. some decoders take this flag into account while decoding
4) "vol", which is placed on every keyframe in AVI, but has to be seperated from the movie data in MP4
5) "ctts" atom, which has to be written when muxing b-frames into MP4

Currently only the 3ivx mp4 muxer and GPAC's MP4Box handle all these things correctly! use only them for AVI conversions, especially with packed bitstreams or if you are unsure which b-frame option/encoding app was used. otherwise the chance is great that you will not get a 100% spec compliant MP4 file!

6) Does transmuxing to MP4 reencode the content?
No, this is a lossless process, only taking out the media streams from one container and putting them into MP4

7) How can i mux Subtitles into MP4 files?
there are three possibilites to store subs in mp4:
- In contrary to MPEG-1/2 the MPEG-4 Standard defines its own Text Stream/Subtitle Format under ISO 14496-17 (MPEG-4 Timed Text). Its text-based (not picture-based as DVD subs), uses UTF-8/16 (including cyrilic, arabic, chinese characters...), allows all sorts of animations (scrolling, colors, karaoke aso...), allows attaching of fonts and is streamable
MPEG-4 TTXT creation is already supported in MP4Box and Quicktime. Playback works with Gabest's and Haali's MP4 dshow parser, Osmo4, Realplayer and Quicktime (only when placed in .3gp) and VideoLAN.
- Nero's Recode2 makes use of the possibility of storing private streams in MP4 (question 4) and simply takes the DVD subpicture streams (vobsubs) from the DVD and stores them in MP4 without modifications
playback of these streams works with Nero's, Gabest's and Haali's Parser, VideoLAN and some Hardware MP4 DVD Players
- another way covered by the MPEG-4 Standard for storing subs in MP4 is to translate the subtitle format into the XMT/BT format and then to encode it as "advanced content" (BIFS binary format) in MP4. use mp4box or dvd2mp4gui for example to convert SRT subs
for playback of advanced content you need a filter/player that can handle this kind of content (see question 14)

8) How can i place Chapters in MP4 files?
chapters storage is possible by using advanced content (eg by creating a menu), but Nero uses a MP4 feature called "user space" (udta atom) which allows you to attach anything you want in MP4 (iTunes uses the udta atom for storing tags and cd/dvd-covers ("coverart") in MP4 for example).
atm you can place chapters in MP4 automatically during encoding with Nero Recode2 or, on existing files, with MP4Box and the MP4 directshow muxer filter coming with Recode2 (usable in graphedit)
As players, not knowing the info stored in udta, will simply ignore it, you need a player/filter that can handle this special chapters info (eg Gabest, Haali, Nero or 3ivx)

9) How can i tag MP4 files?
The MPEG-4 Standard defines the "meta" atom to be used for storing tagging-like information, but Apple has introduced a different tagging way with iTunes using the "udta" atom with utf-8 tags (see question 8)
There are various tools for adding apple-like tags to MP4 files, like mp4tags from mpeg4ip, tg or AtomicParsley

10) How can i store infomation about different tracks in MP4 files?
The MP4 container allows the storage of the used language and the name for every stream (no matter if the stream is audio, video or animation)
The language can be set for example by mp4box and quicktime. The streamname feature is used by Nero and can be set indivdually with mp4box

11) How can i author MP4 files (ie create DVD-like Menus)? Are there any samples?
Thanks to IMOON there is now the MP4MenuGUI tool available which lets you easily design dvd-like menus in MP4. It creates a file using the textual language format called XMT or bt (based on VRML, like the well known Flash), which than gets encoded/compiled into mp4 (free available encoders are mp4box, mp4tool or XMTBatch) as binary format (called BIFS)

If you want to try MP4 authoring yourself "by hand" or modify the script created by MP4MenuGUI read the great Tutorial by the GPAC guys available in english and french
to make this process much easier i created a sample script, called MP4Menu (which is also the basis for MP4MenuGUI) which already supports all features a DVD Menu offers and you will only have to adopt to your needs (guide)

if you want to know what can also be possible in MP4, check out this small in-video menu sample, but MPEG-4 Systems also offers things like animations in 2 and 3 Dimensions (think of movies like Toy Story or Finding Nemo), check out this small systems 2D animation sample (doesnt include a video stream!)

For playing MP4 files using advanced content make sure to use a Systems capable Player, like the GPAC Osmo4 player

12) How can I "anamorphic resize" with MP4?
As the MPEG-4 Standard aims to be a "multi-talent", satisfying everyone's needs, it offers 3 possibilites:
1) on the video bitstream level: maybe the most practicable and widely used method atm
use a codec which allows the setting of a PAR (eg 3ivx, ffmpeg/ffvfw, XviD), than mux the resulting AVI into MP4 by using any MP4 muxer (for example the 3ivx mp4 muxer, MP4Box or mp4UI). On already existing bitstreams you can change the PAR on MPEG-4 ASP with Moitah's MPEG4 Modifier, on AVC with hhanh's ARChange or on both formats with MP4Box
Anamorphic playback also already works automatically with VideoLAN, MPlayer or on DShow with the 3ivx, Nero or Haali parsers together with the XviD (set AR to auto), 3ivx (enable "force overlay"), Nero or ffdshow (enable "overlay mixer") decoder filter
2) on the container level: MP4 offers the possibility to use a "Composition Matrix", which allows the changing of the AR, rotating of the picture, multilayer handling, mixing of two audio streams during playback (eg seperated speech and music in movies)...Quicktime/Pro already offers many composition possibilities via Movie -> Get Movie Properties -> Video/Sound Track -> Size/Layer/Volume/... and the correct playback of such composed MP4 files
3) on the BIFS level: which allows the broadest range of authoring possibilities (question 11) and therefore also changing of the AR (eg via Transform2D.scale)
for creating and playing with this BIFS control stream you can use the GPAC project tools: MP4Box and Osmo4

14) How can i play MP4 files?
as one of the big advantages of MP4 is interoperability and being an open standard (license free!) there already exist a lot of different tools supporting it on as good as all systems including Mac, Linux, PocketPC and of course Windows:

1) if you want to play any multimedia file in a directshow based player (for example media player classic, bsplayer, zoomplayer or the crappy windows media player) first of all two things are needed for playback:
- a splitter/parser filter, which splits up the container file into the included streams (audio, video, subtitles) during playback
- a decoder filter, which decodes the encoded streams (for example ffdshow, 3ivx, CoreAAC)
btw. the only reason why you don't have to install a splitter for AVI is that it is already installed on windows by default

15) How can i (live-)stream/play streamed MP4 files?
Apple and MPEG4IP offer nice and free tools when it comes to streaming MP4:
As streaming server you can use Apple's Darwin Streaming Server, Guides on the process are available from everwicked and linuxjournal
for live streaming you can use mp4live from MPEG4IP (only for Linux), Guides from everwicked and MPEG4IP; on Windows you can use MPEGRecorder (which seems to be a port of mp4live)
Also have a look at the tools from ViTooKi (opensource Streaming Server, Player and other tools)
Another free and opensource MP4 streaming server is available from Cata
for MAC you can have a look at Live Channel

16) Where can i find a MP4 bitrate calculator? Why are MP4 files created from AVI smaller than the source itself?
MP4 needs far less overhead than the AVI container (especially with VBR-MP3), no wonder cause in contrary to AVI the MP4 container was designed for storing MPEG-4 Video and MP3
As a rule of thumb you can say that the video AVI filesize = final audio+video MP4 size (like 700MB) - audio MP4 size + 3MB
3ivx also offers a MP4 bitrate calculator on their website, but it doesnt seem to be very accurate

17) Does MP4 support CRC/EDC or ECC?
No, the MP4 container itself doesnt handle this as the MPEG-4 standard expects the Error Detection/Correction to be placed in the bitstreams (where it belongs)
read more about Error Resilience in MPEG-4 bitstreams here

18) Is it possible to find out which codecs where used to create a MP4 file?
Yes, this is already possible for MPEG-4 ASP video streams and MP3 Audio streams (currently no real solution for AAC exists)
read more about it here

19) Is MP4 the successor of MP3?
Yes and No. No, because MP3 is one specific type of audio format, whereas MP4 is a container format and not an audio codec. Yes, because MP4 is part of the MPEG-4 Standard, which can be taken as the successor of the MPEG-1/2 standard, where MP3 was part of.
MPEG-4 also includes AAC, an audio codec better than MP3, which most of the time comes in the MP4 format

20) Is MP4 the same as MOV/3GP?
Apple's MOV container format was indeed taken as a starting point for MP4 (mainly the moov atom), but there are differences between them (eg AAC audio is stored differently in both).
MP4 on the other hand itself was the starting point for the development of the 3GP format (mainly for mobile phones), which has more in common with MP4 as MP4 with MOV for example, but still is a different format

If you have any suggestions, ideas which questions to add to make the MP4 FAQ better or found any broken links, feel free to post below!
I will do my best to keep the FAQ up-to-date

Please don't use this sticky to discuss any MP4 issues, this thread is meant for info only!
If you have any questions plz search the forum, perhaps they already have been answered and only then start a new thread

thanks,
bond

__________________
Between the weak and the strong one it is the freedom which oppresses and the law that liberates (Jean Jacques Rousseau)I know, that I know nothing (Socrates)

This page has been out of date and contains some misleading information. Like that .m4a/.m4v are incorrect extensions. It also says that .MP4 containers store data differently than .MOV containers which isn't true the containers are identical. You can replace .MP4/.M4A/.M4V/etc .with .MOV and will always still play.

Microsoft didn't include support for AVC with Windows until Windows 7, which is why it can play .MP4 and some .MOV files (it doesn't support either container completely yet...). They we're trying to gain acceptance of their WMV and WMA containers... and AAC containers like MP4 and M4A were competitors. This resulted in the MKV format... though the MKV format doesn't do anything other containers can't (well MOV, OGM, FLV).

Now the MP4 extension is used almost exclusively to denote AVC (h.264) enocded video thanks to the success of Apple's iPod and iOS devices.

This page has been out of date and contains some misleading information. Like that .m4a/.m4v are incorrect extensions. It also says that .MP4 containers store data differently than .MOV containers which isn't true the containers are identical. You can replace .MP4/.M4A/.M4V/etc .with .MOV and will always still play.

Microsoft didn't include support for AVC with Windows until Windows 7, which is why it can play .MP4 and some .MOV files (it doesn't support either container completely yet...). They we're trying to gain acceptance of their WMV and WMA containers... and AAC containers like MP4 and M4A were competitors. This resulted in the MKV format... though the MKV format doesn't do anything other containers can't (well MOV, OGM, FLV).

Now the MP4 extension is used almost exclusively to denote AVC (h.264) enocded video thanks to the success of Apple's iPod and iOS devices.

Ehh yes but still they aren't identical and things you can do in .mov would brake .mp4 if they aren't implemented some stuff .mov allows isn*'t allowed in .mp4 and if you just rename it and the parser doesn't know what todo with it it can become a problem.

__________________all my compares are riddles so please try to decipher them yourselves :)