[FFmpeg-cvslog] r19773 - in trunk/libavformat: seek.c seek.h

Michael Niedermayer michaelni
Sun Sep 6 02:16:33 CEST 2009


On Sat, Sep 05, 2009 at 09:31:01PM +0200, schreter wrote:
> Author: schreter
> Date: Sat Sep  5 21:31:01 2009
> New Revision: 19773
> 
> Log:
> cosmetic changes (indentation, doxygen comments, braces, put structures for API to header, ...)
[...]>  /**
> - * Compare two timestamps exactly, taking into account their respective time bases.
> + * Compare two timestamps exactly, taking their respective time bases into account.
>   *
> - * @param ts_a timestamp A.
> - * @param tb_a time base for timestamp A.
> - * @param ts_b timestamp B.
> - * @param tb_b time base for timestamp A.
> - * @return -1. 0 or 1 if timestamp A is less than, equal or greater than timestamp B.
> + * @param ts_a timestamp A
> + * @param tb_a time base for timestamp A
> + * @param ts_b timestamp B
> + * @param tb_b time base for timestamp A
> + * @return -1, 0 or 1 if timestamp A is less than, equal or greater than timestamp B
>   */
>  static int compare_ts(int64_t ts_a, AVRational tb_a, int64_t ts_b, AVRational tb_b)
>  {
> @@ -95,9 +63,9 @@ static int compare_ts(int64_t ts_a, AVRa
>      if (ts_a == INT64_MIN)
>          return ts_a < ts_b ? -1 : 0;
>      if (ts_a == INT64_MAX)
> -        return ts_a > ts_b ? 1 : 0;
> +        return ts_a > ts_b ?  1 : 0;
>      if (ts_b == INT64_MIN)
> -        return ts_a > ts_b ? 1 : 0;
> +        return ts_a > ts_b ?  1 : 0;
>      if (ts_b == INT64_MAX)
>          return ts_a < ts_b ? -1 : 0;
>  
> @@ -105,7 +73,7 @@ static int compare_ts(int64_t ts_a, AVRa
>      b = ts_b * tb_b.num * tb_a.den;
>  
>      res = a - b;
> -    if (res == 0)
> +    if (!res)
>          return 0;
>      else
>          return (res >> 63) | 1;

not related to your cosmetic change but this code is complete nonsense

please disable or revert all your recent seeking changes, this code needs
quite a bit of bugfixing and i dont see it happening.
Speaking of that your h264 timestamping code also needs work that does not
seem to be done ...

[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

When the tyrant has disposed of foreign enemies by conquest or treaty, and
there is nothing more to fear from them, then he is always stirring up
some war or other, in order that the people may require a leader. -- Plato
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-cvslog/attachments/20090906/77faa079/attachment.pgp>



More information about the ffmpeg-cvslog mailing list