avcodec/hevc: more whitespaces to reduce difference to 064698d381e1e7790f21b0199a8930...
authorMichael Niedermayer <michaelni@gmx.at>
Sat, 2 Nov 2013 10:43:43 +0000 (11:43 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Sat, 2 Nov 2013 11:33:54 +0000 (12:33 +0100)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/hevc.c
libavcodec/hevc.h
libavcodec/hevc_cabac.c
libavcodec/hevc_filter.c
libavcodec/hevc_parser.c
libavcodec/hevc_ps.c
libavcodec/hevcdsp.c
libavcodec/hevcpred.c
libavcodec/hevcpred_template.c

index 324ba2a..642ab68 100644 (file)
@@ -29,6 +29,7 @@
 #include "libavutil/internal.h"
 #include "libavutil/md5.h"
 #include "libavutil/opt.h"
+
 #include "libavutil/pixdesc.h"
 
 #include "bytestream.h"
index 66556ae..a1fa855 100644 (file)
@@ -33,6 +33,7 @@
 #include "hevcpred.h"
 #include "hevcdsp.h"
 #include "internal.h"
+
 #include "thread.h"
 #include "videodsp.h"
 
@@ -951,7 +952,6 @@ int ff_hevc_transform_skip_flag_decode(HEVCContext *s, int c_idx);
  * Get the number of candidate references for the current frame.
  */
 int ff_hevc_frame_nb_refs(HEVCContext *s);
-
 int ff_hevc_set_new_ref(HEVCContext *s, AVFrame **frame, int poc);
 
 /**
@@ -981,6 +981,7 @@ int ff_hevc_cu_qp_delta_sign_flag(HEVCContext *s);
 int ff_hevc_cu_qp_delta_abs(HEVCContext *s);
 void ff_hevc_hls_filter(HEVCContext *s, int x, int y);
 void ff_hevc_hls_filters(HEVCContext *s, int x_ctb, int y_ctb, int ctb_size);
+
 void ff_hevc_hls_residual_coding(HEVCContext *s, int x0, int y0,
                                  int log2_trafo_size, enum ScanType scan_idx,
                                  int c_idx);
index a8cf9a7..43fd892 100644 (file)
@@ -320,8 +320,7 @@ static const uint8_t init_values[3][HEVC_CONTEXTS] = {
       154, 196, 167, 167, 154, 152, 167, 182, 182, 134, 149, 136, 153, 121,
       136, 122, 169, 208, 166, 167, 154, 152, 167, 182,
       // coeff_abs_level_greater2_flag
-      107, 167, 91, 107, 107, 167,
-    },
+      107, 167, 91, 107, 107, 167, },
 };
 
 static const uint8_t scan_1x1[1] = {
index a2b4f68..8d967a3 100644 (file)
@@ -28,6 +28,7 @@
 #include "cabac_functions.h"
 #include "golomb.h"
 #include "hevc.h"
+
 #include "bit_depth_template.c"
 
 #define LUMA 0
index c8af881..3801e1f 100644 (file)
@@ -300,9 +300,9 @@ static int hevc_split(AVCodecContext *avctx, const uint8_t *buf, int buf_size)
                 return i - 3;
             } else { // no parameter set at the beginning of the stream
                 return 0;
+            }
         }
     }
-    }
     return 0;
 }
 
index 3e84692..073ec73 100644 (file)
@@ -822,12 +822,12 @@ int ff_hevc_decode_nal_sps(HEVCContext *s)
 
     sps->nb_st_rps = get_ue_golomb_long(gb);
     if (sps->nb_st_rps > MAX_SHORT_TERM_RPS_COUNT) {
-            av_log(s->avctx, AV_LOG_ERROR,
-                   "Too many short term RPS: %d.\n",
+        av_log(s->avctx, AV_LOG_ERROR,
+               "Too many short term RPS: %d.\n",
                sps->nb_st_rps);
         ret = AVERROR_INVALIDDATA;
-            goto err;
-        }
+        goto err;
+    }
     for (i = 0; i < sps->nb_st_rps; i++) {
         if ((ret = ff_hevc_decode_short_term_rps(s, &sps->st_rps[i],
                                                  sps, 0)) < 0)
@@ -873,9 +873,10 @@ int ff_hevc_decode_nal_sps(HEVCContext *s)
                sps->output_width, sps->output_height);
         if (s->avctx->err_recognition & AV_EF_EXPLODE) {
             ret = AVERROR_INVALIDDATA;
-        goto err;
-    }
-        av_log(s->avctx, AV_LOG_WARNING, "Displaying the whole video surface.\n");
+            goto err;
+        }
+        av_log(s->avctx, AV_LOG_WARNING,
+               "Displaying the whole video surface.\n");
         sps->pic_conf_win.left_offset   =
         sps->pic_conf_win.right_offset  =
         sps->pic_conf_win.top_offset    =
@@ -1018,8 +1019,8 @@ int ff_hevc_decode_nal_pps(HEVCContext *s)
     if (pps_id >= MAX_PPS_COUNT) {
         av_log(s->avctx, AV_LOG_ERROR, "PPS id out of range: %d\n", pps_id);
         ret = AVERROR_INVALIDDATA;
-            goto err;
-        }
+        goto err;
+    }
     pps->sps_id = get_ue_golomb_long(gb);
     if (pps->sps_id >= MAX_SPS_COUNT) {
         av_log(s->avctx, AV_LOG_ERROR, "SPS id out of range: %d\n", pps->sps_id);
@@ -1082,11 +1083,11 @@ int ff_hevc_decode_nal_pps(HEVCContext *s)
         pps->num_tile_rows    = get_ue_golomb_long(gb) + 1;
         if (pps->num_tile_columns == 0 ||
             pps->num_tile_columns >= sps->width) {
-        av_log(s->avctx, AV_LOG_ERROR, "num_tile_columns_minus1 out of range: %d\n",
-                   pps->num_tile_columns - 1);
-            ret = AVERROR_INVALIDDATA;
-        goto err;
-    }
+            av_log(s->avctx, AV_LOG_ERROR, "num_tile_columns_minus1 out of range: %d\n",
+                    pps->num_tile_columns - 1);
+                ret = AVERROR_INVALIDDATA;
+            goto err;
+        }
         if (pps->num_tile_rows == 0 ||
             pps->num_tile_rows >= sps->height) {
             av_log(s->avctx, AV_LOG_ERROR, "num_tile_rows_minus1 out of range: %d\n",
@@ -1112,8 +1113,8 @@ int ff_hevc_decode_nal_pps(HEVCContext *s)
             if (sum >= sps->ctb_width) {
                 av_log(s->avctx, AV_LOG_ERROR, "Invalid tile widths.\n");
                 ret = AVERROR_INVALIDDATA;
-            goto err;
-        }
+                goto err;
+            }
             pps->column_width[pps->num_tile_columns - 1] = sps->ctb_width - sum;
 
             sum = 0;
@@ -1168,8 +1169,8 @@ int ff_hevc_decode_nal_pps(HEVCContext *s)
         av_log(s->avctx, AV_LOG_ERROR, "log2_parallel_merge_level_minus2 out of range: %d\n",
                pps->log2_parallel_merge_level - 2);
         ret = AVERROR_INVALIDDATA;
-                goto err;
-            }
+        goto err;
+    }
 
     pps->slice_header_extension_present_flag = get_bits1(gb);
     pps->pps_extension_flag                  = get_bits1(gb);
@@ -1189,9 +1190,9 @@ int ff_hevc_decode_nal_pps(HEVCContext *s)
             pps->row_height   = av_malloc_array(pps->num_tile_rows,    sizeof(*pps->row_height));
         }
         if (!pps->column_width || !pps->row_height) {
-        ret = AVERROR(ENOMEM);
-        goto err;
-    }
+            ret = AVERROR(ENOMEM);
+            goto err;
+        }
 
         for (i = 0; i < pps->num_tile_columns; i++) {
             pps->column_width[i] = ((i + 1) * sps->ctb_width) / pps->num_tile_columns -
index 6c40caf..d6fafdc 100644 (file)
@@ -161,13 +161,13 @@ void ff_hevc_dsp_init(HEVCDSPContext *hevcdsp, int bit_depth)
     hevcdsp->put_hevc_epel[0][1] = FUNC(put_hevc_epel_h, depth);            \
     hevcdsp->put_hevc_epel[1][0] = FUNC(put_hevc_epel_v, depth);            \
     hevcdsp->put_hevc_epel[1][1] = FUNC(put_hevc_epel_hv, depth);           \
-                                                                                   \
+                                                                            \
                                                                                    \
     hevcdsp->put_unweighted_pred   = FUNC(put_unweighted_pred, depth);      \
     hevcdsp->put_weighted_pred_avg = FUNC(put_weighted_pred_avg, depth);    \
                                                                             \
     hevcdsp->weighted_pred         = FUNC(weighted_pred, depth);            \
-    hevcdsp->weighted_pred_avg     = FUNC(weighted_pred_avg, depth);                   \
+    hevcdsp->weighted_pred_avg     = FUNC(weighted_pred_avg, depth);        \
     hevcdsp->hevc_h_loop_filter_luma     = FUNC(hevc_h_loop_filter_luma, depth);   \
     hevcdsp->hevc_v_loop_filter_luma     = FUNC(hevc_v_loop_filter_luma, depth);   \
     hevcdsp->hevc_h_loop_filter_chroma   = FUNC(hevc_h_loop_filter_chroma, depth); \
index 4ab8856..e4987f8 100644 (file)
@@ -21,6 +21,7 @@
  */
 
 #include "hevc.h"
+
 #include "hevcpred.h"
 
 #define BIT_DEPTH 8
index 8609723..2276023 100644 (file)
@@ -21,6 +21,7 @@
  */
 
 #include "libavutil/pixdesc.h"
+
 #include "bit_depth_template.c"
 #include "hevcpred.h"
 
@@ -557,4 +558,5 @@ static void FUNC(pred_angular_3)(uint8_t *src, const uint8_t *top,
 {
     FUNC(pred_angular)(src, top, left, stride, c_idx, mode, 1 << 5);
 }
+
 #undef POS