[MPlayer-dev-eng] [PATCH] mencoder: correctly consider encoder delays when examining muxer time

Diego Biurrun diego at biurrun.de
Mon Oct 18 13:06:16 CEST 2010


some minor style nits..

On Sun, Oct 17, 2010 at 12:48:40PM -0700, Corey Hickey wrote:
> 
> --- mencoder.c	(revision 32493)
> +++ mencoder.c	(working copy)
> @@ -354,15 +354,27 @@
>  
> +static double adjusted_muxer_time(muxer_stream_t *mux) {

K&R places the { on the next line for function declarations.

> +    if (! mux) return MP_NOPTS_VALUE;

  if (!mux)
      return MP_NOPTS_VALUE;

> -	if (play_n_frames >= 0) timeleft = mux_v->timer + play_n_frames * (double)(mux_v->h.dwScale) / mux_v->h.dwRate;
> +	if (play_n_frames >= 0) timeleft = adjusted_muxer_time(mux_v) + play_n_frames * (double)(mux_v->h.dwScale) / mux_v->h.dwRate;

Break the line while you're at it, same below.

Diego


More information about the MPlayer-dev-eng mailing list