RealMedia
- Extensions: rm, ra
- Company: Real
Multimedia container format developed by Real and used almost exclusively for codecs developed by Real.
The old .ra files are just for audio. The newer RealMedia (.rm) files are for audio and video.
RA Format
RealAudio 1.0 file:
This is from the very first version of RealAudio (1994). These files can only contain 8kbps VSELP audio data. A FourCC (lpcJ) may be present, but it is ignored.
bytes 0-3 '.', 'r', 'a', 0xfd bytes 4-5 0x00, 0x03 bytes 6-7 Pointer to start of compressed audio data bytes 8-21 Unknown bytes 22+: Title string, preceded by a length byte Author string, preceded by a length byte Copyright string, preceded by a length byte Comment string, preceded by a length byte ... Audio data
RealAudio 2.0 file:
This is second version of the RealAudio file format. It is distinguished from the above by the value in byte 5 (=0x04). This type of file must contain a valid FourCC to identify the audio codec.
bytes 0-3 '.', 'r', 'a', 0xfd bytes 4-7 0x00, 0x04, 0x00, 0x00 bytes 8-11 ".ra4" bytes 12-15 Data size (??) bytes 16-17 Version (??) bytes 18-21 Header size (??) bytes 22-23 Codec flavor bytes 24-27 Coded Frame Size bytes 28-41 ??? bytes 42-43 Frame Size bytes 44-45 Sub Packet Size bytes 46-47 ?? bytes 48-49 Sample rate bytes 50-53 ?? bytes 54-55 Channels bytes 56+ Type and FourCC
Version '5':
Same as above, except byte 5 = 0x05 and there are 6 more bytes after 'sub packet size', and the FourCC is not preceeded by a length byte.
RealMedia Format
This is the newer format which stores both audio and video. All multi-byte numbers are stored in big endian format.
A RealMedia file consists of a series of chunks. Each chunk has the following format:
bytes 0-3 chunk type (FOURCC) bytes 4-7 chunk size, including 8-byte preamble bytes n.. chunk payload
Real chunk types:
- .RMF: RealMedia file header
- PROP: File properties
- MDPR: Stream properties
- CONT: Content description/metadata
- DATA: File data
- INDX: File index
- '.','r','a',0xFD: Legacy RealAudio encapsulation
- VIDO
Codecs
Codecs in RealMedia are identified by the following four character codes:
Audio
- lpcJ - RealAudio 1.0 (VSELP)
- 28_8 - RealAudio 2.0 (LD-CELP)
- dnet - AC3
- sipr - Sipro
- cook - Cook
- atrc - ATRAC
- ralf - RealAudio Lossless Format
- raac - LC-AAC
- racp - HE-AAC
Video
- rv10 - H.263
- rv13 - H.263
- rv20 - H.263+
- rv30 - Unknown format
- rv40 - Unknown format