Cleanup: line length, indentation
authorCampbell Barton <ideasman42@gmail.com>
Wed, 20 Jan 2016 22:05:52 +0000 (09:05 +1100)
committerCampbell Barton <ideasman42@gmail.com>
Wed, 20 Jan 2016 22:42:17 +0000 (09:42 +1100)
17 files changed:
source/blender/blenlib/intern/math_statistics.c
source/blender/blenloader/intern/versioning_260.c
source/blender/editors/mesh/editmesh_knife.c
source/blender/editors/mesh/meshtools.c
source/blender/editors/sculpt_paint/paint_image.c
source/blender/editors/sculpt_paint/paint_vertex.c
source/blender/editors/sculpt_paint/sculpt.c
source/blender/editors/space_file/file_ops.c
source/blender/editors/space_image/image_ops.c
source/blender/editors/space_outliner/outliner_tools.c
source/blender/editors/space_view3d/drawvolume.c
source/blender/imbuf/intern/stereoimbuf.c
source/blender/makesrna/intern/rna_cloth.c
source/blender/makesrna/intern/rna_userdef.c
source/blender/physics/intern/implicit_blender.c
source/blender/physics/intern/implicit_eigen.cpp
source/blender/windowmanager/intern/wm_operators.c

index fbd6563e039eed9c781ce06b390d06151721a7a8..fd7418a8f7b85ab7c7fa4240f8cb65e41e76d922 100644 (file)
@@ -114,7 +114,7 @@ void BLI_covariance_m_vn_ex(
 
        CovarianceData data = {
                .cos_vn = cos_vn, .center = center, .r_covmat = r_covmat,
-           .covfac = covfac, .n = n, .nbr_cos_vn = nbr_cos_vn,
+               .covfac = covfac, .n = n, .nbr_cos_vn = nbr_cos_vn,
        };
 
        BLI_task_parallel_range(
index 027c3eb9fbf7565c84067eac5d837e0c36eda859..6dd2d99ef12480c90421191bf0bcb2213e4beaf5 100644 (file)
@@ -459,19 +459,19 @@ static void do_versions_affine_tracker_track(MovieTrackingTrack *track)
 
                if (is_zero_v2(marker->pattern_corners[0]) && is_zero_v2(marker->pattern_corners[1]) &&
                    is_zero_v2(marker->pattern_corners[2]) && is_zero_v2(marker->pattern_corners[3]))
-                       {
-                               marker->pattern_corners[0][0] = track->pat_min[0];
-                               marker->pattern_corners[0][1] = track->pat_min[1];
+               {
+                       marker->pattern_corners[0][0] = track->pat_min[0];
+                       marker->pattern_corners[0][1] = track->pat_min[1];
 
-                               marker->pattern_corners[1][0] = track->pat_max[0];
-                               marker->pattern_corners[1][1] = track->pat_min[1];
+                       marker->pattern_corners[1][0] = track->pat_max[0];
+                       marker->pattern_corners[1][1] = track->pat_min[1];
 
-                               marker->pattern_corners[2][0] = track->pat_max[0];
-                               marker->pattern_corners[2][1] = track->pat_max[1];
+                       marker->pattern_corners[2][0] = track->pat_max[0];
+                       marker->pattern_corners[2][1] = track->pat_max[1];
 
-                               marker->pattern_corners[3][0] = track->pat_min[0];
-                               marker->pattern_corners[3][1] = track->pat_max[1];
-                       }
+                       marker->pattern_corners[3][0] = track->pat_min[0];
+                       marker->pattern_corners[3][1] = track->pat_max[1];
+               }
 
                if (is_zero_v2(marker->search_min) && is_zero_v2(marker->search_max)) {
                        copy_v2_v2(marker->search_min, track->search_min);
index 0dd7b85c61228d969d79d89c9f40f3d3131490ec..3cef5478503834dc8847fc53ed8246843eb7d475 100644 (file)
@@ -1651,8 +1651,8 @@ static void knife_find_line_hits(KnifeTool_OpData *kcd)
                        hit.v = v;
 
                        /* If this isn't from an existing BMVert, it may have been added to a BMEdge originally.
-                                * knowing if the hit comes from an edge is important for edge-in-face checks later on
-                                * see: #knife_add_single_cut -> #knife_verts_edge_in_face, T42611 */
+                        * knowing if the hit comes from an edge is important for edge-in-face checks later on
+                        * see: #knife_add_single_cut -> #knife_verts_edge_in_face, T42611 */
                        if (kfe_hit) {
                                hit.kfe = kfe_hit;
                        }
index 431af56e13d84a34e1d9975248ce13715480da64..bad835b13e7c21464e48ef9ee97aee150b64eb11 100644 (file)
@@ -905,7 +905,9 @@ static float *editmesh_get_mirror_uv(BMEditMesh *em, int axis, float *uv, float
        if (isnan(uv[0]) || !finite(uv[0]) ||
            isnan(uv[1]) || !finite(uv[1])
            )
+       {
                return NULL;
+       }
 
        if (axis) {
                vec[0] = uv[0];
index a43fb902834906915060f3839d4c9dda9e47ae2c..49e5e2646593d24c9593f55d3f14e03d02d2aaf2 100644 (file)
@@ -651,7 +651,7 @@ bool paint_use_opacity_masking(Brush *brush)
               (brush->imagepaint_tool == PAINT_TOOL_SOFTEN) ||
               (brush->imagepaint_tool == PAINT_TOOL_FILL) ||
               (brush->flag & BRUSH_USE_GRADIENT) ||
-                  (brush->mtex.tex && !ELEM(brush->mtex.brush_map_mode, MTEX_MAP_MODE_TILED, MTEX_MAP_MODE_STENCIL, MTEX_MAP_MODE_3D)) ?
+              (brush->mtex.tex && !ELEM(brush->mtex.brush_map_mode, MTEX_MAP_MODE_TILED, MTEX_MAP_MODE_STENCIL, MTEX_MAP_MODE_3D)) ?
                    false : true;
 }
 
index 878c8274255c288a704c6d514472f199d8a313da..7dd96c3cdacf29ed9efc16065cd02269aeb0af18 100644 (file)
@@ -1078,7 +1078,8 @@ static bool weight_paint_sample_enum_itemf__helper(const MDeformVert *dvert, con
        }
        return found;
 }
-static EnumPropertyItem *weight_paint_sample_enum_itemf(bContext *C, PointerRNA *UNUSED(ptr), PropertyRNA *UNUSED(prop), bool *r_free)
+static EnumPropertyItem *weight_paint_sample_enum_itemf(
+        bContext *C, PointerRNA *UNUSED(ptr), PropertyRNA *UNUSED(prop), bool *r_free)
 {
        if (C) {
                wmWindow *win = CTX_wm_window(C);
@@ -2080,9 +2081,11 @@ static void wpaint_stroke_update_step(bContext *C, struct PaintStroke *stroke, P
                wpd->do_multipaint ? wpaint_blur_weight_multi : wpaint_blur_weight_single;
 
        const float pressure = RNA_float_get(itemptr, "pressure");
-       const float brush_size_pressure = BKE_brush_size_get(scene, brush) * (BKE_brush_use_size_pressure(scene, brush) ? pressure : 1.0f);
+       const float brush_size_pressure =
+               BKE_brush_size_get(scene, brush) * (BKE_brush_use_size_pressure(scene, brush) ? pressure : 1.0f);
        const float brush_alpha_value = BKE_brush_alpha_get(scene, brush);
-       const float brush_alpha_pressure = brush_alpha_value * (BKE_brush_use_alpha_pressure(scene, brush) ? pressure : 1.0f);
+       const float brush_alpha_pressure =
+               brush_alpha_value * (BKE_brush_use_alpha_pressure(scene, brush) ? pressure : 1.0f);
 
        /* intentionally don't initialize as NULL, make sure we initialize all members below */
        WeightPaintInfo wpi;
@@ -2176,7 +2179,8 @@ static void wpaint_stroke_update_step(bContext *C, struct PaintStroke *stroke, P
 #define WP_BLUR_ACCUM(v_idx_var)  \
        { \
                const unsigned int vidx = v_idx_var; \
-               const float fac = calc_vp_strength_col_dl(wp, vc, wpd->vertexcosnos[vidx].co, mval, brush_size_pressure, NULL); \
+               const float fac = calc_vp_strength_col_dl( \
+                       wp, vc, wpd->vertexcosnos[vidx].co, mval, brush_size_pressure, NULL); \
                if (fac > 0.0f) { \
                        float weight = blur_weight_func(&me->dvert[vidx], &wpi); \
                        paintweight += weight * fac; \
@@ -2704,8 +2708,10 @@ static void vpaint_stroke_update_step(bContext *C, struct PaintStroke *stroke, P
        float mval[2];
 
        const float pressure = RNA_float_get(itemptr, "pressure");
-       const float brush_size_pressure = BKE_brush_size_get(scene, brush) * (BKE_brush_use_size_pressure(scene, brush) ? pressure : 1.0f);
-       const float brush_alpha_pressure = BKE_brush_alpha_get(scene, brush) * (BKE_brush_use_alpha_pressure(scene, brush) ? pressure : 1.0f);
+       const float brush_size_pressure =
+               BKE_brush_size_get(scene, brush) * (BKE_brush_use_size_pressure(scene, brush) ? pressure : 1.0f);
+       const float brush_alpha_pressure =
+               BKE_brush_alpha_get(scene, brush) * (BKE_brush_use_alpha_pressure(scene, brush) ? pressure : 1.0f);
 
        RNA_float_get_array(itemptr, "mouse", mval);
 
@@ -3173,7 +3179,8 @@ static int paint_weight_gradient_invoke(bContext *C, wmOperator *op, const wmEve
        if (ret & OPERATOR_RUNNING_MODAL) {
                struct ARegion *ar = CTX_wm_region(C);
                if (ar->regiontype == RGN_TYPE_WINDOW) {
-                       if (event->type == LEFTMOUSE && event->val == KM_PRESS) {  /* TODO, hardcoded, extend WM_gesture_straightline_ */
+                       /* TODO, hardcoded, extend WM_gesture_straightline_ */
+                       if (event->type == LEFTMOUSE && event->val == KM_PRESS) {
                                wmGesture *gesture = op->customdata;
                                gesture->mode = 1;
                        }
index da2a987f4c75718e753d06a883d964d526f8e812..f97d877255b4984c571c29c6e142e8d72dedb8b0 100644 (file)
@@ -402,7 +402,7 @@ typedef struct SculptThreadedTaskData {
        Sculpt *sd;
        Object *ob;
        Brush *brush;
-    PBVHNode **nodes;
+       PBVHNode **nodes;
        int totnode;
 
        /* Data specific to some callbacks. */
@@ -946,7 +946,7 @@ static void calc_area_center(
 
        SculptThreadedTaskData data = {
                .sd = sd, .ob = ob, .nodes = nodes, .totnode = totnode,
-           .has_bm_orco = has_bm_orco, .area_cos = area_cos, .area_nos = NULL, .count = count,
+               .has_bm_orco = has_bm_orco, .area_cos = area_cos, .area_nos = NULL, .count = count,
        };
        BLI_mutex_init(&data.mutex);
 
@@ -986,7 +986,7 @@ static void calc_area_normal(
 
        SculptThreadedTaskData data = {
                .sd = sd, .ob = ob, .nodes = nodes, .totnode = totnode,
-           .has_bm_orco = has_bm_orco, .area_cos = NULL, .area_nos = area_nos, .count = count,
+               .has_bm_orco = has_bm_orco, .area_cos = NULL, .area_nos = area_nos, .count = count,
        };
        BLI_mutex_init(&data.mutex);
 
@@ -1024,7 +1024,7 @@ static void calc_area_normal_and_center(
 
        SculptThreadedTaskData data = {
                .sd = sd, .ob = ob, .nodes = nodes, .totnode = totnode,
-           .has_bm_orco = has_bm_orco, .area_cos = area_cos, .area_nos = area_nos, .count = count,
+               .has_bm_orco = has_bm_orco, .area_cos = area_cos, .area_nos = area_nos, .count = count,
        };
        BLI_mutex_init(&data.mutex);
 
index 121bf75c4a53b84685e4579e7a602f7e40fbb36f..1b5428cc0509ee1a66253305ac009def06adb56c 100644 (file)
@@ -1041,7 +1041,7 @@ static int bookmark_move_exec(bContext *C, wmOperator *op)
 void FILE_OT_bookmark_move(wmOperatorType *ot)
 {
        static EnumPropertyItem slot_move[] = {
-           {FILE_BOOKMARK_MOVE_TOP, "TOP", 0, "Top", "Top of the list"},
+               {FILE_BOOKMARK_MOVE_TOP, "TOP", 0, "Top", "Top of the list"},
                {FILE_BOOKMARK_MOVE_UP, "UP", 0, "Up", ""},
                {FILE_BOOKMARK_MOVE_DOWN, "DOWN", 0, "Down", ""},
                {FILE_BOOKMARK_MOVE_BOTTOM, "BOTTOM", 0, "Bottom", "Bottom of the list"},
index c35f5ae14c5714e3071be4fb935fb202d11b0bf1..4d05a87b0c741c278cb6e7fb57674712f67dea62 100644 (file)
@@ -2404,7 +2404,7 @@ void IMAGE_OT_new(wmOperatorType *ot)
        static EnumPropertyItem gen_context_items[] = {
                {GEN_CONTEXT_NONE, "NONE", 0, "None", ""},
                {GEN_CONTEXT_PAINT_CANVAS, "PAINT_CANVAS", 0, "Paint Canvas", ""},
-           {GEN_CONTEXT_PAINT_STENCIL, "PAINT_STENCIL", 0, "Paint Stencil", ""},
+               {GEN_CONTEXT_PAINT_STENCIL, "PAINT_STENCIL", 0, "Paint Stencil", ""},
                {0, NULL, 0, NULL, NULL}
        };
        
index 6e4e8e53510aa38e3f70a3612f330bed14ab7ca8..e88b4c20319107478a2eaef891f4733c30d92a86 100644 (file)
@@ -1256,7 +1256,7 @@ typedef enum eOutlinerLibOpTypes {
 
 static EnumPropertyItem outliner_lib_op_type_items[] = {
        {OL_LIB_RENAME, "RENAME", 0, "Rename", ""},
-    {OL_LIB_DELETE, "DELETE", 0, "Delete", "Delete this library and all its item from Blender (needs a save/reload)"},
+       {OL_LIB_DELETE, "DELETE", 0, "Delete", "Delete this library and all its item from Blender (needs a save/reload)"},
        {0, NULL, 0, NULL, NULL}
 
 };
index 5440fccf40e326e8cf780fc6e1037cf6970cc366..6f6dba3cdde8cba0e53744893142144984b935b0 100644 (file)
@@ -290,7 +290,7 @@ static int create_view_aligned_slices(VolumeSlicer *slicer,
 
 void draw_smoke_volume(SmokeDomainSettings *sds, Object *ob,
                        const float min[3], const float max[3],
-                          const float viewnormal[3])
+                        const float viewnormal[3])
 {
        if (!sds->tex || !sds->tex_shadow) {
                fprintf(stderr, "Could not allocate 3D texture for volume rendering!\n");
index 13a15f101e7b9654086697cce65fb7d1047404ef..19edce3da3bbd4aa2751270506b4fe285fbfd262 100644 (file)
@@ -508,7 +508,7 @@ static void imb_stereo3d_write_topbottom(Stereo3DData *s3d)
                        uchar *to = rect_to + stride_to * y * channels;
                        const uchar *from[2] = {
                            rect_left  + stride_from * y * channels,
-                               rect_right + stride_from * y * channels,
+                           rect_right + stride_from * y * channels,
                        };
 
                        memcpy(to, from[1], sizeof(uchar) * channels * stride_from);
@@ -1201,7 +1201,7 @@ static void imb_stereo3d_read_topbottom(Stereo3DData *s3d)
                        const uchar *from = rect_from + stride_from * y * channels;
                        uchar *to[2] = {
                            rect_left  + stride_to * y * channels,
-                               rect_right + stride_to * y * channels,
+                           rect_right + stride_to * y * channels,
                        };
 
                        memcpy(to[1], from, sizeof(uchar) * channels * stride_to);
index bcb3544049c7c7e52f76de7f9eceb0477eef66ff..b75a3f0320bb25ac10af401d6aa2579bdad8a6ba 100644 (file)
@@ -269,7 +269,7 @@ static void rna_def_cloth_solver_result(BlenderRNA *brna)
            {BPH_SOLVER_NUMERICAL_ISSUE, "NUMERICAL_ISSUE", 0, "Numerical Issue", "The provided data did not satisfy the prerequisites"},
            {BPH_SOLVER_NO_CONVERGENCE, "NO_CONVERGENCE", 0, "No Convergence", "Iterative procedure did not converge"},
            {BPH_SOLVER_INVALID_INPUT, "INVALID_INPUT", 0, "Invalid Input", "The inputs are invalid, or the algorithm has been improperly called"},
-               {0, NULL, 0, NULL, NULL}
+           {0, NULL, 0, NULL, NULL}
        };
        
        srna = RNA_def_struct(brna, "ClothSolverResult", NULL);
index 39562d4d8a04d4b8d1a68e42f12e5e5ce8b34063..f29cbe6ce186385a14fcbe36eb046eee17e84b06 100644 (file)
@@ -3343,7 +3343,7 @@ static void rna_def_userdef_view(BlenderRNA *brna)
        static EnumPropertyItem zoom_frame_modes[] = {
                {ZOOM_FRAME_MODE_KEEP_RANGE, "KEEP_RANGE", 0, "Keep Range", ""},
                {ZOOM_FRAME_MODE_SECONDS, "SECONDS", 0, "Seconds", ""},
-           {ZOOM_FRAME_MODE_KEYFRAMES, "KEYFRAMES", 0, "Keyframes", ""},
+               {ZOOM_FRAME_MODE_KEYFRAMES, "KEYFRAMES", 0, "Keyframes", ""},
                {0, NULL, 0, NULL, NULL}
        };
 
index 11efabfb678e6c644265bee37557205aec04772e..832d516b83944bef82487d2e8fb28a27691e30be 100644 (file)
@@ -1545,7 +1545,8 @@ BLI_INLINE bool spring_length(Implicit_Data *data, int i, int j, float r_extent[
                /*
                if (length>L) {
                        if ((clmd->sim_parms->flags & CSIMSETT_FLAG_TEARING_ENABLED) &&
-                           ( ((length-L)*100.0f/L) > clmd->sim_parms->maxspringlen )) {
+                           ( ((length-L)*100.0f/L) > clmd->sim_parms->maxspringlen ))
+                       {
                                // cut spring!
                                s->flags |= CSPRING_FLAG_DEACTIVATE;
                                return false;
index 64a75083f72c4ed1ef30d64a7266b393e389c404..ff4c705ed616edc4317b2cadfb0fbc5e20a46567 100644 (file)
@@ -903,7 +903,8 @@ BLI_INLINE bool spring_length(Implicit_Data *data, int i, int j, float r_extent[
                /*
                if (length>L) {
                        if ((clmd->sim_parms->flags & CSIMSETT_FLAG_TEARING_ENABLED) &&
-                           ( ((length-L)*100.0f/L) > clmd->sim_parms->maxspringlen )) {
+                           ( ((length-L)*100.0f/L) > clmd->sim_parms->maxspringlen ))
+                       {
                                // cut spring!
                                s->flags |= CSPRING_FLAG_DEACTIVATE;
                                return false;
index ca36c11de4d49ff90986759cbd4ee0cc00f3ebca..c553d4a6907d3d20ed42c8f1ccfb5f212f633f4d 100644 (file)
@@ -4954,7 +4954,7 @@ static void WM_OT_previews_clear(wmOperatorType *ot)
 
        ot->prop = RNA_def_enum_flag(ot->srna, "id_type", preview_id_type_items,
                                     FILTER_ID_SCE | FILTER_ID_OB | FILTER_ID_GR |
-                                        FILTER_ID_MA | FILTER_ID_LA | FILTER_ID_WO | FILTER_ID_TE | FILTER_ID_IM,
+                                    FILTER_ID_MA | FILTER_ID_LA | FILTER_ID_WO | FILTER_ID_TE | FILTER_ID_IM,
                                     "DataBlock Type", "Which datablock previews to clear");
 }