dev builds
themes manual
device status forums
mailing lists
IRC bugs
dev guide

Rockbox mail archive

Subject: Adding RM support - Weekly update

Adding RM support - Weekly update

From: Mohamed Tarek <>
Date: Sat, 11 Jul 2009 04:16:15 +0300


Current status of the project : Code was committed - some bugs had to be
fixed like playback on big-endian targets. Also, there was an
unaligned-access issue with MIPS based targets, but that was fixed too
(Thanks to Maurus Cuelenaere).

Cook codec also now handles seeking to the track's beginning.

Next on my schedule is seeking. ffmpeg's rm parser assumes the presence of
an index chunk in the file to be able to seek, other than that seeking is
allowed in backwards only. And according to this document :** - "RealMedia files" section, the index chunk is
mostly missing.
So, this week I'll have to come up with a seeking algorithm that's
independent of the index chunk's presence. Forunately, ffmpeg's rm parser is
being rewritten, so I'll try reaching the developers working on that to see
if they've reached something.

I've written a simple algorithm to handle seeking, and I'm pasting it here
to have it reviewed so that most of the apparent problems could be fixed
before actually starting to code.
Here goes :
  if block_timestamp > seek_time
      get packet
      if block_timestamp < seek_time

    time_offset = seek_time - block_timestamp
    frames_offset_in_block =
    start decoding from frames[frames_offset_in_block]

  else //block_timestamp < seek_time - make sure that's the closest
timestamp value to seek_time
      if block_timestamp > seek_time
    //do the same 3 lines before "else"

  end if

end if

Received on 2009-07-11

Page was last modified "Mon Nov 16 10:57:21 2020" The Rockbox Crew -- Privacy Policy