[vlc-devel] Matroska, libopus and loophole in the spec

Denis Charmet typx at dinauz.org
Tue Nov 12 11:37:19 CET 2013


Le lundi 11 novembre 2013 à 08:48:09, Timothy B. Terriberry a écrit :
> >The alternative is to change the Opus codec plugin to use the number of
> >samples of the packet if it isn't known at the demux level instead of
> >just dropping it. As proposed in the patch sent yesterday.
> 
> I don't think this will be enough once you want to support pre-skip,
> pre-roll, and end-trimming correctly. That's why this logic lives in
> the demux for Ogg. Feel free to try doing those things and prove me
> wrong, though.
* Preskip is handled during the muxing with negative timestamps.

* Preroll is handled by the demux and the core function
  ES_OUT_SET_NEXT_DISPLAY_TIME (tested OK on my  samples)

* For end trimming I don't have any sample with that but according to
  Mosu if there is DiscardPadding, then there is a duration so it should
  be good.

In any case, the patch has been sent to the ML and is waiting for
reviews/comments.

> >As previously stated, I'm against linking the demux to a codec lib just
> >to fill a block_t field that could easily be ignored and to call
> >functions that will be called in the codec anyway for the same purpose.
> 
> That's why the Ogg demux doesn't link to the codec lib. It just
> re-implements the duration calculation (see
> Ogg_OpusPacketDuration()).
Then this will be done twice...

Regards,

-- 
Denis Charmet - TypX
Le mauvais esprit est un art de vivre



More information about the vlc-devel mailing list