From bf21ce63ee4dd1c539c3b437eb2bd04bf1c8767a Mon Sep 17 00:00:00 2001
From: Jim Bankoski <jimbankoski@google.com>
Date: Sat, 5 Oct 2013 17:24:51 -0700
Subject: [PATCH] encodemb cpplint issues revisited.

Change-Id: Id5f25b74e2207bf44b6f6c8ffe548fa30fd78b4d
---
 vp9/encoder/vp9_encodemb.c | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/vp9/encoder/vp9_encodemb.c b/vp9/encoder/vp9_encodemb.c
index a610d63408..1f36f16186 100644
--- a/vp9/encoder/vp9_encodemb.c
+++ b/vp9/encoder/vp9_encodemb.c
@@ -80,8 +80,7 @@ void vp9_subtract_sb(MACROBLOCK *x, BLOCK_SIZE bsize) {
   vp9_subtract_sbuv(x, bsize);
 }
 
-
-#define RDTRUNC(RM,DM,R,D) ( (128+(R)*(RM)) & 0xFF )
+#define RDTRUNC(RM, DM, R, D) ((128 + (R) * (RM)) & 0xFF)
 typedef struct vp9_token_state vp9_token_state;
 
 struct vp9_token_state {
@@ -92,7 +91,7 @@ struct vp9_token_state {
   short         qc;
 };
 
-// TODO: experiments to find optimal multiple numbers
+// TODO(jimbankoski): experiment to find optimal RD numbers.
 #define Y1_RD_MULT 4
 #define UV_RD_MULT 2
 
@@ -272,11 +271,10 @@ static void optimize_b(MACROBLOCK *mb,
       best_index[i][1] = best;
       /* Finally, make this the new head of the trellis. */
       next = i;
-    }
-    /* There's no choice to make for a zero coefficient, so we don't
-     *  add a new trellis node, but we do need to update the costs.
-     */
-    else {
+    } else {
+      /* There's no choice to make for a zero coefficient, so we don't
+       *  add a new trellis node, but we do need to update the costs.
+       */
       band = get_coef_band(band_translate, i + 1);
       t0 = tokens[next][0].token;
       t1 = tokens[next][1].token;
-- 
GitLab