[vlc-devel] [vlc-commits] demux: ttml: replace timings on output

Filip Roséen filip at atch.se
Thu Jan 12 16:32:36 CET 2017


Hi Francois,

On 2017-01-12 16:26, Francois Cartegnie wrote:

> Le 12/01/2017 à 16:18, Filip Roséen a écrit :
> > The above looks very very odd. Given that it looks like you are trying
> > to extract hours, minutes, and seconds, something like the below would
> > be correct:
> > 
> >     h = i_time / 3600;
> >     m = i_time % 3600 / 60;
> >     s = i_time % 60;
> > 
> > It is also worth noting that I personally feel that readability is
> > harmed when variable declarations are separated from their
> > initialization for no apparent reason.
> 
> I haven't really tested for over second timings. But min seems
> incorrect, yes.

Seconds is also wrong, and the usage of `CLOCK_FREQ` should make
everything turn out weird.

> >> +                /* remove */
> >> +                continue;
> >> +            }
> > 
> > For all cases where `strcmp` is used above, `strcasecmp` might make
> > more sense (given that the case of the attributes are not strictly
> > limited to lower-case, afaik)?
> 
> Since when ? That's not HTML 1.0 crap.
> XML is case sensitive. We already fail on namespaces, let's not add more
> broken matches.

I had some vague memory of ttml differing from the xml spec in that
regard, but now that I gave the RFC a skim through that does not seem
to be the case.

Sorry.
 
> Francois
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20170112/7176d94f/attachment.html>


More information about the vlc-devel mailing list