How to Transcode Video to RealVideo with FFmpeg

This article provides a direct guide on converting modern video files into the legacy RealVideo format using the FFmpeg multimedia framework. You will learn the specific command-line syntax required for RealVideo, the limitations of FFmpeg's built-in encoders, and the audio settings necessary to produce a functional RealMedia container file.

Supported RealVideo Codecs in FFmpeg

FFmpeg has native encoders for early RealVideo generations, but not the later ones. You can encode using:

  • RV10 (rv10): RealVideo 1.0
  • RV20 (rv20): RealVideo 2.0 (G2)

Note: RealVideo 3.0 (RV30) and 4.0 (RV40) can only be decoded by FFmpeg; they cannot be encoded.

For the audio stream within a standard RealMedia (.rm) file, FFmpeg supports the legacy RealAudio 1.0 codec (real_144).

Basic Transcoding Command

To convert an input file (such as an MP4) to RealVideo, set the video codec to rv20, the audio codec to real_144, and use the .rm extension for the output container:

ffmpeg -i input.mp4 -c:v rv20 -c:a real_144 output.rm

Adjusting Bitrate and Frame Rate

RealVideo was engineered for low-bandwidth streaming. To ensure compatibility with legacy playback software and optimize file size, explicitly define the video bitrate and frame rate:

ffmpeg -i input.mp4 -c:v rv20 -b:v 350k -r 25 -c:a real_144 output.rm
  • -c:v rv20: Sets the video encoder to RealVideo 2.0.
  • -b:v 350k: Limits the video bitrate to 350 kbps.
  • -r 25: Forces a standard frame rate of 25 frames per second.
  • -c:a real_144: Sets the audio encoder to 8 kHz RealAudio 1.0.

Encoding with RealVideo 1.0

If your target system requires the older RealVideo 1.0 specification, change the video codec flag to rv10:

ffmpeg -i input.mp4 -c:v rv10 -b:v 250k -c:a real_144 output.rm

Video Only Encoding

If you do not require audio in your RealMedia file, omit the audio processing using the -an flag:

ffmpeg -i input.mp4 -c:v rv20 -b:v 500k -an output.rm