Skip to content

ROQ video playback

lerabot edited this page Jul 29, 2020 · 2 revisions

This page attemps to provide all the tool your need to enable ROQ playback in KOS.

Video files

You can use FFMPEG to encode your video to the ROQ format

ffmpeg -i input_video.mp4 -r 30 output_video.roq

  • -s : Size
  • -r : Framerate
  • -b:v : Video Bitrate
  • -b:a : Audio Bitrate
  • -vf scale=640:436,pad=640:448:0:6

DreamROQ library

The original DreamROQ library was created by MultimediaMike There are various changed being made these days to be framerate accurate.

FFmpeg patch for optimized ROQ encoding

Chilly Willy shared a patch of his own to optimize ROQ encoding.

You'll need to download FFmpeg source, then replace the encode_roq_video function in libavcodex/roqvideoenc.c with the one provided here

You will then reend to recompile FFmpeg and compile your video using.

ffmpeg -i input_file.mp4 -c:v roqvideo -r:v 12 -b:v 900k -vf scale=640:327,pad=640:336:0:4 -g 24000 -quake3_compat 0 -c:a rvq_pcm -ar 32000 -ac 2 output_file.roq

You can test your result with ffplay -codec:video roqvideo filename.roq

Clone this wiki locally