|
Rockbox mail archiveSubject: Adding RM support - Weekly updateAdding RM support - Weekly update
From: Mohamed Tarek <mtarek16_at_gmail.com>
Date: Sat, 11 Jul 2009 04:16:15 +0300 Greetings, 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 :* http://tinyurl.com/l3yqux* - "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(seek) if block_timestamp > seek_time loop: seek_buffer(previous_block) get packet if block_timestamp < seek_time break_loop time_offset = seek_time - block_timestamp frames_offset_in_block = time_offset/((frame_size_in_bits)/bit_rate) start decoding from frames[frames_offset_in_block] else //block_timestamp < seek_time - make sure that's the closest timestamp value to seek_time loop: seek_buffer(next_block) get_packet if block_timestamp > seek_time break_loop seek_buffer(previous_block) get_packet //do the same 3 lines before "else" end if end if -------------------------------------------------- Regards, MT Received on 2009-07-11 Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy |