[haiku-development] Re: MediaPlayer in latest build

  • From: "Axel Dörfler" <axeld@xxxxxxxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Wed, 16 Dec 2009 16:04:58 +0100

David McPaul <dlmcpaul@xxxxxxxxx> wrote:
> Well for mp4, mov, avi the chunk size is the only places you can cut
> without re-encoding, they are supposed to be the lowest seekable and
> addressable points in the file.  For video this is usually a single
> frame.  For audio it is usually a sequence of frames but it does
> depend on the encoding, I remember a file I had where the chunk size
> for the audio was a single 2 byte frame :-(.

That really demands a buffered file/network reader solution before the 
format reader.

> There is nothing
> stopping us from combining the file format chunks into larger chunks
> when passing to the decoder.

Indeed, that could be done if the decoder supports it (I guess it always 
should, as long as the cunks are on frame boundaries).
For the 2 byte frames you mention above, that sounds like a good idea.

> >> By the way, is there an easy way to hook into the Activity 
> > > Monitor?
> > If you would be more specific, I might even have an answer for this 
> > ;-)
> If I wanted to add additional items.  Like say I wanted to record
> chunks per second or other stats.

It's easy to add another data source for it, but I am not sure how you 
would want to store and retrieve the data in the first place.

Bye,
   Axel.


Other related posts: