[FFmpeg-devel] [PATCH 1/4] FFV1 specification: Change formatting of pseudo-code
Michael Niedermayer
michaelni at gmx.at
Fri May 1 13:49:24 CEST 2015
On Fri, May 01, 2015 at 12:13:22PM +0200, Jerome Martinez wrote:
>
> ffv1.lyx | 136 +++++++++++++++++++++++++++++++--------------------------------
> 1 file changed, 68 insertions(+), 68 deletions(-)
> 00196b1a9c9ce0c3467457ac0909c8d56f8d61eb 0001-Change-formatting-of-pseudo-code.patch
> From 9da73eaa1ddf40667dca300ee89430283c1e36ff Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Martinez?= <jerome at mediaarea.net>
> Date: Fri, 1 May 2015 10:54:04 +0200
> Subject: [PATCH 1/4] Change formatting of pseudo-code.
>
> In order to have the same formatting everywhere.
> Formatting is the same as in some ISO or ITU specifications.
> ---
> ffv1.lyx | 136 +++++++++++++++++++++++++++++++--------------------------------
> 1 file changed, 68 insertions(+), 68 deletions(-)
>
> diff --git a/ffv1.lyx b/ffv1.lyx
> index d4911cd..2942c10 100644
> --- a/ffv1.lyx
> +++ b/ffv1.lyx
> @@ -1957,7 +1957,7 @@ Frame
> \begin_inset Text
>
> \begin_layout Plain Layout
> -Frame {
> +Frame( ) {
> \end_layout
>
> \end_inset
> @@ -2027,7 +2027,7 @@ br
> \begin_inset space ~
> \end_inset
>
> -if (keyframe) {
> +if ( keyframe ) {
[...]
> -if(version<2)
> +if( version < 2 )
that doesnt look consistent to me
[...]
> -for(i=0; i<slice_count; i++)
> +for( i = 0; i < slice_count; i++)
should there be a spae before )
[...]
> -for(j=0; j<context_count[i];j++)
> +for( j = 0; j < context_count[i]; j++ )
[...]
> -for(k=0; k<CONTEXT_SIZE;k++)
> +for( k = 0; k < CONTEXT_SIZE; k++)
are you sure your patch makes things more and not less consistent ?
[...]
> @@ -8047,7 +8047,7 @@ QuantizationTablePerContext(i, j, scale)
> \begin_inset space ~
> \end_inset
>
> -scale*=2*len_count[i][j]-1
> +scale *= 2 * len_count[i][j] - 1
here you leave [] in other cases you replace [] by () for arrays
that mix is alot worse than just leaving C syntax
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
I have often repented speaking, but never of holding my tongue.
-- Xenocrates
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150501/d5d5e79e/attachment.asc>
More information about the ffmpeg-devel
mailing list