Cleanup: indentation, wrapping
authorCampbell Barton <ideasman42@gmail.com>
Thu, 14 Mar 2019 21:53:22 +0000 (08:53 +1100)
committerCampbell Barton <ideasman42@gmail.com>
Thu, 14 Mar 2019 22:54:30 +0000 (09:54 +1100)
Mostly functions wrapping args, not confirming to our style guide.

100 files changed:
source/blender/alembic/intern/abc_curves.cc
source/blender/alembic/intern/abc_customdata.cc
source/blender/alembic/intern/abc_mesh.cc
source/blender/alembic/intern/abc_nurbs.cc
source/blender/alembic/intern/abc_points.cc
source/blender/avi/intern/avi_mjpeg.c
source/blender/blenkernel/BKE_gpencil_modifier.h
source/blender/blenkernel/intern/customdata.c
source/blender/blenkernel/intern/dynamicpaint.c
source/blender/blenkernel/intern/library_query.c
source/blender/blenkernel/intern/softbody.c
source/blender/blenkernel/intern/subdiv_converter_mesh.c
source/blender/blenkernel/intern/tracking_auto.c
source/blender/blenlib/intern/noise.c
source/blender/blenloader/intern/readfile.c
source/blender/bmesh/intern/bmesh_log.c
source/blender/bmesh/intern/bmesh_mesh.c
source/blender/bmesh/intern/bmesh_opdefines.c
source/blender/bmesh/tools/bmesh_bevel.c
source/blender/collada/AnimationExporter.cpp
source/blender/collada/AnimationExporter.h
source/blender/collada/AnimationImporter.h
source/blender/collada/ArmatureExporter.h
source/blender/collada/ArmatureImporter.h
source/blender/collada/BCAnimationSampler.h
source/blender/collada/BCSampleData.cpp
source/blender/collada/DocumentImporter.cpp
source/blender/collada/EffectExporter.cpp
source/blender/collada/EffectExporter.h
source/blender/collada/ExtraHandler.h
source/blender/collada/GeometryExporter.cpp
source/blender/collada/MeshImporter.h
source/blender/collada/SceneExporter.cpp
source/blender/collada/TransformWriter.h
source/blender/compositor/nodes/COM_OutputFileNode.cpp
source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
source/blender/depsgraph/intern/builder/deg_builder_relations.cc
source/blender/draw/engines/eevee/eevee_volumes.c
source/blender/draw/engines/gpencil/gpencil_draw_cache_impl.c
source/blender/draw/engines/gpencil/gpencil_draw_utils.c
source/blender/draw/engines/gpencil/gpencil_engine.c
source/blender/draw/engines/gpencil/gpencil_render.c
source/blender/draw/engines/gpencil/gpencil_shader_fx.c
source/blender/draw/modes/object_mode.c
source/blender/editors/animation/anim_channels_edit.c
source/blender/editors/animation/anim_filter.c
source/blender/editors/armature/pose_slide.c
source/blender/editors/gpencil/annotate_draw.c
source/blender/editors/gpencil/annotate_paint.c
source/blender/editors/gpencil/drawgpencil.c
source/blender/editors/gpencil/gpencil_armature.c
source/blender/editors/gpencil/gpencil_brush.c
source/blender/editors/gpencil/gpencil_edit.c
source/blender/editors/gpencil/gpencil_fill.c
source/blender/editors/gpencil/gpencil_old.c
source/blender/editors/gpencil/gpencil_paint.c
source/blender/editors/gpencil/gpencil_primitive.c
source/blender/editors/gpencil/gpencil_select.c
source/blender/editors/gpencil/gpencil_utils.c
source/blender/editors/interface/view2d.c
source/blender/editors/io/io_collada.c
source/blender/editors/mesh/editmesh_bevel.c
source/blender/editors/mesh/editmesh_extrude.c
source/blender/editors/mesh/editmesh_intersect.c
source/blender/editors/mesh/editmesh_tools.c
source/blender/editors/object/object_modifier.c
source/blender/editors/physics/particle_edit.c
source/blender/editors/render/render_opengl.c
source/blender/editors/render/render_shading.c
source/blender/editors/sculpt_paint/paint_stroke.c
source/blender/editors/sculpt_paint/paint_vertex.c
source/blender/editors/sculpt_paint/sculpt.c
source/blender/editors/space_buttons/buttons_texture.c
source/blender/editors/space_info/info_stats.c
source/blender/editors/space_sequencer/sequencer_draw.c
source/blender/editors/space_view3d/view3d_snap.c
source/blender/editors/transform/transform.c
source/blender/editors/transform/transform_conversions.c
source/blender/freestyle/intern/blender_interface/BlenderStrokeRenderer.h
source/blender/freestyle/intern/stroke/StrokeRep.h
source/blender/gpencil_modifiers/intern/MOD_gpencilarray.c
source/blender/imbuf/intern/anim_movie.c
source/blender/imbuf/intern/cineon/cineonlib.c
source/blender/imbuf/intern/indexer.c
source/blender/makesrna/intern/rna_brush.c
source/blender/makesrna/intern/rna_gpencil.c
source/blender/makesrna/intern/rna_gpencil_modifier.c
source/blender/makesrna/intern/rna_modifier.c
source/blender/makesrna/intern/rna_nodetree.c
source/blender/makesrna/intern/rna_scene.c
source/blender/makesrna/intern/rna_sculpt_paint.c
source/blender/makesrna/intern/rna_space.c
source/blender/makesrna/intern/rna_ui_api.c
source/blender/modifiers/intern/MOD_multires.c
source/blender/nodes/shader/nodes/node_shader_mixRgb.c
source/blender/nodes/shader/nodes/node_shader_tangent.c
source/blender/nodes/shader/nodes/node_shader_vectMath.c
source/blender/python/bmesh/bmesh_py_types.c
source/blender/python/mathutils/mathutils_Matrix.c
source/blender/render/intern/source/bake_api.c

index 28c0ad0..c78f31b 100644 (file)
@@ -449,10 +449,10 @@ Mesh *AbcCurveReader::read_mesh(Mesh *existing_mesh,
        catch(Alembic::Util::Exception &ex) {
                *err_str = "Error reading curve sample; more detail on the console";
                printf("Alembic: error reading curve sample for '%s/%s' at time %f: %s\n",
-                          m_iobject.getFullName().c_str(),
-                          m_curves_schema.getName().c_str(),
-                          sample_sel.getRequestedTime(),
-                          ex.what());
+                      m_iobject.getFullName().c_str(),
+                      m_curves_schema.getName().c_str(),
+                      sample_sel.getRequestedTime(),
+                      ex.what());
                return existing_mesh;
        }
 
index 09875fd..1587f33 100644 (file)
@@ -157,9 +157,9 @@ static void write_uv(const OCompoundProperty &prop, const CDStreamConfig &config
        OV2fGeomParam param(prop, name, true, kFacevaryingScope, 1);
 
        OV2fGeomParam::Sample sample(
-               V2fArraySample(&uvs.front(), uvs.size()),
-               UInt32ArraySample(&indices.front(), indices.size()),
-               kFacevaryingScope);
+               V2fArraySample(&uvs.front(), uvs.size()),
+               UInt32ArraySample(&indices.front(), indices.size()),
+               kFacevaryingScope);
 
        param.set(sample);
 }
@@ -205,9 +205,9 @@ static void write_mcol(const OCompoundProperty &prop, const CDStreamConfig &conf
        OC4fGeomParam param(prop, name, true, kFacevaryingScope, 1);
 
        OC4fGeomParam::Sample sample(
-               C4fArraySample(&buffer.front(), buffer.size()),
-               UInt32ArraySample(&indices.front(), indices.size()),
-               kVertexScope);
+               C4fArraySample(&buffer.front(), buffer.size()),
+               UInt32ArraySample(&indices.front(), indices.size()),
+               kVertexScope);
 
        param.set(sample);
 }
index e777182..cb22b1e 100644 (file)
@@ -1101,10 +1101,10 @@ Mesh *AbcMeshReader::read_mesh(Mesh *existing_mesh,
        catch(Alembic::Util::Exception &ex) {
                *err_str = "Error reading mesh sample; more detail on the console";
                printf("Alembic: error reading mesh sample for '%s/%s' at time %f: %s\n",
-                          m_iobject.getFullName().c_str(),
-                          m_schema.getName().c_str(),
-                          sample_sel.getRequestedTime(),
-                          ex.what());
+                      m_iobject.getFullName().c_str(),
+                      m_schema.getName().c_str(),
+                      sample_sel.getRequestedTime(),
+                      ex.what());
                return existing_mesh;
        }
 
@@ -1350,10 +1350,10 @@ void AbcSubDReader::readObjectData(Main *bmain, const Alembic::Abc::ISampleSelec
        }
        catch(Alembic::Util::Exception &ex) {
                printf("Alembic: error reading mesh sample for '%s/%s' at time %f: %s\n",
-                          m_iobject.getFullName().c_str(),
-                          m_schema.getName().c_str(),
-                          sample_sel.getRequestedTime(),
-                          ex.what());
+                      m_iobject.getFullName().c_str(),
+                      m_schema.getName().c_str(),
+                      sample_sel.getRequestedTime(),
+                      ex.what());
                return;
        }
 
@@ -1398,10 +1398,10 @@ Mesh *AbcSubDReader::read_mesh(Mesh *existing_mesh,
        catch(Alembic::Util::Exception &ex) {
                *err_str = "Error reading mesh sample; more detail on the console";
                printf("Alembic: error reading mesh sample for '%s/%s' at time %f: %s\n",
-                          m_iobject.getFullName().c_str(),
-                          m_schema.getName().c_str(),
-                          sample_sel.getRequestedTime(),
-                          ex.what());
+                      m_iobject.getFullName().c_str(),
+                      m_schema.getName().c_str(),
+                      sample_sel.getRequestedTime(),
+                      ex.what());
                return existing_mesh;
        }
 
index b0cc9fc..463396c 100644 (file)
@@ -257,10 +257,10 @@ void AbcNurbsReader::readObjectData(Main *bmain, const Alembic::Abc::ISampleSele
                }
                catch(Alembic::Util::Exception &ex) {
                        printf("Alembic: error reading nurbs sample for '%s/%s' at time %f: %s\n",
-                                  m_iobject.getFullName().c_str(),
-                                  schema.getName().c_str(),
-                                  sample_sel.getRequestedTime(),
-                                  ex.what());
+                              m_iobject.getFullName().c_str(),
+                              schema.getName().c_str(),
+                              sample_sel.getRequestedTime(),
+                              ex.what());
                        return;
                }
 
index d9b78f8..88154da 100644 (file)
@@ -223,10 +223,10 @@ struct Mesh *AbcPointsReader::read_mesh(struct Mesh *existing_mesh,
        catch(Alembic::Util::Exception &ex) {
                *err_str = "Error reading points sample; more detail on the console";
                printf("Alembic: error reading points sample for '%s/%s' at time %f: %s\n",
-                          m_iobject.getFullName().c_str(),
-                          m_schema.getName().c_str(),
-                          sample_sel.getRequestedTime(),
-                          ex.what());
+                      m_iobject.getFullName().c_str(),
+                      m_schema.getName().c_str(),
+                      sample_sel.getRequestedTime(),
+                      ex.what());
                return existing_mesh;
        }
 
index 740f096..249cb57 100644 (file)
@@ -337,18 +337,20 @@ void *avi_converter_to_mjpeg(AviMovie *movie, int stream, unsigned char *buffer,
                buf = imb_alloc_pixels(movie->header->Height, movie->header->Width, 3, sizeof(unsigned char), "avi.avi_converter_to_mjpeg 1");
 
                if (buf) {
-                       Compress_JPEG(movie->streams[stream].sh.Quality / 100,
-                                     buf, buffer,
-                                     movie->header->Width,
-                                     movie->header->Height / 2,
-                                     bufsize / 2);
+                       Compress_JPEG(
+                               movie->streams[stream].sh.Quality / 100,
+                               buf, buffer,
+                               movie->header->Width,
+                               movie->header->Height / 2,
+                               bufsize / 2);
                        *size += numbytes;
                        numbytes = 0;
-                       Compress_JPEG(movie->streams[stream].sh.Quality / 100,
-                                     buf + *size, buffer + (size_t)(movie->header->Height / 2) * (size_t)movie->header->Width * 3,
-                                     movie->header->Width,
-                                     movie->header->Height / 2,
-                                     bufsize / 2);
+                       Compress_JPEG(
+                               movie->streams[stream].sh.Quality / 100,
+                               buf + *size, buffer + (size_t)(movie->header->Height / 2) * (size_t)movie->header->Width * 3,
+                               movie->header->Width,
+                               movie->header->Height / 2,
+                               bufsize / 2);
                        *size += numbytes;
                }
        }
index fe95904..585ea18 100644 (file)
@@ -164,7 +164,7 @@ typedef struct GpencilModifierTypeInfo {
         * This function is optional.
         */
        int (*remapTime)(struct GpencilModifierData *md, struct Depsgraph *depsgraph,
-               struct Scene *scene, struct Object *ob, struct bGPDlayer *gpl, int cfra);
+                        struct Scene *scene, struct Object *ob, struct bGPDlayer *gpl, int cfra);
 
        /**
         * Initialize new instance data for this modifier type, this function
index 56847ad..cdb905f 100644 (file)
@@ -2319,8 +2319,8 @@ static void CustomData_copy_data_layer(
        if (!count || !src_data || !dst_data) {
                if (count && !(src_data == NULL && dst_data == NULL)) {
                        CLOG_WARN(&LOG, "null data for %s type (%p --> %p), skipping",
-                                     layerType_getName(source->layers[src_i].type),
-                                     (void *)src_data, (void *)dst_data);
+                                 layerType_getName(source->layers[src_i].type),
+                                 (void *)src_data, (void *)dst_data);
                }
                return;
        }
index daadc2e..eeaf071 100644 (file)
@@ -2402,13 +2402,14 @@ static float dist_squared_to_looptri_uv_edges(const MLoopTri *mlooptri, const ML
 
        for (int i = 0; i < 3; i++) {
                const float dist_squared = dist_squared_to_line_segment_v2(
-                       point,
-                       mloopuv[mlooptri[tri_index].tri[(i + 0)]].uv,
-                       mloopuv[mlooptri[tri_index].tri[(i + 1) % 3]].uv
+                       point,
+                       mloopuv[mlooptri[tri_index].tri[(i + 0)]].uv,
+                       mloopuv[mlooptri[tri_index].tri[(i + 1) % 3]].uv
                );
 
-               if (dist_squared < min_distance)
+               if (dist_squared < min_distance) {
                        min_distance = dist_squared;
+               }
        }
 
        return min_distance;
index 267699b..72e9d74 100644 (file)
@@ -1204,9 +1204,9 @@ static int foreach_libblock_id_users_callback(void *user_data, ID *UNUSED(self_i
                if (*id_p == iter->id) {
 #if 0
                        printf("%s uses %s (refcounted: %d, userone: %d, used_one: %d, used_one_active: %d, indirect_usage: %d)\n",
-                                  iter->curr_id->name, iter->id->name, (cb_flag & IDWALK_USER) ? 1 : 0, (cb_flag & IDWALK_USER_ONE) ? 1 : 0,
-                                  (iter->id->tag & LIB_TAG_EXTRAUSER) ? 1 : 0, (iter->id->tag & LIB_TAG_EXTRAUSER_SET) ? 1 : 0,
-                                  (cb_flag & IDWALK_INDIRECT_USAGE) ? 1 : 0);
+                              iter->curr_id->name, iter->id->name, (cb_flag & IDWALK_USER) ? 1 : 0, (cb_flag & IDWALK_USER_ONE) ? 1 : 0,
+                              (iter->id->tag & LIB_TAG_EXTRAUSER) ? 1 : 0, (iter->id->tag & LIB_TAG_EXTRAUSER_SET) ? 1 : 0,
+                              (cb_flag & IDWALK_INDIRECT_USAGE) ? 1 : 0);
 #endif
                        if (cb_flag & IDWALK_CB_INDIRECT_USAGE) {
                                iter->count_indirect++;
index 481eb61..d4a0ad7 100644 (file)
@@ -1443,13 +1443,14 @@ static void _scan_for_ext_spring_forces(Scene *scene, Object *ob, float timenow,
                        if (bs->springtype == SB_EDGE) {
                                /* +++ springs colliding */
                                if (ob->softflag & OB_SB_EDGECOLL) {
-                                       if ( sb_detect_edge_collisionCached (sb->bpoint[bs->v1].pos, sb->bpoint[bs->v2].pos,
-                                               &damp, feedback, ob, timenow)) {
-                                                       add_v3_v3(bs->ext_force, feedback);
-                                                       bs->flag |= BSF_INTERSECT;
-                                                       //bs->cf=damp;
-                                                       bs->cf=sb->choke*0.01f;
-
+                                       if (sb_detect_edge_collisionCached(
+                                                   sb->bpoint[bs->v1].pos, sb->bpoint[bs->v2].pos,
+                                                   &damp, feedback, ob, timenow))
+                                       {
+                                               add_v3_v3(bs->ext_force, feedback);
+                                               bs->flag |= BSF_INTERSECT;
+                                               //bs->cf=damp;
+                                               bs->cf=sb->choke*0.01f;
                                        }
                                }
                                /* ---- springs colliding */
index 8aac77c..00a2436 100644 (file)
@@ -324,12 +324,12 @@ static void initialize_manifold_index_array(const BLI_bitmap *used_map,
        int *indices = NULL;
        if (indices_r != NULL) {
                indices = MEM_malloc_arrayN(
-               num_elements, sizeof(int), "manifold indices");
+                       num_elements, sizeof(int), "manifold indices");
        }
        int *indices_reverse = NULL;
        if (indices_reverse_r != NULL) {
                indices_reverse = MEM_malloc_arrayN(
-               num_elements, sizeof(int), "manifold indices reverse");
+                       num_elements, sizeof(int), "manifold indices reverse");
        }
        int offset = 0;
        for (int i = 0; i < num_elements; i++) {
index 38124dd..bddb531 100644 (file)
@@ -538,7 +538,7 @@ void BKE_autotrack_context_sync(AutoTrackContext *context)
                for (track = 0; track < context->num_tracks; ++track) {
                        AutoTrackOptions *options = &context->options[track];
                        int track_frame = BKE_movieclip_remap_scene_to_clip_frame(
-                               context->clips[options->clip_index], frame);
+                               context->clips[options->clip_index], frame);
                        if (options->is_failed) {
                                if (options->failed_frame == track_frame) {
                                        MovieTrackingMarker *prev_marker =
index 8126bdf..e999a50 100644 (file)
@@ -281,9 +281,9 @@ static float newPerlin(float x, float y, float z)
 {
        int A, AA, AB, B, BA, BB;
        float u = floor(x), v = floor(y), w = floor(z);
-       int X = ((int)u) & 255,
-               Y = ((int)v) & 255,
-               Z = ((int)w) & 255;   /* FIND UNIT CUBE THAT CONTAINS POINT */
+       int X = ((int)u) & 255;
+       int Y = ((int)v) & 255;
+       int Z = ((int)w) & 255;   /* FIND UNIT CUBE THAT CONTAINS POINT */
        x -= u;             /* FIND RELATIVE X,Y,Z */
        y -= v;             /* OF POINT IN CUBE. */
        z -= w;
index cc34aa1..655b177 100644 (file)
@@ -6745,15 +6745,13 @@ static void direct_link_scene(FileData *fd, Scene *sce)
                                        seq->strip->stripdata = NULL;
                                }
                                if (seq->flag & SEQ_USE_CROP) {
-                                       seq->strip->crop = newdataadr(
-                                               fd, seq->strip->crop);
+                                       seq->strip->crop = newdataadr(fd, seq->strip->crop);
                                }
                                else {
                                        seq->strip->crop = NULL;
                                }
                                if (seq->flag & SEQ_USE_TRANSFORM) {
-                                       seq->strip->transform = newdataadr(
-                                               fd, seq->strip->transform);
+                                       seq->strip->transform = newdataadr(fd, seq->strip->transform);
                                }
                                else {
                                        seq->strip->transform = NULL;
index ec7c223..77dd6aa 100644 (file)
@@ -1126,10 +1126,10 @@ void bm_log_print(const BMLog *log, const char *description)
 
        printf("%s:\n", description);
        printf("    % 2d: [ initial ]%s\n", 0,
-                  (!log->current_entry) ? current : "");
+              (!log->current_entry) ? current : "");
        for (entry = log->entries.first, i = 1; entry; entry = entry->next, i++) {
                printf("    % 2d: [%p]%s\n", i, entry,
-                          (entry == log->current_entry) ? current : "");
+                      (entry == log->current_entry) ? current : "");
        }
 }
 #endif
index 1e2612d..a1f2281 100644 (file)
@@ -1074,7 +1074,7 @@ void BM_lnorspacearr_store(BMesh *bm, float(*r_lnors)[3])
        int cd_loop_clnors_offset = CustomData_get_offset(&bm->ldata, CD_CUSTOMLOOPNORMAL);
 
        BM_loops_calc_normal_vcos(
-               bm, NULL, NULL, NULL, true, M_PI, r_lnors, bm->lnor_spacearr, NULL, cd_loop_clnors_offset, false);
+               bm, NULL, NULL, NULL, true, M_PI, r_lnors, bm->lnor_spacearr, NULL, cd_loop_clnors_offset, false);
        bm->spacearr_dirty &= ~(BM_SPACEARR_DIRTY | BM_SPACEARR_DIRTY_ALL);
 }
 
@@ -1188,7 +1188,7 @@ void BM_lnorspace_rebuild(BMesh *bm, bool preserve_clnor)
                BKE_lnor_spacearr_clear(bm->lnor_spacearr);
        }
        BM_loops_calc_normal_vcos(
-               bm, NULL, NULL, NULL, true, M_PI, r_lnors, bm->lnor_spacearr, NULL, cd_loop_clnors_offset, true);
+               bm, NULL, NULL, NULL, true, M_PI, r_lnors, bm->lnor_spacearr, NULL, cd_loop_clnors_offset, true);
        MEM_freeN(r_lnors);
 
        BM_ITER_MESH(f, &fiter, bm, BM_FACES_OF_MESH) {
@@ -1352,17 +1352,17 @@ static int bm_loop_normal_mark_indiv(BMesh *bm, BLI_bitmap *loops)
                        while ((ese_prev = ese_prev->prev)) {
                                if (ese_prev->htype == BM_VERT) {
                                        bm_loop_normal_mark_indiv_do_loop(
-                                               BM_face_vert_share_loop((BMFace *)ese->ele, (BMVert *)ese_prev->ele),
-                                               loops, bm->lnor_spacearr, &totloopsel);
+                                               BM_face_vert_share_loop((BMFace *)ese->ele, (BMVert *)ese_prev->ele),
+                                               loops, bm->lnor_spacearr, &totloopsel);
                                }
                                else if (ese_prev->htype == BM_EDGE) {
                                        bm_loop_normal_mark_indiv_do_loop(
-                                               BM_face_vert_share_loop((BMFace *)ese->ele, ((BMEdge *)ese_prev->ele)->v1),
-                                               loops, bm->lnor_spacearr, &totloopsel);
+                                               BM_face_vert_share_loop((BMFace *)ese->ele, ((BMEdge *)ese_prev->ele)->v1),
+                                               loops, bm->lnor_spacearr, &totloopsel);
 
                                        bm_loop_normal_mark_indiv_do_loop(
-                                               BM_face_vert_share_loop((BMFace *)ese->ele, ((BMEdge *)ese_prev->ele)->v2),
-                                               loops, bm->lnor_spacearr, &totloopsel);
+                                               BM_face_vert_share_loop((BMFace *)ese->ele, ((BMEdge *)ese_prev->ele)->v2),
+                                               loops, bm->lnor_spacearr, &totloopsel);
                                }
                        }
                }
index 35543aa..0ed1338 100644 (file)
@@ -1765,11 +1765,11 @@ static BMOpDefine bmo_bevel_def = {
         {"mark_sharp", BMO_OP_SLOT_BOOL},              /* extend edge data to allow sharp edges to run across bevels */
         {"harden_normals", BMO_OP_SLOT_BOOL},  /* harden normals */
         {"face_strength_mode", BMO_OP_SLOT_INT, {(int)BMO_OP_SLOT_SUBTYPE_INT_ENUM},
-               bmo_enum_bevel_face_strength_type}, /* whether to set face strength, and which faces to set if so */
+         bmo_enum_bevel_face_strength_type}, /* whether to set face strength, and which faces to set if so */
         {"miter_outer", BMO_OP_SLOT_INT, {(int)BMO_OP_SLOT_SUBTYPE_INT_ENUM},
-               bmo_enum_bevel_miter_type},         /* outer miter kind */
+         bmo_enum_bevel_miter_type},         /* outer miter kind */
         {"miter_inner", BMO_OP_SLOT_INT, {(int)BMO_OP_SLOT_SUBTYPE_INT_ENUM},
-               bmo_enum_bevel_miter_type},         /* outer miter kind */
+         bmo_enum_bevel_miter_type},         /* outer miter kind */
         {"spread", BMO_OP_SLOT_FLT},           /* amount to offset beveled edge */
         {"smoothresh", BMO_OP_SLOT_FLT},       /* for passing mesh's smoothresh, used in hardening */
         {{'\0'}},
index 803a55b..798e357 100644 (file)
@@ -823,9 +823,10 @@ static bool point_between_edges(float co[3], BMVert *v, BMFace *f, EdgeHalf *e1,
  */
 static void offset_meet(EdgeHalf *e1, EdgeHalf *e2, BMVert *v, BMFace *f, bool edges_between, float meetco[3])
 {
-       float dir1[3], dir2[3], dir1n[3], dir2p[3], norm_v[3], norm_v1[3], norm_v2[3],
-               norm_perp1[3], norm_perp2[3], off1a[3], off1b[3], off2a[3], off2b[3],
-               isect2[3], dropco[3], plane[4], ang, d;
+       float dir1[3], dir2[3], dir1n[3], dir2p[3], norm_v[3], norm_v1[3], norm_v2[3];
+       float norm_perp1[3], norm_perp2[3], off1a[3], off1b[3], off2a[3], off2b[3];
+       float isect2[3], dropco[3], plane[4];
+       float ang, d;
        BMVert *closer_v;
        EdgeHalf *e, *e1next, *e2prev;
        BMFace *ff;
@@ -1903,12 +1904,13 @@ static void bevel_harden_normals(BMesh *bm, BevelParams *bp)
                                }
                        }
                        if (pnorm) {
-                               if (pnorm == norm)
+                               if (pnorm == norm) {
                                        normalize_v3(norm);
+                               }
                                l_index = BM_elem_index_get(l);
                                clnors = BM_ELEM_CD_GET_VOID_P(l, cd_clnors_offset);
                                BKE_lnor_space_custom_normal_to_data(
-                                       bm->lnor_spacearr->lspacearr[l_index], pnorm, clnors);
+                                       bm->lnor_spacearr->lspacearr[l_index], pnorm, clnors);
                        }
                }
        }
@@ -2527,7 +2529,7 @@ static void print_adjust_stats(BoundVert *vstart)
                        delta = fabs(eright->offset_r - eleft->offset_l);
                        delta_pct = 100.0 * delta / eright->offset_r_spec;
                        printf("e%d r(%f) vs l(%f): abs(delta)=%f, delta_pct=%f\n",
-                               BM_elem_index_get(eright->e), eright->offset_r, eleft->offset_l, delta, delta_pct);
+                              BM_elem_index_get(eright->e), eright->offset_r, eleft->offset_l, delta, delta_pct);
                        even_residual2 += delta * delta;
                        if (delta > max_even_r)
                                max_even_r = delta;
@@ -2546,7 +2548,7 @@ static void print_adjust_stats(BoundVert *vstart)
                        delta = eright->offset_r - eright->offset_r_spec;
                        delta_pct = 100.0 * delta / eright->offset_r_spec;
                        printf("e%d r(%f) vs r spec(%f): delta=%f, delta_pct=%f\n",
-                               BM_elem_index_get(eright->e), eright->offset_r, eright->offset_r_spec, delta, delta_pct);
+                              BM_elem_index_get(eright->e), eright->offset_r, eright->offset_r_spec, delta, delta_pct);
                        spec_residual2 += delta * delta;
                        delta = fabs(delta);
                        delta_pct = fabs(delta_pct);
@@ -2558,7 +2560,7 @@ static void print_adjust_stats(BoundVert *vstart)
                        delta = eleft->offset_l - eleft->offset_l_spec;
                        delta_pct = 100.0 * delta / eright->offset_l_spec;
                        printf("e%d l(%f) vs l spec(%f): delta=%f, delta_pct=%f\n",
-                               BM_elem_index_get(eright->e), eleft->offset_l, eleft->offset_l_spec, delta, delta_pct);
+                              BM_elem_index_get(eright->e), eleft->offset_l, eleft->offset_l_spec, delta, delta_pct);
                        spec_residual2 += delta * delta;
                        delta = fabs(delta);
                        delta_pct = fabs(delta_pct);
@@ -2749,7 +2751,7 @@ static void adjust_the_cycle_or_chain(BoundVert *vstart, bool iscycle)
                        EIG_linear_solver_right_hand_side_add(solver, 0, row, weight * enextleft->offset_l);
 #ifdef DEBUG_ADJUST
                        printf("b[%d]=%f * %f, for e%d->offset_l\n", row, weight, enextleft->offset_l,
-                               BM_elem_index_get(enextleft->e));
+                              BM_elem_index_get(enextleft->e));
 #endif
                }
                else {
@@ -4134,13 +4136,14 @@ static VMesh *square_out_adj_vmesh(BevelParams *bp, BevVert *bv)
                for (j = 1; j < ns2 + odd; j++) {
                        for (k = 1; k <= ns2; k++) {
                                ikind = isect_line_line_v3(
-                                       mesh_vert(vm, i, 0, k)->co, centerline + clstride * im1 + 3 * k,
-                                       mesh_vert(vm, i, j, 0)->co, centerline + clstride * i + 3 * j,
-                                       meet1, meet2);
+                                       mesh_vert(vm, i, 0, k)->co, centerline + clstride * im1 + 3 * k,
+                                       mesh_vert(vm, i, j, 0)->co, centerline + clstride * i + 3 * j,
+                                       meet1, meet2);
                                if (ikind == 0) {
                                        /* how can this happen? fall back on interpolation in one direction if it does */
-                                       interp_v3_v3v3(mesh_vert(vm, i, j, k)->co,
-                                               mesh_vert(vm, i, 0, k)->co, centerline + clstride * im1 + 3 * k, j * ns2inv);
+                                       interp_v3_v3v3(
+                                               mesh_vert(vm, i, j, k)->co,
+                                               mesh_vert(vm, i, 0, k)->co, centerline + clstride * im1 + 3 * k, j * ns2inv);
                                }
                                else if (ikind == 1) {
                                        copy_v3_v3(mesh_vert(vm, i, j, k)->co, meet1);
index ebb2a9d..e9babea 100644 (file)
@@ -92,11 +92,11 @@ bool AnimationExporter::exportAnimations()
 
                try {
                        animation_sampler.sample_scene(
-                               export_settings->sampling_rate,
-                               /*keyframe_at_end = */ true,
-                               export_settings->open_sim,
-                               export_settings->keep_keyframes,
-                               export_settings->export_animation_type
+                               export_settings->sampling_rate,
+                               /*keyframe_at_end = */ true,
+                               export_settings->open_sim,
+                               export_settings->keep_keyframes,
+                               export_settings->export_animation_type
                        );
 
                        openLibrary();
index 295ec66..7af4777 100644 (file)
@@ -145,48 +145,48 @@ protected:
 
        /* export animation as separate trans/rot/scale curves */
        void export_curve_animation_set(
-               Object *ob,
-               BCAnimationSampler &sampler,
-               bool export_tm_curves);
+               Object *ob,
+               BCAnimationSampler &sampler,
+               bool export_tm_curves);
 
        /* export one single curve */
        void export_curve_animation(
-               Object *ob,
-               BCAnimationCurve &curve);
+               Object *ob,
+               BCAnimationCurve &curve);
 
        /* export animation as matrix data */
        void export_matrix_animation(
-               Object *ob,
-               BCAnimationSampler &sampler);
+               Object *ob,
+               BCAnimationSampler &sampler);
 
        /* step through the bone hierarchy */
        void export_bone_animations_recursive(
-               Object *ob_arm,
-               Bone *bone,
-               BCAnimationSampler &sampler);
+               Object *ob_arm,
+               Bone *bone,
+               BCAnimationSampler &sampler);
 
        /* Export for one bone */
        void export_bone_animation(
-               Object *ob,
-               Bone *bone,
-               BCFrames &frames,
-               BCMatrixSampleMap &outmats);
+               Object *ob,
+               Bone *bone,
+               BCFrames &frames,
+               BCMatrixSampleMap &outmats);
 
        /* call to the low level collada exporter */
        void export_collada_curve_animation(
-               std::string id,
-               std::string name,
-               std::string target,
-               std::string axis,
-               BCAnimationCurve &curve);
+               std::string id,
+               std::string name,
+               std::string target,
+               std::string axis,
+               BCAnimationCurve &curve);
 
        /* call to the low level collada exporter */
        void export_collada_matrix_animation(
-               std::string id,
-               std::string name,
-               std::string target,
-               BCFrames &frames,
-               BCMatrixSampleMap &outmats);
+               std::string id,
+               std::string name,
+               std::string target,
+               BCFrames &frames,
+               BCMatrixSampleMap &outmats);
 
        BCAnimationCurve *get_modified_export_curve(Object *ob, BCAnimationCurve &curve, BCAnimationCurveMap &curves);
 
@@ -197,40 +197,41 @@ protected:
 
        /* Input and Output sources (single valued) */
        std::string collada_source_from_values(
-               BC_animation_source_type tm_channel,
-               COLLADASW::InputSemantic::Semantics semantic,
-               std::vector<float> &values,
-               const std::string& anim_id,
-               const std::string axis_name);
+               BC_animation_source_type tm_channel,
+               COLLADASW::InputSemantic::Semantics semantic,
+               std::vector<float> &values,
+               const std::string& anim_id,
+               const std::string axis_name);
 
        /* Output sources (matrix data) */
        std::string collada_source_from_values(
-               BCMatrixSampleMap &samples,
-               const std::string& anim_id);
+               BCMatrixSampleMap &samples,
+               const std::string& anim_id);
 
        /* Interpolation sources */
        std::string collada_linear_interpolation_source(
-               int tot,
-               const std::string& anim_id);
+               int tot,
+               const std::string& anim_id);
 
        /* source ID = animation_name + semantic_suffix */
 
        std::string get_semantic_suffix(COLLADASW::InputSemantic::Semantics semantic);
 
-       void add_source_parameters(COLLADASW::SourceBase::ParameterNameList& param,
-               COLLADASW::InputSemantic::Semantics semantic,
-               bool is_rot,
-               const std::string axis,
-               bool transform);
+       void add_source_parameters(
+               COLLADASW::SourceBase::ParameterNameList& param,
+               COLLADASW::InputSemantic::Semantics semantic,
+               bool is_rot,
+               const std::string axis,
+               bool transform);
 
        int get_point_in_curve(BCBezTriple &bezt, COLLADASW::InputSemantic::Semantics semantic, bool is_angle, float *values);
        int get_point_in_curve(const BCAnimationCurve &curve, float sample_frame, COLLADASW::InputSemantic::Semantics semantic, bool is_angle, float *values);
 
        std::string collada_tangent_from_curve(
-               COLLADASW::InputSemantic::Semantics semantic,
-               BCAnimationCurve &curve,
-               const std::string& anim_id,
-               const std::string axis_name);
+               COLLADASW::InputSemantic::Semantics semantic,
+               BCAnimationCurve &curve,
+               const std::string& anim_id,
+               const std::string axis_name);
 
        std::string collada_interpolation_source(const BCAnimationCurve &curve, const std::string& anim_id, std::string axis_name, bool *has_tangents);
 
@@ -251,8 +252,8 @@ protected:
 
 #ifdef WITH_MORPH_ANIMATION
        void export_morph_animation(
-               Object *ob,
-               BCAnimationSampler &sampler);
+               Object *ob,
+               BCAnimationSampler &sampler);
 #endif
 
 };
index e5d431a..dfb3f5c 100644 (file)
@@ -180,11 +180,12 @@ public:
        // prerequisites:
        // animlist_map - map animlist id -> animlist
        // curve_map - map anim id -> curve(s)
-       Object *translate_animation_OLD(COLLADAFW::Node *node,
-               std::map<COLLADAFW::UniqueId, Object *>& object_map,
-               std::map<COLLADAFW::UniqueId, COLLADAFW::Node *>& root_map,
-               COLLADAFW::Transformation::TransformationType tm_type,
-               Object *par_job = NULL);
+       Object *translate_animation_OLD(
+               COLLADAFW::Node *node,
+               std::map<COLLADAFW::UniqueId, Object *>& object_map,
+               std::map<COLLADAFW::UniqueId, COLLADAFW::Node *>& root_map,
+               COLLADAFW::Transformation::TransformationType tm_type,
+               Object *par_job = NULL);
 
        void find_frames( std::vector<float>* frames, std::vector<FCurve*>* curves );
        void find_frames_old( std::vector<float>* frames, COLLADAFW::Node * node, COLLADAFW::Transformation::TransformationType tm_type );
index d5f8081..11f8536 100644 (file)
@@ -61,10 +61,10 @@ public:
        {}
 
        void add_armature_bones(
-               Object *ob_arm,
-               ViewLayer *view_layer,
-               SceneExporter *se,
-               std::vector<Object *>& child_objects);
+               Object *ob_arm,
+               ViewLayer *view_layer,
+               SceneExporter *se,
+               std::vector<Object *>& child_objects);
 
        bool add_instance_controller(Object *ob);
 
@@ -85,10 +85,10 @@ private:
        // Scene, SceneExporter and the list of child_objects
        // are required for writing bone parented objects
        void add_bone_node(
-               Bone *bone,
-               Object *ob_arm,
-               SceneExporter *se,
-               std::vector<Object *>& child_objects);
+               Bone *bone,
+               Object *ob_arm,
+               SceneExporter *se,
+               std::vector<Object *>& child_objects);
 
        void add_bone_transform(Object *ob_arm, Bone *bone, COLLADASW::Node& node);
 
index 4715b31..4c82b1e 100644 (file)
@@ -100,8 +100,9 @@ private:
        JointData *get_joint_data(COLLADAFW::Node *node);
 #endif
 
-       int create_bone(SkinInfo* skin, COLLADAFW::Node *node, EditBone *parent, int totchild,
-               float parent_mat[4][4], bArmature *arm, std::vector<std::string> &layer_labels);
+       int create_bone(
+               SkinInfo* skin, COLLADAFW::Node *node, EditBone *parent, int totchild,
+               float parent_mat[4][4], bArmature *arm, std::vector<std::string> &layer_labels);
 
        BoneExtended &add_bone_extended(EditBone *bone, COLLADAFW::Node * node, int sibcount, std::vector<std::string> &layer_labels, BoneExtensionMap &extended_bones);
 
index 19ccb88..95ec642 100644 (file)
@@ -175,11 +175,11 @@ public:
        void add_object(Object *ob);
 
        void sample_scene(
-               int sampling_rate,
-               int keyframe_at_end,
-               bool for_opensim,
-               bool keep_keyframes,
-               BC_export_animation_type export_animation_type);
+               int sampling_rate,
+               int keyframe_at_end,
+               bool for_opensim,
+               bool keep_keyframes,
+               BC_export_animation_type export_animation_type);
 
        BCAnimationCurveMap *get_curves(Object *ob);
        void get_object_frames(BCFrames &frames, Object *ob);
index 936d48c..812ac3c 100644 (file)
@@ -95,9 +95,9 @@ const bool BCSample::get_value(std::string channel_target, const int array_index
        else if (channel_target == "scale") {
                *val = obmat.scale()[array_index];
        }
-       else if (
-               channel_target == "rotation" ||
-               channel_target == "rotation_euler") {
+       else if (channel_target == "rotation" ||
+                channel_target == "rotation_euler")
+       {
                *val = obmat.rotation()[array_index];
        }
        else if (channel_target == "rotation_quat") {
index 97d4f05..f784c81 100644 (file)
@@ -474,10 +474,10 @@ void DocumentImporter::report_unknown_reference(const COLLADAFW::Node &node, con
        std::string id = node.getOriginalId();
        std::string name = node.getName();
        fprintf(stderr,
-               "error: node id=\"%s\", name=\"%s\" refers to an undefined %s.\n",
-               id.c_str(),
-               name.c_str(),
-               object_type.c_str());
+               "error: node id=\"%s\", name=\"%s\" refers to an undefined %s.\n",
+               id.c_str(),
+               name.c_str(),
+               object_type.c_str());
 }
 
 std::vector<Object *> *DocumentImporter::write_node(COLLADAFW::Node *node, COLLADAFW::Node *parent_node, Scene *sce, Object *par, bool is_library_node)
@@ -496,10 +496,10 @@ std::vector<Object *> *DocumentImporter::write_node(COLLADAFW::Node *node, COLLA
        std::vector<Object *> *root_objects = new std::vector<Object *>();
 
        fprintf(stderr,
-               "| %s id='%s', name='%s'\n",
-               is_joint ? "JOINT" : "NODE ",
-               id.c_str(),
-        name.c_str() );
+               "| %s id='%s', name='%s'\n",
+               is_joint ? "JOINT" : "NODE ",
+               id.c_str(),
+               name.c_str() );
 
        if (is_joint) {
                if (parent_node == NULL && !is_library_node) {
index 3494cdb..94e86af 100644 (file)
@@ -156,9 +156,10 @@ void EffectsExporter::create_image_samplers(COLLADASW::EffectProfile &ep, KeyIma
                std::string uid(id_name(image));
                std::string key = translate_id(uid);
 
-               COLLADASW::Sampler *sampler = new COLLADASW::Sampler(COLLADASW::Sampler::SAMPLER_TYPE_2D,
-                       key + COLLADASW::Sampler::SAMPLER_SID_SUFFIX,
-                       key + COLLADASW::Sampler::SURFACE_SID_SUFFIX);
+               COLLADASW::Sampler *sampler = new COLLADASW::Sampler(
+                       COLLADASW::Sampler::SAMPLER_TYPE_2D,
+                       key + COLLADASW::Sampler::SAMPLER_SID_SUFFIX,
+                       key + COLLADASW::Sampler::SURFACE_SID_SUFFIX);
 
                sampler->setImageId(key);
 
@@ -203,9 +204,10 @@ void EffectsExporter::operator()(Material *ma, Object *ob)
                // create only one <sampler>/<surface> pair for each unique image
                if (im_samp_map.find(key) == im_samp_map.end()) {
                        //<newparam> <sampler> <source>
-                       COLLADASW::Sampler sampler(COLLADASW::Sampler::SAMPLER_TYPE_2D,
-                               key + COLLADASW::Sampler::SAMPLER_SID_SUFFIX,
-                               key + COLLADASW::Sampler::SURFACE_SID_SUFFIX);
+                       COLLADASW::Sampler sampler(
+                               COLLADASW::Sampler::SAMPLER_TYPE_2D,
+                               key + COLLADASW::Sampler::SAMPLER_SID_SUFFIX,
+                               key + COLLADASW::Sampler::SURFACE_SID_SUFFIX);
                        sampler.setImageId(key);
                        // copy values to arrays since they will live longer
                        samplers[a] = sampler;
index 3ba6420..6d42a3d 100644 (file)
@@ -60,11 +60,12 @@ private:
        void get_images(Material *ma, KeyImageMap &uid_image_map);
        void create_image_samplers(COLLADASW::EffectProfile &ep, KeyImageMap &uid_image_map, std::string &active_uv);
 
-       void writeTextures(COLLADASW::EffectProfile &ep,
-                       std::string &key,
-                       COLLADASW::Sampler *sampler,
-                       MTex *t, Image *ima,
-                       std::string &uvname );
+       void writeTextures(
+               COLLADASW::EffectProfile &ep,
+               std::string &key,
+               COLLADASW::Sampler *sampler,
+               MTex *t, Image *ima,
+               std::string &uvname );
 
        bool hasEffects(Scene *sce);
 
index 4e1e041..fef1d5c 100644 (file)
@@ -53,16 +53,16 @@ public:
 
        /** Method to ask, if the current callback handler want to read the data of the given extra element. */
        bool parseElement (
-               const char* profileName,
-               const unsigned long& elementHash,
-               const COLLADAFW::UniqueId& uniqueId,
-               COLLADAFW::Object* object);
+               const char* profileName,
+               const unsigned long& elementHash,
+               const COLLADAFW::UniqueId& uniqueId,
+               COLLADAFW::Object* object);
 
        /** For backwards compatibility with older OpenCollada, new version added object parameter */
        bool parseElement (
-               const char* profileName,
-               const unsigned long& elementHash,
-               const COLLADAFW::UniqueId& uniqueId);
+               const char* profileName,
+               const unsigned long& elementHash,
+               const COLLADAFW::UniqueId& uniqueId);
 private:
        /** Disable default copy constructor. */
        ExtraHandler(const ExtraHandler& pre);
index ba9ba79..f589e99 100644 (file)
@@ -519,10 +519,10 @@ void GeometryExporter::createVertexColorSource(std::string geom_id, Mesh *me)
                        MLoopCol *mlc = mloopcol + mpoly->loopstart;
                        for (int j = 0; j < mpoly->totloop; j++, mlc++) {
                                source.appendValues(
-                                               mlc->r / 255.0f,
-                                               mlc->g / 255.0f,
-                                               mlc->b / 255.0f,
-                                               mlc->a / 255.0f
+                                       mlc->r / 255.0f,
+                                       mlc->g / 255.0f,
+                                       mlc->b / 255.0f,
+                                       mlc->a / 255.0f
                                );
                        }
                }
index 163ecfc..08b7edd 100644 (file)
@@ -105,23 +105,26 @@ private:
        std::map<COLLADAFW::UniqueId, MaterialIdPrimitiveArrayMap> geom_uid_mat_mapping_map; // crazy name!
        std::multimap<COLLADAFW::UniqueId, COLLADAFW::UniqueId> materials_mapped_to_geom; //< materials that have already been mapped to a geometry. A pair of geom uid and mat uid, one geometry can have several materials
 
-       bool set_poly_indices(MPoly *mpoly,
-                                                 MLoop *mloop,
-                                                 int loop_index,
-                                                 unsigned int *indices,
-                                                 int loop_count);
-
-       void set_face_uv(MLoopUV *mloopuv,
-                                        UVDataWrapper &uvs,
-                                        int loop_index,
-                                        COLLADAFW::IndexList& index_list,
-                                        int count);
-
-       void set_vcol(MLoopCol *mloopcol,
-                         VCOLDataWrapper &vob,
-                         int loop_index,
-                         COLLADAFW::IndexList& index_list,
-                         int count);
+       bool set_poly_indices(
+               MPoly *mpoly,
+               MLoop *mloop,
+               int loop_index,
+               unsigned int *indices,
+               int loop_count);
+
+       void set_face_uv(
+               MLoopUV *mloopuv,
+               UVDataWrapper &uvs,
+               int loop_index,
+               COLLADAFW::IndexList& index_list,
+               int count);
+
+       void set_vcol(
+               MLoopCol *mloopcol,
+               VCOLDataWrapper &vob,
+               int loop_index,
+               COLLADAFW::IndexList& index_list,
+               int count);
 
 #ifdef COLLADA_DEBUG
        void print_index_list(COLLADAFW::IndexList& index_list);
index f09fae7..9031aa1 100644 (file)
@@ -131,10 +131,10 @@ void SceneExporter::writeNodes(Object *ob)
                }
                else {
                        TransformWriter::add_node_transform_ob(
-                               colladaNode,
-                               ob,
-                               this->export_settings->export_transformation_type,
-                               this->export_settings->limit_precision
+                               colladaNode,
+                               ob,
+                               this->export_settings->export_transformation_type,
+                               this->export_settings->limit_precision
                        );
                }
 
@@ -148,9 +148,10 @@ void SceneExporter::writeNodes(Object *ob)
                                COLLADASW::InstanceGeometry instGeom(mSW);
                                instGeom.setUrl(COLLADASW::URI(COLLADABU::Utils::EMPTY_STRING, get_geometry_id(ob, this->export_settings->use_object_instantiation)));
                                instGeom.setName(encode_xml(id_name(ob)));
-                               InstanceWriter::add_material_bindings(instGeom.getBindMaterial(),
-                                       ob,
-                                       this->export_settings->active_uv_only);
+                               InstanceWriter::add_material_bindings(
+                                       instGeom.getBindMaterial(),
+                                       ob,
+                                       this->export_settings->active_uv_only);
                                instGeom.add();
                        }
                }
index 49ed22e..3792ce8 100644 (file)
@@ -33,16 +33,16 @@ class TransformWriter
 {
 protected:
        void add_node_transform(
-               COLLADASW::Node& node,
-               float mat[4][4],
-               float parent_mat[4][4],
-               bool limit_precision=false);
+               COLLADASW::Node& node,
+               float mat[4][4],
+               float parent_mat[4][4],
+               bool limit_precision=false);
 
        void add_node_transform_ob(
-               COLLADASW::Node& node,
-               Object *ob,
-               BC_export_transformation_type transformation_type,
-               bool limit_precision = false);
+               COLLADASW::Node& node,
+               Object *ob,
+               BC_export_transformation_type transformation_type,
+               bool limit_precision = false);
 
        void add_node_transform_identity(COLLADASW::Node& node);
 
index 6adf4f6..beed19a 100644 (file)
@@ -55,8 +55,8 @@ void OutputFileNode::convertToOperations(NodeConverter &converter, const Composi
                }
                else {
                        outputOperation = new OutputOpenExrMultiLayerOperation(
-                         context.getRenderData(), context.getbNodeTree(), storage->base_path,
-                         storage->format.exr_codec, use_half_float, context.getViewName());
+                               context.getRenderData(), context.getbNodeTree(), storage->base_path,
+                               storage->format.exr_codec, use_half_float, context.getViewName());
                }
                converter.addOperation(outputOperation);
 
index eefdb80..ecb2dad 100644 (file)
@@ -497,7 +497,8 @@ void DepsgraphNodeBuilder::build_collection(
                         * might become visible too. */
                }
                else if (from_layer_collection == NULL &&
-                        !id_node->is_collection_fully_expanded) {
+                        !id_node->is_collection_fully_expanded)
+               {
                        /* Initially collection was built from layer now, and was requested
                         * to not recurs into object. But nw it's asked to recurs into all
                         * objects. */
index 2e78df7..ef5ec6a 100644 (file)
@@ -2269,30 +2269,37 @@ void DepsgraphRelationBuilder::build_object_data_geometry_datablock(ID *obdata)
                {
                        Curve *cu = (Curve *)obdata;
                        if (cu->bevobj != NULL) {
-                               ComponentKey bevob_geom_key(&cu->bevobj->id,
-                                       NodeType::GEOMETRY);
-                               add_relation(bevob_geom_key,
-                                       obdata_geom_eval_key,
-                                       "Curve Bevel Geometry");
-                               ComponentKey bevob_key(&cu->bevobj->id,
-                                       NodeType::TRANSFORM);
-                               add_relation(bevob_key,
-                                       obdata_geom_eval_key,
-                                       "Curve Bevel Transform");
+                               ComponentKey bevob_geom_key(
+                                       &cu->bevobj->id,
+                                       NodeType::GEOMETRY);
+                               add_relation(
+                                       bevob_geom_key,
+                                       obdata_geom_eval_key,
+                                       "Curve Bevel Geometry");
+                               ComponentKey bevob_key(
+                                       &cu->bevobj->id,
+                                       NodeType::TRANSFORM);
+                               add_relation(
+                                       bevob_key,
+                                       obdata_geom_eval_key,
+                                       "Curve Bevel Transform");
                                build_object(NULL, cu->bevobj);
                        }
                        if (cu->taperobj != NULL) {
-                               ComponentKey taperob_key(&cu->taperobj->id,
-                                       NodeType::GEOMETRY);
+                               ComponentKey taperob_key(
+                                       &cu->taperobj->id,
+                                       NodeType::GEOMETRY);
                                add_relation(taperob_key, obdata_geom_eval_key, "Curve Taper");
                                build_object(NULL, cu->taperobj);
                        }
                        if (cu->textoncurve != NULL) {
-                               ComponentKey textoncurve_key(&cu->textoncurve->id,
-                                       NodeType::GEOMETRY);
-                               add_relation(textoncurve_key,
-                                       obdata_geom_eval_key,
-                                       "Text on Curve");
+                               ComponentKey textoncurve_key(
+                                       &cu->textoncurve->id,
+                                       NodeType::GEOMETRY);
+                               add_relation(
+                                       textoncurve_key,
+                                       obdata_geom_eval_key,
+                                       "Text on Curve");
                                build_object(NULL, cu->textoncurve);
                        }
                        break;
index 7297b6f..5fe0144 100644 (file)
@@ -405,9 +405,10 @@ void EEVEE_volumes_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
 
                if (grp == NULL) {
                        /* If no world or volume material is present just clear the buffer with this drawcall */
-                       grp = DRW_shgroup_empty_tri_batch_create(e_data.volumetric_clear_sh,
-                                                                    psl->volumetric_world_ps,
-                                                                    common_data->vol_tex_size[2]);
+                       grp = DRW_shgroup_empty_tri_batch_create(
+                               e_data.volumetric_clear_sh,
+                               psl->volumetric_world_ps,
+                               common_data->vol_tex_size[2]);
 
                        DRW_shgroup_uniform_block(grp, "common_block", sldata->common_ubo);
                }
index 70e679d..1f3874e 100644 (file)
@@ -155,41 +155,41 @@ void DRW_gpencil_get_stroke_geom(struct GpencilBatchCacheElem *be, bGPDstroke *g
                if (i == 0) {
                        if (gps->flag & GP_STROKE_CYCLIC && totpoints > 2) {
                                gpencil_set_stroke_point(
-                                       be->vbo, &points[totpoints - 1], be->vbo_len,
-                                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
+                                       be->vbo, &points[totpoints - 1], be->vbo_len,
+                                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
                                be->vbo_len++;
                        }
                        else {
                                gpencil_set_stroke_point(
-                                       be->vbo, &points[1], be->vbo_len,
-                                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
+                                       be->vbo, &points[1], be->vbo_len,
+                                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
                                be->vbo_len++;
                        }
                }
                /* set point */
                gpencil_set_stroke_point(
-                       be->vbo, pt, be->vbo_len,
-                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
+                       be->vbo, pt, be->vbo_len,
+                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
                be->vbo_len++;
        }
 
        if (gps->flag & GP_STROKE_CYCLIC && totpoints > 2) {
                /* draw line to first point to complete the cycle */
                gpencil_set_stroke_point(
-                       be->vbo, &points[0], be->vbo_len,
-                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
+                       be->vbo, &points[0], be->vbo_len,
+                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
                be->vbo_len++;
                /* now add adjacency point (not drawn) */
                gpencil_set_stroke_point(
-                       be->vbo, &points[1], be->vbo_len,
-                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
+                       be->vbo, &points[1], be->vbo_len,
+                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
                be->vbo_len++;
        }
        /* last adjacency point (not drawn) */
        else {
                gpencil_set_stroke_point(
-                       be->vbo, &points[totpoints - 2], be->vbo_len,
-                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
+                       be->vbo, &points[totpoints - 2], be->vbo_len,
+                       be->pos_id, be->color_id, be->thickness_id, be->uvdata_id, thickness, ink);
                be->vbo_len++;
        }
 }
@@ -223,8 +223,8 @@ void DRW_gpencil_get_fill_geom(struct GpencilBatchCacheElem *be, Object *ob, bGP
        for (int i = 0; i < gps->tot_triangles; i++, stroke_triangle++) {
                for (int j = 0; j < 3; j++) {
                        gpencil_set_fill_point(
-                               be->vbo, be->vbo_len, &gps->points[stroke_triangle->verts[j]], color, stroke_triangle->uv[j],
-                               be->pos_id, be->color_id, be->uvdata_id);
+                               be->vbo, be->vbo_len, &gps->points[stroke_triangle->verts[j]], color, stroke_triangle->uv[j],
+                               be->pos_id, be->color_id, be->uvdata_id);
                        be->vbo_len++;
                }
        }
@@ -277,15 +277,15 @@ GPUBatch *DRW_gpencil_get_buffer_stroke_geom(bGPdata *gpd, short thickness)
                        if (gpd->runtime.sbuffer_sflag & GP_STROKE_CYCLIC && totpoints > 2) {
                                ED_gpencil_tpoint_to_point(ar, origin, &points[totpoints - 1], &pt2);
                                gpencil_set_stroke_point(
-                                       vbo, &pt2, idx,
-                                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
+                                       vbo, &pt2, idx,
+                                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
                                idx++;
                        }
                        else {
                                ED_gpencil_tpoint_to_point(ar, origin, &points[1], &pt2);
                                gpencil_set_stroke_point(
-                                       vbo, &pt2, idx,
-                                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
+                                       vbo, &pt2, idx,
+                                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
                                idx++;
                        }
                }
@@ -302,22 +302,22 @@ GPUBatch *DRW_gpencil_get_buffer_stroke_geom(bGPdata *gpd, short thickness)
                /* draw line to first point to complete the cycle */
                ED_gpencil_tpoint_to_point(ar, origin, &points[0], &pt2);
                gpencil_set_stroke_point(
-                       vbo, &pt2, idx,
-                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
+                       vbo, &pt2, idx,
+                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
                idx++;
                /* now add adjacency point (not drawn) */
                ED_gpencil_tpoint_to_point(ar, origin, &points[1], &pt3);
                gpencil_set_stroke_point(
-                       vbo, &pt3, idx,
-                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
+                       vbo, &pt3, idx,
+                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
                idx++;
        }
        /* last adjacency point (not drawn) */
        else {
                ED_gpencil_tpoint_to_point(ar, origin, &points[totpoints - 2], &pt2);
                gpencil_set_stroke_point(
-                       vbo, &pt2, idx,
-                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
+                       vbo, &pt2, idx,
+                       pos_id, color_id, thickness_id, uvdata_id, thickness, gpd->runtime.scolor);
                idx++;
        }
 
index 9ed86cb..ce01044 100644 (file)
@@ -999,8 +999,8 @@ static void gpencil_draw_strokes(
                                    ((gps->flag & GP_STROKE_NOFILL) == 0))
                                {
                                        gpencil_add_fill_vertexdata(
-                                               cache, ob, gpl, derived_gpf, gps,
-                                               opacity, tintcolor, false, custonion);
+                                               cache, ob, gpl, derived_gpf, gps,
+                                               opacity, tintcolor, false, custonion);
                                }
                                /* stroke */
                                /* No fill strokes, must show stroke always */
@@ -1015,8 +1015,8 @@ static void gpencil_draw_strokes(
                                        }
 
                                        gpencil_add_stroke_vertexdata(
-                                               cache, ob, gpl, derived_gpf, gps,
-                                               opacity, tintcolor, false, custonion);
+                                               cache, ob, gpl, derived_gpf, gps,
+                                               opacity, tintcolor, false, custonion);
                                }
                        }
                }
@@ -1378,15 +1378,15 @@ void DRW_gpencil_populate_buffer_strokes(GPENCIL_e_data *e_data, void *vedata, T
                        if (gpd->runtime.sbuffer_size > 1) {
                                if ((gp_style) && (gp_style->mode == GP_STYLE_MODE_LINE)) {
                                        stl->g_data->shgrps_drawing_stroke = DRW_gpencil_shgroup_stroke_create(
-                                               e_data, vedata, psl->drawing_pass, e_data->gpencil_stroke_sh, NULL,
-                                               gpd, NULL, NULL, gp_style, -1,
-                                               false, 1.0f, (const int *)stl->storage->shade_render);
+                                               e_data, vedata, psl->drawing_pass, e_data->gpencil_stroke_sh, NULL,
+                                               gpd, NULL, NULL, gp_style, -1,
+                                               false, 1.0f, (const int *)stl->storage->shade_render);
                                }
                                else {
                                        stl->g_data->shgrps_drawing_stroke = DRW_gpencil_shgroup_point_create(
-                                               e_data, vedata, psl->drawing_pass, e_data->gpencil_point_sh, NULL,
-                                               gpd, NULL, gp_style, -1,
-                                               false, 1.0f, (const int *)stl->storage->shade_render);
+                                               e_data, vedata, psl->drawing_pass, e_data->gpencil_point_sh, NULL,
+                                               gpd, NULL, gp_style, -1,
+                                               false, 1.0f, (const int *)stl->storage->shade_render);
                                }
 
                                /* clean previous version of the batch */
@@ -1399,18 +1399,18 @@ void DRW_gpencil_populate_buffer_strokes(GPENCIL_e_data *e_data, void *vedata, T
                                /* use unit matrix because the buffer is in screen space and does not need conversion */
                                if (gpd->runtime.mode == GP_STYLE_MODE_LINE) {
                                        e_data->batch_buffer_stroke = DRW_gpencil_get_buffer_stroke_geom(
-                                               gpd, lthick);
+                                               gpd, lthick);
                                }
                                else {
                                        e_data->batch_buffer_stroke = DRW_gpencil_get_buffer_point_geom(
-                                               gpd, lthick);
+                                               gpd, lthick);
                                }
 
                                /* buffer strokes, must show stroke always */
                                DRW_shgroup_call_add(
-                                           stl->g_data->shgrps_drawing_stroke,
-                                           e_data->batch_buffer_stroke,
-                                           stl->storage->unit_matrix);
+                                       stl->g_data->shgrps_drawing_stroke,
+                                       e_data->batch_buffer_stroke,
+                                       stl->storage->unit_matrix);
 
                                if ((gpd->runtime.sbuffer_size >= 3) &&
                                    (gpd->runtime.sfill[3] > GPENCIL_ALPHA_OPACITY_THRESH) &&
@@ -1423,7 +1423,7 @@ void DRW_gpencil_populate_buffer_strokes(GPENCIL_e_data *e_data, void *vedata, T
                                                gpd->runtime.sfill[3] = 0.5f;
                                        }
                                        stl->g_data->shgrps_drawing_fill = DRW_shgroup_create(
-                                               e_data->gpencil_drawing_fill_sh, psl->drawing_pass);
+                                               e_data->gpencil_drawing_fill_sh, psl->drawing_pass);
 
                                        /* clean previous version of the batch */
                                        if (stl->storage->buffer_fill) {
@@ -1453,7 +1453,7 @@ void DRW_gpencil_populate_buffer_strokes(GPENCIL_e_data *e_data, void *vedata, T
            ((gpd->runtime.sbuffer_sflag & GP_STROKE_ERASER) == 0))
        {
                DRWShadingGroup *shgrp = DRW_shgroup_create(
-                       e_data->gpencil_edit_point_sh, psl->drawing_pass);
+                       e_data->gpencil_edit_point_sh, psl->drawing_pass);
                const float *viewport_size = DRW_viewport_size_get();
                DRW_shgroup_uniform_vec2(shgrp, "Viewport", viewport_size, 1);
 
index d3afe4e..5f2652b 100644 (file)
@@ -125,10 +125,10 @@ static void GPENCIL_create_framebuffers(void *vedata)
                                size[0], size[1], fb_format,
                                &draw_engine_gpencil_type);
                        GPU_framebuffer_ensure_config(
-                               &fbl->temp_fb_a, {
-                                       GPU_ATTACHMENT_TEXTURE(e_data.temp_depth_tx_a),
-                                       GPU_ATTACHMENT_TEXTURE(e_data.temp_color_tx_a)
-                               });
+                               &fbl->temp_fb_a, {
+                                   GPU_ATTACHMENT_TEXTURE(e_data.temp_depth_tx_a),
+                                   GPU_ATTACHMENT_TEXTURE(e_data.temp_color_tx_a),
+                               });
 
                        e_data.temp_depth_tx_b = DRW_texture_pool_query_2D(
                                size[0], size[1], GPU_DEPTH_COMPONENT24,
@@ -137,10 +137,10 @@ static void GPENCIL_create_framebuffers(void *vedata)
                                size[0], size[1], fb_format,
                                &draw_engine_gpencil_type);
                        GPU_framebuffer_ensure_config(
-                               &fbl->temp_fb_b, {
-                                       GPU_ATTACHMENT_TEXTURE(e_data.temp_depth_tx_b),
-                                       GPU_ATTACHMENT_TEXTURE(e_data.temp_color_tx_b)
-                               });
+                               &fbl->temp_fb_b, {
+                                   GPU_ATTACHMENT_TEXTURE(e_data.temp_depth_tx_b),
+                                   GPU_ATTACHMENT_TEXTURE(e_data.temp_color_tx_b),
+                               });
 
                        /* used for FX effects and Layer blending */
                        e_data.temp_depth_tx_fx = DRW_texture_pool_query_2D(
@@ -150,10 +150,10 @@ static void GPENCIL_create_framebuffers(void *vedata)
                                size[0], size[1], fb_format,
                                &draw_engine_gpencil_type);
                        GPU_framebuffer_ensure_config(
-                               &fbl->temp_fb_fx, {
-                                       GPU_ATTACHMENT_TEXTURE(e_data.temp_depth_tx_fx),
-                                       GPU_ATTACHMENT_TEXTURE(e_data.temp_color_tx_fx),
-                               });
+                               &fbl->temp_fb_fx, {
+                                   GPU_ATTACHMENT_TEXTURE(e_data.temp_depth_tx_fx),
+                                   GPU_ATTACHMENT_TEXTURE(e_data.temp_color_tx_fx),
+                               });
                }
 
                /* background framebuffer to speed up drawing process (always 16 bits) */
@@ -165,10 +165,10 @@ static void GPENCIL_create_framebuffers(void *vedata)
                                size[0], size[1], GPU_RGBA32F,
                                &draw_engine_gpencil_type);
                        GPU_framebuffer_ensure_config(
-                               &fbl->background_fb, {
-                                       GPU_ATTACHMENT_TEXTURE(e_data.background_depth_tx),
-                                       GPU_ATTACHMENT_TEXTURE(e_data.background_color_tx)
-                               });
+                               &fbl->background_fb, {
+                                   GPU_ATTACHMENT_TEXTURE(e_data.background_depth_tx),
+                                   GPU_ATTACHMENT_TEXTURE(e_data.background_color_tx),
+                               });
                }
        }
 }
@@ -345,8 +345,8 @@ void GPENCIL_cache_init(void *vedata)
                stl->storage->shgroup_id = 0;
                /* Stroke pass 3D */
                psl->stroke_pass_3d = DRW_pass_create(
-                       "GPencil Stroke Pass",
-                       DRW_STATE_WRITE_COLOR | DRW_STATE_WRITE_DEPTH | DRW_STATE_DEPTH_LESS_EQUAL | DRW_STATE_BLEND);
+                       "GPencil Stroke Pass",
+                       DRW_STATE_WRITE_COLOR | DRW_STATE_WRITE_DEPTH | DRW_STATE_DEPTH_LESS_EQUAL | DRW_STATE_BLEND);
                stl->storage->shgroup_id = 0;
 
                /* edit pass */
@@ -518,8 +518,8 @@ void GPENCIL_cache_init(void *vedata)
 
                /* blend layers pass */
                psl->blend_pass = DRW_pass_create(
-                       "GPencil Blend Layers Pass",
-                       DRW_STATE_WRITE_COLOR | DRW_STATE_BLEND | DRW_STATE_WRITE_DEPTH | DRW_STATE_DEPTH_LESS);
+                       "GPencil Blend Layers Pass",
+                       DRW_STATE_WRITE_COLOR | DRW_STATE_BLEND | DRW_STATE_WRITE_DEPTH | DRW_STATE_DEPTH_LESS);
                DRWShadingGroup *blend_shgrp = DRW_shgroup_create(e_data.gpencil_blend_fullscreen_sh, psl->blend_pass);
                DRW_shgroup_call_add(blend_shgrp, quad, NULL);
                DRW_shgroup_uniform_texture_ref(blend_shgrp, "strokeColor", &e_data.temp_color_tx_a);
@@ -601,8 +601,8 @@ void GPENCIL_cache_populate(void *vedata, Object *ob)
                        if (ob->dt != OB_BOUNDBOX) {
                                /* save gp objects for drawing later */
                                stl->g_data->gp_object_cache = gpencil_object_cache_add(
-                                       stl->g_data->gp_object_cache, ob,
-                                       &stl->g_data->gp_cache_size, &stl->g_data->gp_cache_used);
+                                       stl->g_data->gp_object_cache, ob,
+                                       &stl->g_data->gp_cache_size, &stl->g_data->gp_cache_used);
 
                                /* enable instance loop */
                                if (!stl->g_data->do_instances) {
@@ -759,8 +759,8 @@ static void gpencil_draw_pass_range(
        }
 
        DRW_draw_pass_subset(
-               GPENCIL_3D_DRAWMODE(ob, gpd) ? psl->stroke_pass_3d : psl->stroke_pass_2d,
-               init_shgrp, end_shgrp);
+               GPENCIL_3D_DRAWMODE(ob, gpd) ? psl->stroke_pass_3d : psl->stroke_pass_2d,
+               init_shgrp, end_shgrp);
 
        if ((!stl->storage->is_mat_preview) && (multi)) {
                MULTISAMPLE_GP_SYNC_DISABLE(stl->storage->multisamples, fbl, fb, txl);
@@ -781,7 +781,7 @@ static void drw_gpencil_select_render(GPENCIL_StorageList *stl, GPENCIL_PassList
        {
                /* sort by zdepth */
                qsort(stl->g_data->gp_object_cache, stl->g_data->gp_cache_used,
-                       sizeof(tGPencilObjectCache), gpencil_object_cache_compare_zdepth);
+                     sizeof(tGPencilObjectCache), gpencil_object_cache_compare_zdepth);
 
                for (int i = 0; i < stl->g_data->gp_cache_used; i++) {
                        cache_ob = &stl->g_data->gp_object_cache[i];
@@ -799,8 +799,8 @@ static void drw_gpencil_select_render(GPENCIL_StorageList *stl, GPENCIL_PassList
                                        }
                                        /* draw group */
                                        DRW_draw_pass_subset(
-                                               GPENCIL_3D_DRAWMODE(ob, gpd) ? psl->stroke_pass_3d : psl->stroke_pass_2d,
-                                               init_shgrp, end_shgrp);
+                                               GPENCIL_3D_DRAWMODE(ob, gpd) ? psl->stroke_pass_3d : psl->stroke_pass_2d,
+                                               init_shgrp, end_shgrp);
                                }
                                /* the cache must be dirty for next loop */
                                gpd->flag |= GP_DATA_CACHE_IS_DIRTY;
@@ -918,8 +918,8 @@ void GPENCIL_draw_scene(void *ved)
                                                        use_blend = true;
                                                        /* draw pending groups */
                                                        gpencil_draw_pass_range(
-                                                               fbl, stl, psl, txl, fbl->temp_fb_a,
-                                                               ob, gpd, init_shgrp, end_shgrp, is_last);
+                                                               fbl, stl, psl, txl, fbl->temp_fb_a,
+                                                               ob, gpd, init_shgrp, end_shgrp, is_last);
 
                                                        /* draw current group in separated texture */
                                                        init_shgrp = array_elm->init_shgrp;
index 2e3cb4b..d754fdf 100644 (file)
@@ -81,16 +81,16 @@ void GPENCIL_render_init(GPENCIL_Data *ved, RenderEngine *engine, struct Depsgra
        }
 
        vedata->render_depth_tx = DRW_texture_pool_query_2D(
-               size[0], size[1], GPU_DEPTH_COMPONENT24,
-               &draw_engine_gpencil_type);
+               size[0], size[1], GPU_DEPTH_COMPONENT24,
+               &draw_engine_gpencil_type);
        vedata->render_color_tx = DRW_texture_pool_query_2D(
-               size[0], size[1], GPU_RGBA32F,
-               &draw_engine_gpencil_type);
+               size[0], size[1], GPU_RGBA32F,
+               &draw_engine_gpencil_type);
        GPU_framebuffer_ensure_config(
-               &fbl->main, {
-                       GPU_ATTACHMENT_TEXTURE(vedata->render_depth_tx),
-                       GPU_ATTACHMENT_TEXTURE(vedata->render_color_tx)
-               });
+               &fbl->main, {
+                   GPU_ATTACHMENT_TEXTURE(vedata->render_depth_tx),
+                   GPU_ATTACHMENT_TEXTURE(vedata->render_color_tx)
+               });
 
        /* Alloc transient data. */
        if (!stl->g_data) {
index e4819f4..b1bc796 100644 (file)
@@ -457,8 +457,8 @@ static void DRW_gpencil_fx_shadow(
        GPUBatch *fxquad = DRW_cache_fullscreen_quad_get();
        /* prepare pass */
        fx_shgrp = DRW_shgroup_create(
-               e_data->gpencil_fx_shadow_prepare_sh,
-               psl->fx_shader_pass_blend);
+               e_data->gpencil_fx_shadow_prepare_sh,
+               psl->fx_shader_pass_blend);
        DRW_shgroup_call_add(fx_shgrp, fxquad, NULL);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeColor", &e_data->temp_color_tx_a);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeDepth", &e_data->temp_depth_tx_a);
@@ -494,8 +494,8 @@ static void DRW_gpencil_fx_shadow(
 
        /* blur pass */
        fx_shgrp = DRW_shgroup_create(
-               e_data->gpencil_fx_blur_sh,
-               psl->fx_shader_pass_blend);
+               e_data->gpencil_fx_blur_sh,
+               psl->fx_shader_pass_blend);
        DRW_shgroup_call_add(fx_shgrp, fxquad, NULL);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeColor", &e_data->temp_color_tx_fx);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeDepth", &e_data->temp_depth_tx_fx);
@@ -510,8 +510,8 @@ static void DRW_gpencil_fx_shadow(
 
        /* resolve pass */
        fx_shgrp = DRW_shgroup_create(
-               e_data->gpencil_fx_shadow_resolve_sh,
-               psl->fx_shader_pass_blend);
+               e_data->gpencil_fx_shadow_resolve_sh,
+               psl->fx_shader_pass_blend);
        DRW_shgroup_call_add(fx_shgrp, fxquad, NULL);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeColor", &e_data->temp_color_tx_a);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeDepth", &e_data->temp_depth_tx_a);
@@ -540,8 +540,8 @@ static void DRW_gpencil_fx_glow(
        GPUBatch *fxquad = DRW_cache_fullscreen_quad_get();
        /* prepare pass */
        fx_shgrp = DRW_shgroup_create(
-               e_data->gpencil_fx_glow_prepare_sh,
-               psl->fx_shader_pass_blend);
+               e_data->gpencil_fx_glow_prepare_sh,
+               psl->fx_shader_pass_blend);
        DRW_shgroup_call_add(fx_shgrp, fxquad, NULL);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeColor", &e_data->temp_color_tx_a);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeDepth", &e_data->temp_depth_tx_a);
@@ -555,8 +555,8 @@ static void DRW_gpencil_fx_glow(
 
        /* blur pass */
        fx_shgrp = DRW_shgroup_create(
-               e_data->gpencil_fx_blur_sh,
-               psl->fx_shader_pass_blend);
+               e_data->gpencil_fx_blur_sh,
+               psl->fx_shader_pass_blend);
        DRW_shgroup_call_add(fx_shgrp, fxquad, NULL);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeColor", &e_data->temp_color_tx_fx);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeDepth", &e_data->temp_depth_tx_fx);
@@ -571,8 +571,8 @@ static void DRW_gpencil_fx_glow(
 
        /* resolve pass */
        fx_shgrp = DRW_shgroup_create(
-               e_data->gpencil_fx_glow_resolve_sh,
-               psl->fx_shader_pass_blend);
+               e_data->gpencil_fx_glow_resolve_sh,
+               psl->fx_shader_pass_blend);
        DRW_shgroup_call_add(fx_shgrp, fxquad, NULL);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeColor", &e_data->temp_color_tx_a);
        DRW_shgroup_uniform_texture_ref(fx_shgrp, "strokeDepth", &e_data->temp_depth_tx_a);
@@ -659,52 +659,52 @@ void GPENCIL_create_fx_shaders(GPENCIL_e_data *e_data)
        /* fx shaders (all in screen space) */
        if (!e_data->gpencil_fx_blur_sh) {
                e_data->gpencil_fx_blur_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_blur_frag_glsl, NULL);
+                       datatoc_gpencil_fx_blur_frag_glsl, NULL);
        }
        if (!e_data->gpencil_fx_colorize_sh) {
                e_data->gpencil_fx_colorize_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_colorize_frag_glsl, NULL);
+                       datatoc_gpencil_fx_colorize_frag_glsl, NULL);
        }
        if (!e_data->gpencil_fx_flip_sh) {
                e_data->gpencil_fx_flip_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_flip_frag_glsl, NULL);
+                       datatoc_gpencil_fx_flip_frag_glsl, NULL);
        }
        if (!e_data->gpencil_fx_light_sh) {
                e_data->gpencil_fx_light_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_light_frag_glsl, NULL);
+                       datatoc_gpencil_fx_light_frag_glsl, NULL);
        }
        if (!e_data->gpencil_fx_pixel_sh) {
                e_data->gpencil_fx_pixel_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_pixel_frag_glsl, NULL);
+                       datatoc_gpencil_fx_pixel_frag_glsl, NULL);
        }
        if (!e_data->gpencil_fx_rim_prepare_sh) {
                e_data->gpencil_fx_rim_prepare_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_rim_prepare_frag_glsl, NULL);
+                       datatoc_gpencil_fx_rim_prepare_frag_glsl, NULL);
 
                e_data->gpencil_fx_rim_resolve_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_rim_resolve_frag_glsl, NULL);
+                       datatoc_gpencil_fx_rim_resolve_frag_glsl, NULL);
        }
        if (!e_data->gpencil_fx_shadow_prepare_sh) {
                e_data->gpencil_fx_shadow_prepare_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_shadow_prepare_frag_glsl, NULL);
+                       datatoc_gpencil_fx_shadow_prepare_frag_glsl, NULL);
 
                e_data->gpencil_fx_shadow_resolve_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_shadow_resolve_frag_glsl, NULL);
+                       datatoc_gpencil_fx_shadow_resolve_frag_glsl, NULL);
        }
        if (!e_data->gpencil_fx_glow_prepare_sh) {
                e_data->gpencil_fx_glow_prepare_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_glow_prepare_frag_glsl, NULL);
+                       datatoc_gpencil_fx_glow_prepare_frag_glsl, NULL);
 
                e_data->gpencil_fx_glow_resolve_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_glow_resolve_frag_glsl, NULL);
+                       datatoc_gpencil_fx_glow_resolve_frag_glsl, NULL);
        }
        if (!e_data->gpencil_fx_swirl_sh) {
                e_data->gpencil_fx_swirl_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_swirl_frag_glsl, NULL);
+                       datatoc_gpencil_fx_swirl_frag_glsl, NULL);
        }
        if (!e_data->gpencil_fx_wave_sh) {
                e_data->gpencil_fx_wave_sh = DRW_shader_create_fullscreen(
-                       datatoc_gpencil_fx_wave_frag_glsl, NULL);
+                       datatoc_gpencil_fx_wave_frag_glsl, NULL);
        }
 }
 
@@ -880,8 +880,9 @@ static void draw_gpencil_midpass_blur(
 
        GPU_framebuffer_bind(fbl->temp_fb_b);
        GPU_framebuffer_clear_color_depth(fbl->temp_fb_b, clearcol, 1.0f);
-       DRW_draw_pass_subset(psl->fx_shader_pass_blend,
-               runtime->fx_sh_b, runtime->fx_sh_b);
+       DRW_draw_pass_subset(
+               psl->fx_shader_pass_blend,
+               runtime->fx_sh_b, runtime->fx_sh_b);
 
        /* copy pass from b for ping-pong frame buffers */
        GPU_framebuffer_bind(fbl->temp_fb_fx);
@@ -981,8 +982,8 @@ static void draw_gpencil_shadow_passes(
        GPU_framebuffer_bind(fbl->temp_fb_fx);
        GPU_framebuffer_clear_color_depth(fbl->temp_fb_fx, clearcol, 1.0f);
        DRW_draw_pass_subset(
-               psl->fx_shader_pass_blend,
-               fxd->runtime.fx_sh, fxd->runtime.fx_sh);
+               psl->fx_shader_pass_blend,
+               fxd->runtime.fx_sh, fxd->runtime.fx_sh);
 
        /* blur shadow */
        draw_gpencil_do_blur(
@@ -995,8 +996,8 @@ static void draw_gpencil_shadow_passes(
        GPU_framebuffer_bind(fbl->temp_fb_b);
        GPU_framebuffer_clear_color_depth(fbl->temp_fb_b, clearcol, 1.0f);
        DRW_draw_pass_subset(
-               psl->fx_shader_pass_blend,
-               fxd->runtime.fx_sh_c, fxd->runtime.fx_sh_c);
+               psl->fx_shader_pass_blend,
+               fxd->runtime.fx_sh_c, fxd->runtime.fx_sh_c);
 
        /* copy pass from b to a for ping-pong frame buffers */
        e_data->input_depth_tx = e_data->temp_depth_tx_b;
@@ -1026,8 +1027,8 @@ static void draw_gpencil_glow_passes(
        GPU_framebuffer_bind(fbl->temp_fb_fx);
        GPU_framebuffer_clear_color_depth(fbl->temp_fb_fx, clearcol, 1.0f);
        DRW_draw_pass_subset(
-               psl->fx_shader_pass_blend,
-               fxd->runtime.fx_sh, fxd->runtime.fx_sh);
+               psl->fx_shader_pass_blend,
+               fxd->runtime.fx_sh, fxd->runtime.fx_sh);
 
        /* blur glow */
        draw_gpencil_do_blur(
@@ -1044,8 +1045,8 @@ static void draw_gpencil_glow_passes(
        fxd->blur[1] = (fxd->flag & FX_GLOW_USE_ALPHA) ? 1 : 0;
 
        DRW_draw_pass_subset(
-               psl->fx_shader_pass_blend,
-               fxd->runtime.fx_sh_c, fxd->runtime.fx_sh_c);
+               psl->fx_shader_pass_blend,
+               fxd->runtime.fx_sh_c, fxd->runtime.fx_sh_c);
 
        /* copy pass from b to a for ping-pong frame buffers */
        e_data->input_depth_tx = e_data->temp_depth_tx_b;
index f73aacf..988ada8 100644 (file)
@@ -2914,9 +2914,9 @@ static void OBJECT_gpencil_color_names(Object *ob, struct DRWTextStore *dt, ucha
                                        if (pt->flag & GP_SPOINT_SELECT) {
                                                mul_v3_m4v3(fpt, ob->obmat, &pt->x);
                                                DRW_text_cache_add(
-                                                       dt, fpt,
-                                                       ma->id.name + 2, strlen(ma->id.name + 2),
-                                                       10, 0, DRW_TEXT_CACHE_GLOBALSPACE | DRW_TEXT_CACHE_STRING_PTR, color);
+                                                       dt, fpt,
+                                                       ma->id.name + 2, strlen(ma->id.name + 2),
+                                                       10, 0, DRW_TEXT_CACHE_GLOBALSPACE | DRW_TEXT_CACHE_STRING_PTR, color);
                                                break;
                                        }
                                }
index acffbd5..558c5d5 100644 (file)
@@ -1258,8 +1258,9 @@ static void rearrange_nla_control_channels(bAnimContext *ac, AnimData *adt, eRea
        /* we cannot rearrange between strips, but within each strip, we can rearrange those curves */
        for (nlt = adt->nla_tracks.first; nlt; nlt = nlt->next) {
                for (strip = nlt->strips.first; strip; strip = strip->next) {
-                       rearrange_animchannel_islands(&strip->fcurves, rearrange_func, mode, ANIMTYPE_NLACURVE,
-                                                         &anim_data_visible);
+                       rearrange_animchannel_islands(
+                               &strip->fcurves, rearrange_func, mode, ANIMTYPE_NLACURVE,
+                               &anim_data_visible);
                }
        }
 
index af2037e..17d74e8 100644 (file)
@@ -1418,10 +1418,11 @@ static size_t animfilter_nla(bAnimContext *UNUSED(ac), ListBase *anim_data, bDop
                                 * - as AnimData may not have an action, we pass a dummy pointer just to get the list elem created, then
                                 *   overwrite this with the real value - REVIEW THIS...
                                 */
-                               ANIMCHANNEL_NEW_CHANNEL_FULL((void *)(&adt->action), ANIMTYPE_NLAACTION, owner_id, NULL,
-                                       {
-                                               ale->data = adt->action ? adt->action : NULL;
-                                       });
+                               ANIMCHANNEL_NEW_CHANNEL_FULL(
+                                       (void *)(&adt->action), ANIMTYPE_NLAACTION, owner_id, NULL,
+                                       {
+                                           ale->data = adt->action ? adt->action : NULL;
+                                       });
                        }
                }
 
@@ -1551,26 +1552,27 @@ static size_t animfilter_block_data(bAnimContext *ac, ListBase *anim_data, bDope
                 * in a few places in the rest of the code still - notably for the few cases where special mode-based
                 * different types of data expanders are required.
                 */
-               ANIMDATA_FILTER_CASES(iat,
-                       { /* AnimData */
-                               /* specifically filter animdata block */
-                               if (ANIMCHANNEL_SELOK(SEL_ANIMDATA(adt)) ) {
-                                       ANIMCHANNEL_NEW_CHANNEL(adt, ANIMTYPE_ANIMDATA, id, NULL);
-                               }
-                       },
-                       { /* NLA */
-                               items += animfilter_nla(ac, anim_data, ads, adt, filter_mode, id);
-                       },
-                       { /* Drivers */
-                               items += animfilter_fcurves(anim_data, ads, adt->drivers.first, ANIMTYPE_FCURVE,
-                                                           filter_mode, NULL, id, id);
-                       },
-                       { /* NLA Control Keyframes */
-                               items += animfilter_nla_controls(anim_data, ads, adt, filter_mode, id);
-                       },
-                       { /* Keyframes */
-                               items += animfilter_action(ac, anim_data, ads, adt->action, filter_mode, id);
-                       }
+               ANIMDATA_FILTER_CASES(
+                       iat,
+                       { /* AnimData */
+                           /* specifically filter animdata block */
+                           if (ANIMCHANNEL_SELOK(SEL_ANIMDATA(adt)) ) {
+                               ANIMCHANNEL_NEW_CHANNEL(adt, ANIMTYPE_ANIMDATA, id, NULL);
+                           }
+                       },
+                       { /* NLA */
+                           items += animfilter_nla(ac, anim_data, ads, adt, filter_mode, id);
+                       },
+                       { /* Drivers */
+                           items += animfilter_fcurves(anim_data, ads, adt->drivers.first, ANIMTYPE_FCURVE,
+                                                       filter_mode, NULL, id, id);
+                       },
+                       { /* NLA Control Keyframes */
+                           items += animfilter_nla_controls(anim_data, ads, adt, filter_mode, id);
+                       },
+                       { /* Keyframes */
+                           items += animfilter_action(ac, anim_data, ads, adt->action, filter_mode, id);
+                       }
                );
        }
 
@@ -2531,20 +2533,21 @@ static size_t animdata_filter_ds_obanim(bAnimContext *ac, ListBase *anim_data, b
 
        /* determine the type of expander channels to use */
        /* this is the best way to do this for now... */
-       ANIMDATA_FILTER_CASES(ob,
-               { /* AnimData - no channel, but consider data */ },
-               { /* NLA - no channel, but consider data */ },
-               { /* Drivers */
-                       type = ANIMTYPE_FILLDRIVERS;
-                       cdata = adt;
-                       expanded = EXPANDED_DRVD(adt);
-               },
-               { /* NLA Strip Controls - no dedicated channel for now (XXX) */ },
-               { /* Keyframes */
-                       type = ANIMTYPE_FILLACTD;
-                       cdata = adt->action;
-                       expanded = EXPANDED_ACTC(adt->action);
-               });
+       ANIMDATA_FILTER_CASES(
+               ob,
+               { /* AnimData - no channel, but consider data */ },
+               { /* NLA - no channel, but consider data */ },
+               { /* Drivers */
+                   type = ANIMTYPE_FILLDRIVERS;
+                   cdata = adt;
+                   expanded = EXPANDED_DRVD(adt);
+               },
+               { /* NLA Strip Controls - no dedicated channel for now (XXX) */ },
+               { /* Keyframes */
+                   type = ANIMTYPE_FILLACTD;
+                   cdata = adt->action;
+                   expanded = EXPANDED_ACTC(adt->action);
+               });
 
        /* add object-level animation channels */
        BEGIN_ANIMFILTER_SUBCHANNELS(expanded)
@@ -2701,20 +2704,21 @@ static size_t animdata_filter_ds_scene(bAnimContext *ac, ListBase *anim_data, bD
 
        /* determine the type of expander channels to use */
        // this is the best way to do this for now...
-       ANIMDATA_FILTER_CASES(sce,
-               { /* AnimData - no channel, but consider data */},
-               { /* NLA - no channel, but consider data */},
-               { /* Drivers */
-                       type = ANIMTYPE_FILLDRIVERS;
-                       cdata = adt;
-                       expanded = EXPANDED_DRVD(adt);
-               },
-               { /* NLA Strip Controls - no dedicated channel for now (XXX) */ },
-               { /* Keyframes */
-                       type = ANIMTYPE_FILLACTD;
-                       cdata = adt->action;
-                       expanded = EXPANDED_ACTC(adt->action);
-               });
+       ANIMDATA_FILTER_CASES(
+               sce,
+               { /* AnimData - no channel, but consider data */},
+               { /* NLA - no channel, but consider data */},
+               { /* Drivers */
+                   type = ANIMTYPE_FILLDRIVERS;
+                   cdata = adt;
+                   expanded = EXPANDED_DRVD(adt);
+               },
+               { /* NLA Strip Controls - no dedicated channel for now (XXX) */ },
+               { /* Keyframes */
+                   type = ANIMTYPE_FILLACTD;
+                   cdata = adt->action;
+                   expanded = EXPANDED_ACTC(adt->action);
+               });
 
        /* add scene-level animation channels */
        BEGIN_ANIMFILTER_SUBCHANNELS(expanded)
index 769398e..1d3fd1e 100644 (file)
@@ -1645,19 +1645,19 @@ void POSE_OT_propagate(wmOperatorType *ot)
 {
        static const EnumPropertyItem terminate_items[] = {
                {POSE_PROPAGATE_SMART_HOLDS, "WHILE_HELD", 0, "While Held",
-            "Propagate pose to all keyframes after current frame that don't change (Default behavior)"},
+                "Propagate pose to all keyframes after current frame that don't change (Default behavior)"},
                {POSE_PROPAGATE_NEXT_KEY, "NEXT_KEY", 0, "To Next Keyframe",
-            "Propagate pose to first keyframe following the current frame only"},
+                "Propagate pose to first keyframe following the current frame only"},
                {POSE_PROPAGATE_LAST_KEY, "LAST_KEY", 0, "To Last Keyframe",
-            "Propagate pose to the last keyframe only (i.e. making action cyclic)"},
+                "Propagate pose to the last keyframe only (i.e. making action cyclic)"},
                {POSE_PROPAGATE_BEFORE_FRAME, "BEFORE_FRAME", 0, "Before Frame",
-            "Propagate pose to all keyframes between current frame and 'Frame' property"},
+                "Propagate pose to all keyframes between current frame and 'Frame' property"},
                {POSE_PROPAGATE_BEFORE_END, "BEFORE_END", 0, "Before Last Keyframe",
-            "Propagate pose to all keyframes from current frame until no more are found"},
+                "Propagate pose to all keyframes from current frame until no more are found"},
                {POSE_PROPAGATE_SELECTED_KEYS, "SELECTED_KEYS", 0, "On Selected Keyframes",
-            "Propagate pose to all selected keyframes"},
+                "Propagate pose to all selected keyframes"},
                {POSE_PROPAGATE_SELECTED_MARKERS, "SELECTED_MARKERS", 0, "On Selected Markers",
-            "Propagate pose to all keyframes occurring on frames with Scene Markers after the current frame"},
+                "Propagate pose to all keyframes occurring on frames with Scene Markers after the current frame"},
                {0, NULL, 0, NULL, NULL},
        };
 
index f30b3a4..3d70a7f 100644 (file)
@@ -717,8 +717,8 @@ static void gp_draw_strokes_edit(
 /* ----- General Drawing ------ */
 /* draw onion-skinning for a layer */
 static void gp_draw_onionskins(
-       bGPdata *gpd, bGPDlayer *gpl, bGPDframe *gpf, int offsx, int offsy, int winx, int winy,
-       int UNUSED(cfra), int dflag)
+        bGPdata *gpd, bGPDlayer *gpl, bGPDframe *gpf, int offsx, int offsy, int winx, int winy,
+        int UNUSED(cfra), int dflag)
 {
        const float alpha = 1.0f;
        float color[4];
@@ -738,8 +738,8 @@ static void gp_draw_onionskins(
                                fac = 1.0f - ((float)(gpf->framenum - gf->framenum) / (float)(gpl->gstep + 1));
                                color[3] = alpha * fac * 0.66f;
                                gp_draw_strokes(
-                                       gpd, gpl, gf, offsx, offsy, winx, winy, dflag,
-                                       gpl->thickness, color);
+                                       gpd, gpl, gf, offsx, offsy, winx, winy, dflag,
+                                       gpl->thickness, color);
                        }
                        else
                                break;
@@ -750,8 +750,8 @@ static void gp_draw_onionskins(
                if (gpf->prev) {
                        color[3] = (alpha / 7);
                        gp_draw_strokes(
-                               gpd, gpl, gpf->prev, offsx, offsy, winx, winy, dflag,
-                               gpl->thickness, color);
+                               gpd, gpl, gpf->prev, offsx, offsy, winx, winy, dflag,
+                               gpl->thickness, color);
                }
        }
        else {
@@ -774,8 +774,8 @@ static void gp_draw_onionskins(
                                fac = 1.0f - ((float)(gf->framenum - gpf->framenum) / (float)(gpl->gstep_next + 1));
                                color[3] = alpha * fac * 0.66f;
                                gp_draw_strokes(
-                                       gpd, gpl, gf, offsx, offsy, winx, winy, dflag,
-                                       gpl->thickness, color);
+                                       gpd, gpl, gf, offsx, offsy, winx, winy, dflag,
+                                       gpl->thickness, color);
                        }
                        else
                                break;
@@ -786,8 +786,8 @@ static void gp_draw_onionskins(
                if (gpf->next) {
                        color[3] = (alpha / 4);
                        gp_draw_strokes(
-                               gpd, gpl, gpf->next, offsx, offsy, winx, winy, dflag,
-                               gpl->thickness, color);
+                               gpd, gpl, gpf->next, offsx, offsy, winx, winy, dflag,
+                               gpl->thickness, color);
                }
        }
        else {
index f7d813a..349deb6 100644 (file)
@@ -227,8 +227,7 @@ static bool gpencil_draw_poll(bContext *C)
                if ((obact) && (obact->type == OB_GPENCIL) &&
                    (obact->mode == OB_MODE_PAINT_GPENCIL))
                {
-                       CTX_wm_operator_poll_msg_set(C,
-                               "Annotation cannot be used in grease pencil draw mode");
+                       CTX_wm_operator_poll_msg_set(C, "Annotation cannot be used in grease pencil draw mode");
                        return false;
                }
        }
@@ -2133,8 +2132,7 @@ static void annotation_add_missing_events(bContext *C, wmOperator *op, const wmE
                interp_v2_v2v2(pt, a, b, 0.5f);
                sub_v2_v2v2(pt, b, pt);
                /* create fake event */
-               annotation_draw_apply_event(op, event, CTX_data_depsgraph(C),
-                       pt[0], pt[1]);
+               annotation_draw_apply_event(op, event, CTX_data_depsgraph(C), pt[0], pt[1]);
        }
        else if (dist >= factor) {
                int slices = 2 + (int)((dist - 1.0) / factor);
@@ -2143,8 +2141,9 @@ static void annotation_add_missing_events(bContext *C, wmOperator *op, const wmE
                        interp_v2_v2v2(pt, a, b, n * i);
                        sub_v2_v2v2(pt, b, pt);
                        /* create fake event */
-                       annotation_draw_apply_event(op, event, CTX_data_depsgraph(C),
-                               pt[0], pt[1]);
+                       annotation_draw_apply_event(
+                               op, event, CTX_data_depsgraph(C),
+                               pt[0], pt[1]);
                }
        }
 }
@@ -2281,8 +2280,8 @@ static int gpencil_draw_modal(bContext *C, wmOperator *op, const wmEvent *event)
 
                                if (G.debug & G_DEBUG) {
                                        printf("found alternative region %p (old was %p) - at %d %d (sa: %d %d -> %d %d)\n",
-                                               current_region, p->ar, event->x, event->y,
-                                               p->sa->totrct.xmin, p->sa->totrct.ymin, p->sa->totrct.xmax, p->sa->totrct.ymax);
+                                              current_region, p->ar, event->x, event->y,
+                                              p->sa->totrct.xmin, p->sa->totrct.ymin, p->sa->totrct.xmax, p->sa->totrct.ymax);
                                }
 
                                if (current_region) {
index dafc950..1ae3176 100644 (file)
@@ -570,8 +570,9 @@ static int gp_set_filling_texture(Image *image, short flag)
                return (int)GL_INVALID_OPERATION;
        }
 
-       GPU_create_gl_tex(bind, ibuf->rect, ibuf->rect_float, ibuf->x, ibuf->y, GL_TEXTURE_2D,
-               false, false, image);
+       GPU_create_gl_tex(
+               bind, ibuf->rect, ibuf->rect_float, ibuf->x, ibuf->y, GL_TEXTURE_2D,
+               false, false, image);
 
        glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
        glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
@@ -1099,9 +1100,10 @@ static void gp_draw_strokes(tGPDdraw *tgpw)
                                /* 3D Lines - OpenGL primitives-based */
                                if (gps->totpoints == 1) {
                                        if (tgpw->disable_fill != 1) {
-                                               gp_draw_stroke_point(gps->points, sthickness, tgpw->dflag, gps->flag,
-                                                       tgpw->offsx, tgpw->offsy, tgpw->winx, tgpw->winy,
-                                                       tgpw->diff_mat, ink);
+                                               gp_draw_stroke_point(
+                                                       gps->points, sthickness, tgpw->dflag, gps->flag,
+                                                       tgpw->offsx, tgpw->offsy, tgpw->winx, tgpw->winy,
+                                                       tgpw->diff_mat, ink);
                                        }
                                }
                                else {
@@ -1740,8 +1742,7 @@ void ED_gpencil_draw_view3d_object(wmWindowManager *wm, Scene *scene, Depsgraph
        ToolSettings *ts = scene->toolsettings;
        Brush *brush = BKE_paint_brush(&ts->gp_paint->paint);
        if (brush != NULL) {
-               gp_draw_data(rv3d, brush, 1.0f, ob, gpd,
-                       offsx, offsy, winx, winy, CFRA, dflag);
+               gp_draw_data(rv3d, brush, 1.0f, ob, gpd, offsx, offsy, winx, winy, CFRA, dflag);
        }
 }
 
index 97f5db9..a482eb8 100644 (file)
@@ -576,14 +576,14 @@ static int gpencil_generate_weights_exec(bContext *C, wmOperator *op)
                GpencilModifierData *md = BKE_gpencil_modifiers_findByType(ob_eval, eGpencilModifierType_Armature);
                if (md == NULL) {
                        BKE_report(op->reports, RPT_ERROR,
-                               "The grease pencil object need an Armature modifier");
+                                  "The grease pencil object need an Armature modifier");
                        return OPERATOR_CANCELLED;
                }
 
                ArmatureGpencilModifierData *mmd = (ArmatureGpencilModifierData *)md;
                if (mmd->object == NULL) {
                        BKE_report(op->reports, RPT_ERROR,
-                               "Armature modifier is not valid or wrong defined");
+                                  "Armature modifier is not valid or wrong defined");
                        return OPERATOR_CANCELLED;
                }
 
index ee1838a..0403a42 100644 (file)
@@ -1269,7 +1269,7 @@ static bool gpsculpt_brush_init(bContext *C, wmOperator *op)
                        if (found == false) {
                                /* STOP HERE! Nothing to paste! */
                                BKE_report(op->reports, RPT_ERROR,
-                                          "Copy some strokes to the clipboard before using the Clone brush to paste copies of them");
+                                          "Copy some strokes to the clipboard before using the Clone brush to paste copies of them");
 
                                MEM_freeN(gso);
                                op->customdata = NULL;
@@ -1853,8 +1853,7 @@ static int gpsculpt_brush_invoke(bContext *C, wmOperator *op, const wmEvent *eve
 
        /* the operator cannot work while play animation */
        if (is_playing) {
-               BKE_report(op->reports, RPT_ERROR,
-                       "Cannot sculpt while play animation");
+               BKE_report(op->reports, RPT_ERROR, "Cannot sculpt while play animation");
 
                return OPERATOR_CANCELLED;
        }
index 088282c..1388beb 100644 (file)
@@ -881,8 +881,9 @@ static void gpencil_add_move_points(bGPDframe *gpf, bGPDstroke *gps)
 
                /* if last point, add new point at the end */
                if (do_last) {
-                       copy_point(gps, temp_points, temp_dverts,
-                               oldtotpoints - 1, gps->totpoints - 1);
+                       copy_point(
+                               gps, temp_points, temp_dverts,
+                               oldtotpoints - 1, gps->totpoints - 1);
 
                        /* deselect old */
                        pt = &gps->points[gps->totpoints - 2];
@@ -2600,8 +2601,9 @@ void GPENCIL_OT_snap_to_cursor(wmOperatorType *ot)
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
 
        /* props */
-       ot->prop = RNA_def_boolean(ot->srna, "use_offset", true, "With Offset",
-               "Offset the entire stroke instead of selected points only");
+       ot->prop = RNA_def_boolean(
+               ot->srna, "use_offset", true, "With Offset",
+               "Offset the entire stroke instead of selected points only");
 }
 
 /* ------------------------------- */
@@ -3333,8 +3335,9 @@ static int gp_strokes_reproject_exec(bContext *C, wmOperator *op)
 
                                /* Project stroke in one axis */
                                if (ELEM(mode, GP_REPROJECT_FRONT, GP_REPROJECT_SIDE, GP_REPROJECT_TOP)) {
-                                       ED_gp_get_drawing_reference(scene, ob, gpl,
-                                               ts->gpencil_v3d_align, origin);
+                                       ED_gp_get_drawing_reference(
+                                               scene, ob, gpl,
+                                               ts->gpencil_v3d_align, origin);
 
                                        int axis = 0;
                                        switch (mode) {
@@ -3360,8 +3363,9 @@ static int gp_strokes_reproject_exec(bContext *C, wmOperator *op)
                                                }
                                        }
 
-                                       ED_gp_project_point_to_plane(ob, rv3d, origin,
-                                               axis, &pt2);
+                                       ED_gp_project_point_to_plane(
+                                               ob, rv3d, origin,
+                                               axis, &pt2);
 
                                        copy_v3_v3(&pt->x, &pt2.x);
 
@@ -3666,8 +3670,9 @@ void GPENCIL_OT_stroke_subdivide(wmOperatorType *ot)
        RNA_def_float(ot->srna, "factor", 0.0f, 0.0f, 2.0f, "Smooth", "", 0.0f, 2.0f);
        prop = RNA_def_int(ot->srna, "repeat", 1, 1, 10, "Repeat", "", 1, 5);
        RNA_def_property_flag(prop, PROP_SKIP_SAVE);
-       RNA_def_boolean(ot->srna, "only_selected", true, "Selected Points",
-               "Smooth only selected points in the stroke");
+       RNA_def_boolean(
+               ot->srna, "only_selected", true, "Selected Points",
+               "Smooth only selected points in the stroke");
        RNA_def_boolean(ot->srna, "smooth_position", true, "Position", "");
        RNA_def_boolean(ot->srna, "smooth_thickness", true, "Thickness", "");
        RNA_def_boolean(ot->srna, "smooth_strength", false, "Strength", "");
@@ -4224,8 +4229,9 @@ void GPENCIL_OT_stroke_smooth(wmOperatorType *ot)
        RNA_def_property_flag(prop, PROP_SKIP_SAVE);
 
        RNA_def_float(ot->srna, "factor", 0.5f, 0.0f, 2.0f, "Factor", "", 0.0f, 2.0f);
-       RNA_def_boolean(ot->srna, "only_selected", true, "Selected Points",
-               "Smooth only selected points in the stroke");
+       RNA_def_boolean(
+               ot->srna, "only_selected", true, "Selected Points",
+               "Smooth only selected points in the stroke");
        RNA_def_boolean(ot->srna, "smooth_position", true, "Position", "");
        RNA_def_boolean(ot->srna, "smooth_thickness", true, "Thickness", "");
        RNA_def_boolean(ot->srna, "smooth_strength", false, "Strength", "");
@@ -4306,7 +4312,7 @@ static void gpencil_cutter_dissolve(bGPDlayer *hit_layer, bGPDstroke *hit_stroke
                        }
                }
                gp_stroke_delete_tagged_points(
-                       hit_layer->actframe, hit_stroke, gpsn, GP_SPOINT_TAG, false, 1);
+                       hit_layer->actframe, hit_stroke, gpsn, GP_SPOINT_TAG, false, 1);
        }
 }
 
@@ -4365,7 +4371,7 @@ static int gpencil_cutter_lasso_select(
                                float r_hita[3], r_hitb[3];
                                if (gps->totpoints > 1) {
                                        ED_gpencil_select_stroke_segment(
-                                               gpl, gps, pt, true, true, scale, r_hita, r_hitb);
+                                               gpl, gps, pt, true, true, scale, r_hita, r_hitb);
                                }
                                /* avoid infinite loops */
                                if (gps->totpoints > oldtot) {
index 680568a..7668b7c 100644 (file)
@@ -349,8 +349,8 @@ static void gp_render_offscreen(tGPDfill *tgpf)
        glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
 
        ED_view3d_update_viewmat(
-               tgpf->depsgraph, tgpf->scene, tgpf->v3d, tgpf->ar,
-               NULL, winmat, NULL);
+               tgpf->depsgraph, tgpf->scene, tgpf->v3d, tgpf->ar,
+               NULL, winmat, NULL);
        /* set for opengl */
        GPU_matrix_projection_set(tgpf->rv3d->winmat);
        GPU_matrix_set(tgpf->rv3d->viewmat);
index b1924b3..5d6abb5 100644 (file)
@@ -187,7 +187,7 @@ static int gpencil_convert_old_files_exec(bContext *C, wmOperator *UNUSED(op))
                                 * to put them into from here...
                                 */
                                printf("WARNING: Old Grease Pencil data ('%s') still exists on Object '%s'\n",
-                                       ob->gpd->id.name + 2, ob->id.name + 2);
+                                      ob->gpd->id.name + 2, ob->id.name + 2);
                        }
                }
        }
index 50a7d9d..99b3809 100644 (file)
@@ -830,7 +830,7 @@ static short gp_stroke_addpoint(
                        if (gpencil_project_check(p)) {
                                view3d_region_operator_needs_opengl(p->win, p->ar);
                                ED_view3d_autodist_init(
-                                       p->depsgraph, p->ar, v3d, (ts->gpencil_v3d_align & GP_PROJECT_DEPTH_STROKE) ? 1 : 0);
+                                       p->depsgraph, p->ar, v3d, (ts->gpencil_v3d_align & GP_PROJECT_DEPTH_STROKE) ? 1 : 0);
                        }
 
                        /* convert screen-coordinates to appropriate coordinates (and store them) */
@@ -2306,10 +2306,11 @@ static void gpencil_draw_eraser(bContext *UNUSED(C), int x, int y, void *p_ptr)
                immUniform1f("dash_width", 12.0f);
                immUniform1f("dash_factor", 0.5f);
 
-               imm_draw_circle_wire_2d(shdr_pos, x, y, p->radius,
-                       /* XXX Dashed shader gives bad results with sets of small segments currently,
-                        *     temp hack around the issue. :( */
-                       max_ii(8, p->radius / 2));  /* was fixed 40 */
+               imm_draw_circle_wire_2d(
+                       shdr_pos, x, y, p->radius,
+                       /* XXX Dashed shader gives bad results with sets of small segments currently,
+                        *     temp hack around the issue. :( */
+                       max_ii(8, p->radius / 2));  /* was fixed 40 */
 
                immUnbindProgram();
 
@@ -3363,8 +3364,7 @@ static void gpencil_add_missing_events(bContext *C, wmOperator *op, const wmEven
                interp_v2_v2v2(pt, a, b, 0.5f);
                sub_v2_v2v2(pt, b, pt);
                /* create fake event */
-               gpencil_draw_apply_event(C, op, event, CTX_data_depsgraph(C),
-                       pt[0], pt[1]);
+               gpencil_draw_apply_event(C, op, event, CTX_data_depsgraph(C), pt[0], pt[1]);
        }
        else if (dist >= factor) {
                int slices = 2 + (int)((dist - 1.0) / factor);
@@ -3373,8 +3373,9 @@ static void gpencil_add_missing_events(bContext *C, wmOperator *op, const wmEven
                        interp_v2_v2v2(pt, a, b, n * i);
                        sub_v2_v2v2(pt, b, pt);
                        /* create fake event */
-                       gpencil_draw_apply_event(C, op, event, CTX_data_depsgraph(C),
-                               pt[0], pt[1]);
+                       gpencil_draw_apply_event(
+                               C, op, event, CTX_data_depsgraph(C),
+                               pt[0], pt[1]);
                }
        }
 }
@@ -3577,8 +3578,8 @@ static int gpencil_draw_modal(bContext *C, wmOperator *op, const wmEvent *event)
 
                                if (G.debug & G_DEBUG) {
                                        printf("found alternative region %p (old was %p) - at %d %d (sa: %d %d -> %d %d)\n",
-                                               current_region, p->ar, event->x, event->y,
-                                               p->sa->totrct.xmin, p->sa->totrct.ymin, p->sa->totrct.xmax, p->sa->totrct.ymax);
+                                              current_region, p->ar, event->x, event->y,
+                                              p->sa->totrct.xmin, p->sa->totrct.ymin, p->sa->totrct.xmax, p->sa->totrct.ymax);
                                }
 
                                if (current_region) {
@@ -3754,7 +3755,7 @@ static int gpencil_draw_modal(bContext *C, wmOperator *op, const wmEvent *event)
                        /* event doesn't need to be handled */
 #if 0
                        printf("unhandled event -> %d (mmb? = %d | mmv? = %d)\n",
-                               event->type, event->type == MIDDLEMOUSE, event->type == MOUSEMOVE);
+                              event->type, event->type == MIDDLEMOUSE, event->type == MOUSEMOVE);
 #endif
                        break;
        }
index 3a2347d..8890648 100644 (file)
@@ -412,32 +412,33 @@ static void gpencil_primitive_status_indicators(bContext *C, tGPDprimitive *tgpi
 
        if (tgpi->type == GP_STROKE_LINE) {
                BLI_strncpy(
-                       msg_str,
-                       IFACE_("Line: ESC to cancel, LMB set origin, Enter/MMB to confirm, WHEEL/+- to adjust subdivision number, Shift to align, Alt to center, E: extrude"),
-                       UI_MAX_DRAW_STR);
+                       msg_str,
+                       IFACE_("Line: ESC to cancel, LMB set origin, Enter/MMB to confirm, WHEEL/+- to adjust subdivision number, Shift to align, Alt to center, E: extrude"),
+                       UI_MAX_DRAW_STR);
        }
        else if (tgpi->type == GP_STROKE_BOX) {
                BLI_strncpy(
-                       msg_str,
-                       IFACE_("Rectangle: ESC to cancel, LMB set origin, Enter/MMB to confirm, WHEEL/+- to adjust subdivision number, Shift to square, Alt to center"),
-                       UI_MAX_DRAW_STR);
+                       msg_str,
+                       IFACE_("Rectangle: ESC to cancel, LMB set origin, Enter/MMB to confirm, WHEEL/+- to adjust subdivision number, Shift to square, Alt to center"),
+                       UI_MAX_DRAW_STR);
        }
        else if (tgpi->type == GP_STROKE_CIRCLE) {
                BLI_strncpy(
-                       msg_str,
-                       IFACE_("Circle: ESC to cancel, Enter/MMB to confirm, WHEEL/+- to adjust edge number, Shift to square, Alt to center"),
-                       UI_MAX_DRAW_STR);
+                       msg_str,
+                       IFACE_("Circle: ESC to cancel, Enter/MMB to confirm, WHEEL/+- to adjust edge number, Shift to square, Alt to center"),
+                       UI_MAX_DRAW_STR);
        }
        else if (tgpi->type == GP_STROKE_ARC) {
-               BLI_strncpy(msg_str,
-                       IFACE_("Arc: ESC to cancel, Enter/MMB to confirm, WHEEL/+- to adjust edge number, Shift to square, Alt to center, M: Flip, E: extrude"),
-                       UI_MAX_DRAW_STR);
+               BLI_strncpy(
+                       msg_str,
+                       IFACE_("Arc: ESC to cancel, Enter/MMB to confirm, WHEEL/+- to adjust edge number, Shift to square, Alt to center, M: Flip, E: extrude"),
+                       UI_MAX_DRAW_STR);
        }
        else if (tgpi->type == GP_STROKE_CURVE) {
                BLI_strncpy(
-                       msg_str,
-                       IFACE_("Curve: ESC to cancel, Enter/MMB to confirm, WHEEL/+- to adjust edge number, Shift to square, Alt to center, E: extrude"),
-                       UI_MAX_DRAW_STR);
+                       msg_str,
+                       IFACE_("Curve: ESC to cancel, Enter/MMB to confirm, WHEEL/+- to adjust edge number, Shift to square, Alt to center, E: extrude"),
+                       UI_MAX_DRAW_STR);
        }
 
        if (ELEM(tgpi->type, GP_STROKE_CIRCLE, GP_STROKE_ARC, GP_STROKE_LINE, GP_STROKE_BOX)) {
@@ -924,8 +925,9 @@ static void gp_primitive_update_strokes(bContext *C, tGPDprimitive *tgpi)
 
                        /* get origin to reproject point */
                        float origin[3];
-                       ED_gp_get_drawing_reference(tgpi->scene, tgpi->ob, tgpi->gpl,
-                               ts->gpencil_v3d_align, origin);
+                       ED_gp_get_drawing_reference(
+                               tgpi->scene, tgpi->ob, tgpi->gpl,
+                               ts->gpencil_v3d_align, origin);
                        /* reproject current */
                        ED_gpencil_tpoint_to_point(tgpi->ar, origin, tpt, &spt);
                        ED_gp_project_point_to_plane(tgpi->ob, tgpi->rv3d, origin, tgpi->lock_axis - 1, &spt);
@@ -987,10 +989,11 @@ static void gp_primitive_update_strokes(bContext *C, tGPDprimitive *tgpi)
        /* reproject to plane */
        if (!is_depth) {
                float origin[3];
-               ED_gp_get_drawing_reference(tgpi->scene, tgpi->ob, tgpi->gpl,
-                       ts->gpencil_v3d_align, origin);
+               ED_gp_get_drawing_reference(
+                       tgpi->scene, tgpi->ob, tgpi->gpl,
+                       ts->gpencil_v3d_align, origin);
                ED_gp_project_stroke_to_plane(
-                       tgpi->ob, tgpi->rv3d, gps, origin, ts->gp_sculpt.lock_axis - 1);
+                       tgpi->ob, tgpi->rv3d, gps, origin, ts->gp_sculpt.lock_axis - 1);
        }
 
        /* if parented change position relative to parent object */
index 0862a86..99bbf10 100644 (file)
@@ -877,7 +877,7 @@ static bool gp_stroke_do_circle_sel(
                        float r_hita[3], r_hitb[3];
                        bool hit_select = (bool)(pt1->flag & GP_SPOINT_SELECT);
                        ED_gpencil_select_stroke_segment(
-                               gpl, gps, pt1, hit_select, false, scale, r_hita, r_hitb);
+                               gpl, gps, pt1, hit_select, false, scale, r_hita, r_hitb);
                }
 
                /* Ensure that stroke selection is in sync with its points */
@@ -942,8 +942,8 @@ static int gpencil_circle_select_exec(bContext *C, wmOperator *op)
        GP_EDITABLE_STROKES_BEGIN(gpstroke_iter, C, gpl, gps)
        {
                changed |= gp_stroke_do_circle_sel(
-                       gpl, gps, &gsc, mx, my, radius, select, &rect,
-                       gpstroke_iter.diff_mat, selectmode, scale);
+                       gpl, gps, &gsc, mx, my, radius, select, &rect,
+                       gpstroke_iter.diff_mat, selectmode, scale);
        }
        GP_EDITABLE_STROKES_END(gpstroke_iter);
 
@@ -1066,7 +1066,7 @@ static int gpencil_generic_select_exec(
                                                bool hit_select = (bool)(pt->flag & GP_SPOINT_SELECT);
                                                float r_hita[3], r_hitb[3];
                                                ED_gpencil_select_stroke_segment(
-                                                       gpl, gps, pt, hit_select, false, scale, r_hita, r_hitb);
+                                                       gpl, gps, pt, hit_select, false, scale, r_hita, r_hitb);
                                        }
 
                                }
index 5f70380..84bfd70 100644 (file)
@@ -796,8 +796,9 @@ bool gp_point_xy_to_3d(const GP_SpaceConversion *gsc, Scene *scene, const float
        const RegionView3D *rv3d = gsc->ar->regiondata;
        float rvec[3];
 
-       ED_gp_get_drawing_reference(scene, gsc->ob, gsc->gpl,
-               scene->toolsettings->gpencil_v3d_align, rvec);
+       ED_gp_get_drawing_reference(
+               scene, gsc->ob, gsc->gpl,
+               scene->toolsettings->gpencil_v3d_align, rvec);
 
        float zfac = ED_view3d_calc_zfac(rv3d, rvec, NULL);
 
@@ -2217,8 +2218,8 @@ int ED_gpencil_select_stroke_segment(
        int direction = 0;
        float(*points2d)[2] = MEM_mallocN(sizeof(*points2d) * gps->totpoints, "GP Stroke temp 2d points");
        BKE_gpencil_stroke_2d_flat_ref(
-               gps->points, gps->totpoints,
-               gps->points, gps->totpoints, points2d, scale, &direction);
+               gps->points, gps->totpoints,
+               gps->points, gps->totpoints, points2d, scale, &direction);
 
        GHash *all_2d = BLI_ghash_ptr_new(__func__);
 
@@ -2229,9 +2230,9 @@ int ED_gpencil_select_stroke_segment(
                /* the extremes of the stroke are scaled to improve collision detection
                 * for near lines */
                BKE_gpencil_stroke_2d_flat_ref(
-                       gps->points, gps->totpoints,
-                       gps_iter->points, gps_iter->totpoints, points2d_iter,
-                       scale, &direction);
+                       gps->points, gps->totpoints,
+                       gps_iter->points, gps_iter->totpoints, points2d_iter,
+                       scale, &direction);
                BLI_ghash_insert(all_2d, gps_iter, points2d_iter);
        }
 
@@ -2255,7 +2256,7 @@ int ED_gpencil_select_stroke_segment(
                        copy_v2_v2(p2d_a2, points2d[i2]);
 
                        hit_a = gpencil_check_collision(
-                               gps, gps_array, all_2d, totstrokes, p2d_a1, p2d_a2, r_hit2d);
+                               gps, gps_array, all_2d, totstrokes, p2d_a1, p2d_a2, r_hit2d);
 
                        if (select) {
                                pta1->flag |= GP_SPOINT_SELECT;
@@ -2289,7 +2290,7 @@ int ED_gpencil_select_stroke_segment(
                copy_v2_v2(p2d_a2, points2d[i2]);
 
                hit_b = gpencil_check_collision(
-                       gps, gps_array, all_2d, totstrokes, p2d_a1, p2d_a2, r_hit2d);
+                       gps, gps_array, all_2d, totstrokes, p2d_a1, p2d_a2, r_hit2d);
 
                if (select) {
                        pta1->flag |= GP_SPOINT_SELECT;
index bb49f02..df116b3 100644 (file)
@@ -1328,8 +1328,8 @@ void UI_view2d_grid_draw(View2D *v2d, View2DGrid *grid, int flag)
 {
        float vec1[2], vec2[2];
        int a, step;
-       int vertical_minor_step = (BLI_rcti_size_x(&v2d->mask) + 1) / (U.v2d_min_gridsize * UI_DPI_FAC),
-               horizontal_major_step = (BLI_rcti_size_y(&v2d->mask) + 1) / (U.v2d_min_gridsize * UI_DPI_FAC);
+       int vertical_minor_step = (BLI_rcti_size_x(&v2d->mask) + 1) / (U.v2d_min_gridsize * UI_DPI_FAC);
+       int horizontal_major_step = (BLI_rcti_size_y(&v2d->mask) + 1) / (U.v2d_min_gridsize * UI_DPI_FAC);
        uchar grid_line_color[3];
 
        /* check for grid first, as it may not exist */
index d73ddfa..3829821 100644 (file)
@@ -500,11 +500,13 @@ void WM_OT_collada_export(wmOperatorType *ot)
                        "Export also the curve handles (if available) (this does only work when the inverse parent matrix "
                        "is the unity matrix, otherwise you may end up with odd results)");
 
-       RNA_def_boolean(func, "keep_keyframes", 0, "Keep Keyframes",
-               "Use existing keyframes as additional sample points (this helps when you want to keep manual tweaks)");
+       RNA_def_boolean(
+               func, "keep_keyframes", 0, "Keep Keyframes",
+               "Use existing keyframes as additional sample points (this helps when you want to keep manual tweaks)");
 
-       RNA_def_boolean(func, "keep_flat_curves", 0, "All keyed curves",
-               "Export also curves which have only one key or are totally flat");
+       RNA_def_boolean(
+               func, "keep_flat_curves", 0, "All keyed curves",
+               "Export also curves which have only one key or are totally flat");
 
        RNA_def_boolean(func, "active_uv_only", 0, "Only Selected UV Map",
                        "Export only the selected UV Map");
index 0b079fd..1059374 100644 (file)
@@ -146,8 +146,9 @@ static void edbm_bevel_update_header(bContext *C, wmOperator *op)
                BLI_snprintf(offset_str, NUM_STR_REP_LEN, "%.1f%%", RNA_float_get(op->ptr, "offset_pct"));
        }
        else {
-               bUnit_AsString2(offset_str, NUM_STR_REP_LEN, (double)RNA_float_get(op->ptr, "offset"), 3,
-                       B_UNIT_LENGTH, &sce->unit, true);
+               bUnit_AsString2(
+                       offset_str, NUM_STR_REP_LEN, (double)RNA_float_get(op->ptr, "offset"), 3,
+                       B_UNIT_LENGTH, &sce->unit, true);
        }
 
        prop = RNA_struct_find_property(op->ptr, "offset_type");
@@ -157,46 +158,47 @@ static void edbm_bevel_update_header(bContext *C, wmOperator *op)
        prop = RNA_struct_find_property(op->ptr, "miter_inner");
        RNA_property_enum_name_gettexted(C, op->ptr, prop, RNA_property_enum_get(op->ptr, prop), &imiter_str);
 
-       BLI_snprintf(header, sizeof(header),
-               IFACE_("%s: confirm, "
-                       "%s: cancel, "
-                       "%s: mode (%s), "
-                       "%s: width (%s), "
-                       "%s: segments (%d), "
-                       "%s: profile (%.3f), "
-                       "%s: clamp overlap (%s), "
-                       "%s: vertex only (%s), "
-                       "%s: outer miter (%s), "
-                       "%s: inner miter (%s), "
-                       "%s: harden normals (%s), "
-                       "%s: mark seam (%s), "
-                       "%s: mark sharp (%s)"
-               ),
-               WM_MODALKEY(BEV_MODAL_CONFIRM),
-               WM_MODALKEY(BEV_MODAL_CANCEL),
-               WM_MODALKEY(BEV_MODAL_OFFSET_MODE_CHANGE),
-               mode_str,
-               WM_MODALKEY(BEV_MODAL_VALUE_OFFSET),
-               offset_str,
-               WM_MODALKEY(BEV_MODAL_VALUE_SEGMENTS),
-               RNA_int_get(op->ptr, "segments"),
-               WM_MODALKEY(BEV_MODAL_VALUE_PROFILE),
-               RNA_float_get(op->ptr, "profile"),
-               WM_MODALKEY(BEV_MODAL_CLAMP_OVERLAP_TOGGLE),
-               WM_bool_as_string(RNA_boolean_get(op->ptr, "clamp_overlap")),
-               WM_MODALKEY(BEV_MODAL_VERTEX_ONLY_TOGGLE),
-               WM_bool_as_string(RNA_boolean_get(op->ptr, "vertex_only")),
-               WM_MODALKEY(BEV_MODAL_OUTER_MITER_CHANGE),
-               omiter_str,
-               WM_MODALKEY(BEV_MODAL_INNER_MITER_CHANGE),
-               imiter_str,
-               WM_MODALKEY(BEV_MODAL_HARDEN_NORMALS_TOGGLE),
-               WM_bool_as_string(RNA_boolean_get(op->ptr, "harden_normals")),
-               WM_MODALKEY(BEV_MODAL_MARK_SEAM_TOGGLE),
-               WM_bool_as_string(RNA_boolean_get(op->ptr, "mark_seam")),
-               WM_MODALKEY(BEV_MODAL_MARK_SHARP_TOGGLE),
-               WM_bool_as_string(RNA_boolean_get(op->ptr, "mark_sharp"))
-               );
+       BLI_snprintf(
+               header, sizeof(header),
+               IFACE_("%s: confirm, "
+                      "%s: cancel, "
+                      "%s: mode (%s), "
+                      "%s: width (%s), "
+                      "%s: segments (%d), "
+                      "%s: profile (%.3f), "
+                      "%s: clamp overlap (%s), "
+                      "%s: vertex only (%s), "
+                      "%s: outer miter (%s), "
+                      "%s: inner miter (%s), "
+                      "%s: harden normals (%s), "
+                      "%s: mark seam (%s), "
+                      "%s: mark sharp (%s)"
+               ),
+               WM_MODALKEY(BEV_MODAL_CONFIRM),
+               WM_MODALKEY(BEV_MODAL_CANCEL),
+               WM_MODALKEY(BEV_MODAL_OFFSET_MODE_CHANGE),
+               mode_str,
+               WM_MODALKEY(BEV_MODAL_VALUE_OFFSET),
+               offset_str,
+               WM_MODALKEY(BEV_MODAL_VALUE_SEGMENTS),
+               RNA_int_get(op->ptr, "segments"),
+               WM_MODALKEY(BEV_MODAL_VALUE_PROFILE),
+               RNA_float_get(op->ptr, "profile"),
+               WM_MODALKEY(BEV_MODAL_CLAMP_OVERLAP_TOGGLE),
+               WM_bool_as_string(RNA_boolean_get(op->ptr, "clamp_overlap")),
+               WM_MODALKEY(BEV_MODAL_VERTEX_ONLY_TOGGLE),
+               WM_bool_as_string(RNA_boolean_get(op->ptr, "vertex_only")),
+               WM_MODALKEY(BEV_MODAL_OUTER_MITER_CHANGE),
+               omiter_str,
+               WM_MODALKEY(BEV_MODAL_INNER_MITER_CHANGE),
+               imiter_str,
+               WM_MODALKEY(BEV_MODAL_HARDEN_NORMALS_TOGGLE),
+               WM_bool_as_string(RNA_boolean_get(op->ptr, "harden_normals")),
+               WM_MODALKEY(BEV_MODAL_MARK_SEAM_TOGGLE),
+               WM_bool_as_string(RNA_boolean_get(op->ptr, "mark_seam")),
+               WM_MODALKEY(BEV_MODAL_MARK_SHARP_TOGGLE),
+               WM_bool_as_string(RNA_boolean_get(op->ptr, "mark_sharp"))
+       );
 
 #undef WM_MODALKEY
 
@@ -223,7 +225,7 @@ static bool edbm_bevel_init(bContext *C, wmOperator *op, const bool is_modal)
        {
                uint ob_store_len = 0;
                Object **objects = BKE_view_layer_array_from_objects_in_edit_mode_unique_data(
-                       view_layer, CTX_wm_view3d(C), &ob_store_len);
+                       view_layer, CTX_wm_view3d(C), &ob_store_len);
                opdata->ob_store = MEM_malloc_arrayN(ob_store_len, sizeof(*opdata->ob_store), __func__);
                for (uint ob_index = 0; ob_index < ob_store_len; ob_index++) {
                        Object *obedit = objects[ob_index];
@@ -272,8 +274,9 @@ static bool edbm_bevel_init(bContext *C, wmOperator *op, const bool is_modal)
                for (uint ob_index = 0; ob_index < opdata->ob_store_len; ob_index++) {
                        opdata->ob_store[ob_index].mesh_backup = EDBM_redo_state_store(opdata->ob_store[ob_index].em);
                }
-               opdata->draw_handle_pixel = ED_region_draw_cb_activate(ar->type, ED_region_draw_mouse_line_cb,
-                       opdata->mcenter, REGION_DRAW_POST_PIXEL);
+               opdata->draw_handle_pixel = ED_region_draw_cb_activate(
+                       ar->type, ED_region_draw_mouse_line_cb,
+                       opdata->mcenter, REGION_DRAW_POST_PIXEL);
                G.moving = G_TRANSFORM_EDIT;
 
                if (v3d) {
@@ -565,31 +568,31 @@ wmKeyMap *bevel_modal_keymap(wmKeyConfig *keyconf)
                {BEV_MODAL_CANCEL, "CANCEL", 0, "Cancel", "Cancel bevel"},
                {BEV_MODAL_CONFIRM, "CONFIRM", 0, "Confirm", "Confirm bevel"},
                {BEV_MODAL_VALUE_OFFSET, "VALUE_OFFSET", 0, "Value is offset",
-                       "Value changes offset"},
+                "Value changes offset"},
                {BEV_MODAL_VALUE_PROFILE, "VALUE_PROFILE", 0, "Value is profile",
-                       "Value changes profile"},
+                "Value changes profile"},
                {BEV_MODAL_VALUE_SEGMENTS, "VALUE_SEGMENTS", 0, "Value is segments",
-                       "Value changes segments"},
+                "Value changes segments"},
                {BEV_MODAL_SEGMENTS_UP, "SEGMENTS_UP", 0, "Increase segments",
-                       "Increase segments"},
+                "Increase segments"},
                {BEV_MODAL_SEGMENTS_DOWN, "SEGMENTS_DOWN", 0, "Decrease segments",
-                       "Decrease segments"},
+                "Decrease segments"},
                {BEV_MODAL_OFFSET_MODE_CHANGE, "OFFSET_MODE_CHANGE", 0, "Change offset mode",
-                       "Cycle through offset modes"},
+                "Cycle through offset modes"},
                {BEV_MODAL_CLAMP_OVERLAP_TOGGLE, "CLAMP_OVERLAP_TOGGLE", 0, "Toggle clamp overlap",
-                       "Toggle clamp overlap flag"},
+                "Toggle clamp overlap flag"},
                {BEV_MODAL_VERTEX_ONLY_TOGGLE, "VERTEX_ONLY_TOGGLE", 0, "Toggle vertex only",
-                       "Toggle vertex only flag"},
+                "Toggle vertex only flag"},
                {BEV_MODAL_HARDEN_NORMALS_TOGGLE, "HARDEN_NORMALS_TOGGLE", 0, "Toggle harden normals",
-                       "Toggle harden normals flag"},
+                "Toggle harden normals flag"},
                {BEV_MODAL_MARK_SEAM_TOGGLE, "MARK_SEAM_TOGGLE", 0, "Toggle mark seam",
-                       "Toggle mark seam flag"},
+                "Toggle mark seam flag"},
                {BEV_MODAL_MARK_SHARP_TOGGLE, "MARK_SHARP_TOGGLE", 0, "Toggle mark sharp",
-                       "Toggle mark sharp flag"},
+                "Toggle mark sharp flag"},
                {BEV_MODAL_OUTER_MITER_CHANGE, "OUTER_MITER_CHANGE", 0, "Change outer miter",
-                       "Cycle through outer miter kinds"},
+                "Cycle through outer miter kinds"},
                {BEV_MODAL_INNER_MITER_CHANGE, "INNER_MITER_CHANGE", 0, "Change inner miter",
-                       "Cycle through inner miter kinds"},
+                "Cycle through inner miter kinds"},
                {0, NULL, 0, NULL, NULL},
        };
 
@@ -868,26 +871,34 @@ void MESH_OT_bevel(wmOperatorType *ot)
        RNA_def_property_range(prop, 0.0, 100);
        RNA_def_property_ui_text(prop, "Width Percent", "Bevel amount for percentage method");
        RNA_def_int(ot->srna, "segments", 1, 1, SEGMENTS_HARD_MAX, "Segments", "Segments for curved edge", 1, 100);
-       RNA_def_float(ot->srna, "profile", 0.5f, PROFILE_HARD_MIN, 1.0f, "Profile",
-               "Controls profile shape (0.5 = round)", PROFILE_HARD_MIN, 1.0f);
+       RNA_def_float(
+               ot->srna, "profile", 0.5f, PROFILE_HARD_MIN, 1.0f, "Profile",
+               "Controls profile shape (0.5 = round)", PROFILE_HARD_MIN, 1.0f);
        RNA_def_boolean(ot->srna, "vertex_only", false, "Vertex Only", "Bevel only vertices");
-       RNA_def_boolean(ot->srna, "clamp_overlap", false, "Clamp Overlap",
-               "Do not allow beveled edges/vertices to overlap each other");
+       RNA_def_boolean(
+               ot->srna, "clamp_overlap", false, "Clamp Overlap",
+               "Do not allow beveled edges/vertices to overlap each other");
        RNA_def_boolean(ot->srna, "loop_slide", true, "Loop Slide", "Prefer slide along edge to even widths");
        RNA_def_boolean(ot->srna, "mark_seam", false, "Mark Seams", "Mark Seams along beveled edges");
        RNA_def_boolean(ot->srna, "mark_sharp", false, "Mark Sharp", "Mark beveled edges as sharp");
-       RNA_def_int(ot->srna, "material", -1, -1, INT_MAX, "Material",
-               "Material for bevel faces (-1 means use adjacent faces)", -1, 100);
-       RNA_def_boolean(ot->srna, "harden_normals", false, "Harden Normals",
-               "Match normals of new faces to adjacent faces");
-       RNA_def_enum(ot->srna, "face_strength_mode", face_strength_mode_items, BEVEL_FACE_STRENGTH_NONE,
-               "Face Strength Mode", "Whether to set face strength, and which faces to set face strength on");
-       RNA_def_enum(ot->srna, "miter_outer", miter_outer_items, BEVEL_MITER_SHARP,
-               "Outer Miter", "Pattern to use for outside of miters");
-       RNA_def_enum(ot->srna, "miter_inner", miter_inner_items, BEVEL_MITER_SHARP,
-               "Inner Miter", "Pattern to use for inside of miters");
-       RNA_def_float(ot->srna, "spread", 0.1f, 0.0f, 1e6f, "Spread",
-               "Amount to spread arcs for arc inner miters", 0.0f, 100.0f);
+       RNA_def_int(
+               ot->srna, "material", -1, -1, INT_MAX, "Material",
+               "Material for bevel faces (-1 means use adjacent faces)", -1, 100);
+       RNA_def_boolean(
+               ot->srna, "harden_normals", false, "Harden Normals",
+               "Match normals of new faces to adjacent faces");
+       RNA_def_enum(
+               ot->srna, "face_strength_mode", face_strength_mode_items, BEVEL_FACE_STRENGTH_NONE,
+               "Face Strength Mode", "Whether to set face strength, and which faces to set face strength on");
+       RNA_def_enum(
+               ot->srna, "miter_outer", miter_outer_items, BEVEL_MITER_SHARP,
+               "Outer Miter", "Pattern to use for outside of miters");
+       RNA_def_enum(
+               ot->srna, "miter_inner", miter_inner_items, BEVEL_MITER_SHARP,
+               "Inner Miter", "Pattern to use for inside of miters");
+       RNA_def_float(
+               ot->srna, "spread", 0.1f, 0.0f, 1e6f, "Spread",
+               "Amount to spread arcs for arc inner miters", 0.0f, 100.0f);
        prop = RNA_def_boolean(ot->srna, "release_confirm", 0, "Confirm on Release", "");
        RNA_def_property_flag(prop, PROP_HIDDEN | PROP_SKIP_SAVE);
 
index ab49a6c..f2ba227 100644 (file)
@@ -307,9 +307,9 @@ static int edbm_extrude_repeat_exec(bContext *C, wmOperator *op)
                        edbm_extrude_ex(obedit, em, BM_ALL_NOLOOP, BM_ELEM_SELECT, false, false, false);
 
                        BMO_op_callf(
-                               em->bm, BMO_FLAG_DEFAULTS,
-                               "translate vec=%v verts=%hv",
-                               dvec, BM_ELEM_SELECT);
+                               em->bm, BMO_FLAG_DEFAULTS,
+                               "translate vec=%v verts=%hv",
+                               dvec, BM_ELEM_SELECT);
                }
 
                EDBM_mesh_normals_update(em);
index 08486f2..c500683 100644 (file)
@@ -884,8 +884,8 @@ static int edbm_face_split_by_edges_exec(bContext *C, wmOperator *UNUSED(op))
                                                                float v_pivot_co[3];
                                                                float v_pivot_fac;
                                                                BMEdge *e_split = bm_face_split_edge_find(
-                                                                       e, f, v_pivot, bm->ftable, bm->totface,
-                                                                       v_pivot_co, &v_pivot_fac);
+                                                                       e, f, v_pivot, bm->ftable, bm->totface,
+                                                                       v_pivot_co, &v_pivot_fac);
 
                                                                if (e_split) {
                                                                        /* for degenerate cases this vertex may be in one
@@ -918,9 +918,9 @@ static int edbm_face_split_by_edges_exec(bContext *C, wmOperator *UNUSED(op))
                                        struct LinkBase *e_ls_base = BLI_ghashIterator_getValue(&gh_iter);
 
                                        bm_face_split_by_edges_island_connect(
-                                               bm, f,
-                                               e_ls_base->list, e_ls_base->list_len,
-                                               mem_arena_edgenet);
+                                               bm, f,
+                                               e_ls_base->list, e_ls_base->list_len,
+                                               mem_arena_edgenet);
 
                                        BLI_memarena_clear(mem_arena_edgenet);
                                }
index 17ddb48..9a58608 100644 (file)
@@ -8197,7 +8197,7 @@ static int edbm_set_normals_from_faces_exec(bContext *C, wmOperator *op)
                                                if (!is_zero_v3(vnors[v_index])) {
                                                        short *clnors = BM_ELEM_CD_GET_VOID_P(l, cd_clnors_offset);
                                                        BKE_lnor_space_custom_normal_to_data(
-                                                               bm->lnor_spacearr->lspacearr[l_index], vnors[v_index], clnors);
+                                                               bm->lnor_spacearr->lspacearr[l_index], vnors[v_index], clnors);
 
                                                        if (bm->lnor_spacearr->lspacearr[l_index]->flags & MLNOR_SPACE_IS_SINGLE) {
                                                                BLI_BITMAP_ENABLE(loop_set, l_index);
index a55163b..c8a755a 100644 (file)
@@ -283,8 +283,7 @@ static bool object_modifier_safe_to_delete(Main *bmain, Object *ob,
        ModifierType type)
 {
        return (!object_has_modifier(ob, exclude, type) &&
-               !ED_object_iter_other(bmain, ob, false,
-                       object_has_modifier_cb, &type));
+               !ED_object_iter_other(bmain, ob, false, object_has_modifier_cb, &type));
 }
 
 static bool object_modifier_remove(Main *bmain, Object *ob, ModifierData *md,
@@ -1182,9 +1181,10 @@ static int multires_higher_levels_delete_exec(bContext *C, wmOperator *op)
 
        multiresModifier_del_levels(mmd, scene, ob, 1);
 
-       ED_object_iter_other(CTX_data_main(C), ob, true,
-               ED_object_multires_update_totlevels_cb,
-               &mmd->totlvl);
+       ED_object_iter_other(
+               CTX_data_main(C), ob, true,
+               ED_object_multires_update_totlevels_cb,
+               &mmd->totlvl);
 
        WM_event_add_notifier(C, NC_OBJECT | ND_MODIFIER, ob);
 
@@ -1227,9 +1227,10 @@ static int multires_subdivide_exec(bContext *C, wmOperator *op)
 
        multiresModifier_subdivide(mmd, scene, ob, 0, mmd->simple);
 
-       ED_object_iter_other(CTX_data_main(C), ob, true,
-               ED_object_multires_update_totlevels_cb,
-               &mmd->totlvl);
+       ED_object_iter_other(
+               CTX_data_main(C), ob, true,
+               ED_object_multires_update_totlevels_cb,
+               &mmd->totlvl);
 
        DEG_id_tag_update(&ob->id, ID_RECALC_GEOMETRY);
        WM_event_add_notifier(C, NC_OBJECT | ND_MODIFIER, ob);
@@ -1404,8 +1405,8 @@ void OBJECT_OT_multires_external_save(wmOperatorType *ot)
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO | OPTYPE_INTERNAL;
 
        WM_operator_properties_filesel(
-               ot, FILE_TYPE_FOLDER | FILE_TYPE_BTX, FILE_SPECIAL, FILE_SAVE,
-               WM_FILESEL_FILEPATH | WM_FILESEL_RELPATH, FILE_DEFAULTDISPLAY, FILE_SORT_ALPHA);
+               ot, FILE_TYPE_FOLDER | FILE_TYPE_BTX, FILE_SPECIAL, FILE_SAVE,
+               WM_FILESEL_FILEPATH | WM_FILESEL_RELPATH, FILE_DEFAULTDISPLAY, FILE_SORT_ALPHA);
        edit_modifier_properties(ot);
 }
 
@@ -1769,8 +1770,9 @@ static Object *modifier_skin_armature_create(Depsgraph *depsgraph, Main *bmain,
        arm->edbo = MEM_callocN(sizeof(ListBase), "edbo armature");
 
        mvert_skin = CustomData_get_layer(&me->vdata, CD_MVERT_SKIN);
-       BKE_mesh_vert_edge_map_create(&emap, &emap_mem,
-               me->medge, me->totvert, me->totedge);
+       BKE_mesh_vert_edge_map_create(
+               &emap, &emap_mem,
+               me->medge, me->totvert, me->totedge);
 
        edges_visited = BLI_BITMAP_NEW(me->totedge, "edge_visited");
 
@@ -2174,9 +2176,10 @@ static int ocean_bake_exec(bContext *C, wmOperator *op)
                return OPERATOR_FINISHED;
        }
 
-       och = BKE_ocean_init_cache(omd->cachepath, modifier_path_relbase(bmain, ob),
-               omd->bakestart, omd->bakeend, omd->wave_scale,
-               omd->chop_amount, omd->foam_coverage, omd->foam_fade, omd->resolution);
+       och = BKE_ocean_init_cache(
+               omd->cachepath, modifier_path_relbase(bmain, ob),
+               omd->bakestart, omd->bakeend, omd->wave_scale,
+               omd->chop_amount, omd->foam_coverage, omd->foam_fade, omd->resolution);
 
        och->time = MEM_mallocN(och->duration * sizeof(float), "foam bake time");
 
@@ -2213,8 +2216,9 @@ static int ocean_bake_exec(bContext *C, wmOperator *op)
        scene->r.cfra = cfra;
 
        /* setup job */
-       wm_job = WM_jobs_get(CTX_wm_manager(C), CTX_wm_window(C), scene, "Ocean Simulation",
-               WM_JOB_PROGRESS, WM_JOB_TYPE_OBJECT_SIM_OCEAN);
+       wm_job = WM_jobs_get(
+               CTX_wm_manager(C), CTX_wm_window(C), scene, "Ocean Simulation",
+               WM_JOB_PROGRESS, WM_JOB_TYPE_OBJECT_SIM_OCEAN);
        oj = MEM_callocN(sizeof(OceanBakeJob), "ocean bake job");
        oj->owner = ob;
        oj->ocean = ocean;
index 7a786f3..0b63d74 100644 (file)
@@ -4477,8 +4477,8 @@ static bool shape_cut_test_point(PEData *data, ParticleCacheKey *key)
        userdata.num_hits = 0;
 
        BLI_bvhtree_ray_cast_all(
-               shape_bvh->tree, key->co, dir, 0.0f, BVH_RAYCAST_DIST_MAX,
-               point_inside_bvh_cb, &userdata);
+               shape_bvh->tree, key->co, dir, 0.0f, BVH_RAYCAST_DIST_MAX,
+               point_inside_bvh_cb, &userdata);
 
        /* for any point inside a watertight mesh the number of hits is uneven */
        return (userdata.num_hits % 2) == 1;
index feadc88..0e0292c 100644 (file)
@@ -327,7 +327,7 @@ static void screen_opengl_render_doit(const bContext *C, OGLRender *oglrender, R
 
                        G.f |= G_FLAG_RENDER_VIEWPORT;
                        ED_gpencil_draw_ex(
-                               view_layer, rv3d, scene, gpd, sizex, sizey, scene->r.cfra, SPACE_SEQ);
+                               view_layer, rv3d, scene, gpd, sizex, sizey, scene->r.cfra, SPACE_SEQ);
                        G.f &= ~G_FLAG_RENDER_VIEWPORT;
 
                        gp_rect = MEM_mallocN(sizex * sizey * sizeof(unsigned char) * 4, "offscreen rect");
index 329aec5..0d4a8b8 100644 (file)
@@ -898,10 +898,12 @@ static int light_cache_bake_invoke(bContext *C, wmOperator *op, const wmEvent *U
 void SCENE_OT_light_cache_bake(wmOperatorType *ot)
 {
        static const EnumPropertyItem light_cache_subset_items[] = {
-               {LIGHTCACHE_SUBSET_ALL, "ALL", 0, "All LightProbes", "Bake both irradiance grids and reflection cubemaps"},
-               {LIGHTCACHE_SUBSET_DIRTY, "DIRTY", 0, "Dirty Only", "Only bake lightprobes that are marked as dirty"},
-               {LIGHTCACHE_SUBSET_CUBE, "CUBEMAPS", 0, "Cubemaps Only", "Try to only bake reflection cubemaps if irradiance "
-                                                                    "grids are up to date"},
+               {LIGHTCACHE_SUBSET_ALL, "ALL", 0, "All LightProbes",
+                "Bake both irradiance grids and reflection cubemaps"},
+               {LIGHTCACHE_SUBSET_DIRTY, "DIRTY", 0, "Dirty Only",
+                "Only bake lightprobes that are marked as dirty"},
+               {LIGHTCACHE_SUBSET_CUBE, "CUBEMAPS", 0, "Cubemaps Only",
+                "Try to only bake reflection cubemaps if irradiance grids are up to date"},
                {0, NULL, 0, NULL, NULL},
        };
 
index a782ca9..d662240 100644 (file)
@@ -808,9 +808,9 @@ static void stroke_done(struct bContext *C, struct wmOperator *op)
 
        if (stroke->timer) {
                WM_event_remove_timer(
-                       CTX_wm_manager(C),
-                       CTX_wm_window(C),
-                       stroke->timer);
+                       CTX_wm_manager(C),
+                       CTX_wm_window(C),
+                       stroke->timer);
        }
 
        if (stroke->rng) {
index f1ada42..4149be9 100644 (file)
@@ -890,7 +890,7 @@ static void do_weight_paint_vertex_multi(
                }
 
                oldw = BKE_defvert_multipaint_collective_weight(
-                       dv_prev, wpi->defbase_tot, wpi->defbase_sel, wpi->defbase_tot_sel, wpi->do_auto_normalize);
+                       dv_prev, wpi->defbase_tot, wpi->defbase_sel, wpi->defbase_tot_sel, wpi->do_auto_normalize);
        }
        else {
                oldw = curw;
index f1b41ff..34c049c 100644 (file)
@@ -1859,8 +1859,8 @@ static void do_topology_rake_bmesh_task_cb_ex(
 
        float tmp[3];
        mul_v3_v3fl(
-               tmp, ss->cache->sculpt_normal_symm,
-               dot_v3v3(ss->cache->sculpt_normal_symm, direction));
+               tmp, ss->cache->sculpt_normal_symm,
+               dot_v3v3(ss->cache->sculpt_normal_symm, direction));
        sub_v3_v3(direction, tmp);
 
        /* Cancel if there's no grab data. */
@@ -1880,8 +1880,8 @@ static void do_topology_rake_bmesh_task_cb_ex(
        {
                if (sculpt_brush_test_sq_fn(&test, vd.co)) {
                        const float fade = bstrength * tex_strength(
-                               ss, brush, vd.co, sqrtf(test.dist),
-                               vd.no, vd.fno, *vd.mask, tls->thread_id) * ss->cache->pressure;
+                               ss, brush, vd.co, sqrtf(test.dist),
+                               vd.no, vd.fno, *vd.mask, tls->thread_id) * ss->cache->pressure;
 
                        float avg[3], val[3];
 
index bcf536e..067e0f5 100644 (file)
@@ -156,8 +156,9 @@ static void buttons_texture_modifier_gpencil_foreach(void *userData, Object *ob,
        RNA_pointer_create(&ob->id, &RNA_GpencilModifier, md, &ptr);
        prop = RNA_struct_find_property(&ptr, propname);
 
-       buttons_texture_user_property_add(users, &ob->id, ptr, prop,
-               N_("Grease Pencil Modifiers"), RNA_struct_ui_icon(ptr.type), md->name);
+       buttons_texture_user_property_add(
+               users, &ob->id, ptr, prop,
+               N_("Grease Pencil Modifiers"), RNA_struct_ui_icon(ptr.type), md->name);
 }
 
 static void buttons_texture_users_from_context(ListBase *users, const bContext *C, SpaceProperties *sbuts)
index e788af1..fdcc915 100644 (file)
@@ -475,9 +475,9 @@ static void stats_string(ViewLayer *view_layer)
        }
        else if ((ob) && (ob->type == OB_GPENCIL)) {
                ofs += BLI_snprintf(s + ofs, MAX_INFO_LEN - ofs,
-                       IFACE_("Layers:%s | Frames:%s | Strokes:%s | Points:%s | Objects:%s/%s"),
-                       stats_fmt.totgplayer, stats_fmt.totgpframe, stats_fmt.totgpstroke,
-                       stats_fmt.totgppoint, stats_fmt.totobjsel, stats_fmt.totobj);
+                                   IFACE_("Layers:%s | Frames:%s | Strokes:%s | Points:%s | Objects:%s/%s"),
+                                   stats_fmt.totgplayer, stats_fmt.totgpframe, stats_fmt.totgpstroke,
+                                   stats_fmt.totgppoint, stats_fmt.totobjsel, stats_fmt.totobj);
 
                ofs += BLI_strncpy_rlen(s + ofs, memstr, MAX_INFO_LEN - ofs);
                ofs += BLI_strncpy_rlen(s + ofs, gpumemstr, MAX_INFO_LEN - ofs);
index 31a4b15..3b6ca49 100644 (file)
@@ -982,8 +982,9 @@ static ImBuf *sequencer_make_scope(Scene *scene, ImBuf *ibuf, ImBuf *(*make_scop
        ImBuf *display_ibuf = IMB_dupImBuf(ibuf);
        ImBuf *scope;
 
-       IMB_colormanagement_imbuf_make_display_space(display_ibuf, &scene->view_settings,
-                                                            &scene->display_settings);
+       IMB_colormanagement_imbuf_make_display_space(
+               display_ibuf, &scene->view_settings,
+               &scene->display_settings);
 
        scope = make_scope_cb(display_ibuf);
 
@@ -1078,12 +1079,13 @@ void sequencer_draw_maskedit(const bContext *C, Scene *scene, ARegion *ar, Space
                        width = (scene->r.size * scene->r.xsch) / 100;
                        height = (scene->r.size * scene->r.ysch) / 100;
 
-                       ED_mask_draw_region(mask, ar,
-                               0, 0, 0,  /* TODO */
-                               width, height,
-                               aspx, aspy,
-                               false, true,
-                               NULL, C);
+                       ED_mask_draw_region(
+                               mask, ar,
+                               0, 0, 0,  /* TODO */
+                               width, height,
+                               aspx, aspy,
+                               false, true,
+                               NULL, C);
                }
        }
 }
index 2108fc1..fe84e5b 100644 (file)
@@ -472,8 +472,9 @@ void VIEW3D_OT_snap_selected_to_cursor(wmOperatorType *ot)
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO | OPTYPE_USE_EVAL_DATA;
 
        /* rna */
-       RNA_def_boolean(ot->srna, "use_offset", 1, "Offset",
-               "If the selection should be snapped as a whole or by each object center");
+       RNA_def_boolean(
+               ot->srna, "use_offset", 1, "Offset",
+               "If the selection should be snapped as a whole or by each object center");
 }
 
 /* *************************************************** */
index 4e41b3a..c447d75 100644 (file)
@@ -4189,7 +4189,7 @@ static void headerRotation(TransInfo *t, char str[UI_MAX_DRAW_STR], float final)
        }
        else {
                ofs += BLI_snprintf(str + ofs, UI_MAX_DRAW_STR - ofs, IFACE_("Rot: %.2f%s %s"),
-                       RAD2DEGF(final), t->con.text, t->proptext);
+                                   RAD2DEGF(final), t->con.text, t->proptext);
        }
 
        if (t->flag & T_PROP_EDIT_ALL) {
@@ -4650,7 +4650,7 @@ void freeCustomNormalArray(TransInfo *t, TransDataContainer *tc, TransCustomData
                /* Restore custom loop normal on cancel */
                for (int i = 0; i < lnors_ed_arr->totloop; i++, lnor_ed++) {
                        BKE_lnor_space_custom_normal_to_data(
-                               bm->lnor_spacearr->lspacearr[lnor_ed->loop_index], lnor_ed->niloc, lnor_ed->clnors_data);
+                               bm->lnor_spacearr->lspacearr[lnor_ed->loop_index], lnor_ed->niloc, lnor_ed->clnors_data);
                }
        }
 
@@ -4727,7 +4727,7 @@ static void applyNormalRotation(TransInfo *t, const int UNUSED(mval[2]))
                        mul_v3_m3v3(lnor_ed->nloc, mat, lnor_ed->niloc);
 
                        BKE_lnor_space_custom_normal_to_data(
-                               bm->lnor_spacearr->lspacearr[lnor_ed->loop_index], lnor_ed->nloc, lnor_ed->clnors_data);
+                               bm->lnor_spacearr->lspacearr[lnor_ed->loop_index], lnor_ed->nloc, lnor_ed->clnors_data);
                }
        }
 
index 75d1aa9..43e038e 100644 (file)
@@ -8480,8 +8480,9 @@ static void createTransGPencil(bContext *C, TransInfo *t)
                                        float falloff = 1.0f; /* by default no falloff */
                                        if ((is_multiedit) && (use_multiframe_falloff)) {
                                                /* Faloff depends on distance to active frame (relative to the overall frame range) */
-                                               falloff = BKE_gpencil_multiframe_falloff_calc(gpf, gpl->actframe->framenum,
-                                                       f_init, f_end, ts->gp_sculpt.cur_falloff);
+                                               falloff = BKE_gpencil_multiframe_falloff_calc(
+                                                       gpf, gpl->actframe->framenum,
+                                                       f_init, f_end, ts->gp_sculpt.cur_falloff);
                                        }
 
                                        for (gps = gpf->strokes.first; gps; gps = gps->next) {
index 1d488f5..c41c5f1 100644 (file)
@@ -87,8 +87,9 @@ protected:
        float get_stroke_vertex_z(void) const;
        unsigned int get_stroke_mesh_id(void) const;
        bool test_triangle_visibility(StrokeVertexRep *svRep[3]) const;
-       void test_strip_visibility(Strip::vertex_container& strip_vertices,
-               int *visible_faces, int *visible_segments) const;
+       void test_strip_visibility(
+               Strip::vertex_container& strip_vertices,
+               int *visible_faces, int *visible_segments) const;
 
        vector<StrokeRep *> _strokeReps;
 
index b282aca..3c14d9f 100644 (file)
@@ -144,7 +144,7 @@ protected:
 
 public:
        Strip(const std::vector<StrokeVertex*>& iStrokeVertices, bool hasTex = false,
-                       bool tipBegin = false, bool tipEnd = false, float texStep = 1.0);
+             bool tipBegin = false, bool tipEnd = false, float texStep = 1.0);
        Strip(const Strip& iBrother);
        virtual ~Strip();
 
index 56f07d2..7dbb79b 100644 (file)
@@ -135,8 +135,7 @@ static void BKE_gpencil_instance_modifier_instance_tfm(
                add_v3_v3(mat_offset[3], mmd->offset);
                invert_m4_m4(obinv, ob->obmat);
 
-               mul_m4_series(r_offset, mat_offset,
-                       obinv, mmd->object->obmat);
+               mul_m4_series(r_offset, mat_offset, obinv, mmd->object->obmat);
                copy_m4_m4(mat_offset, r_offset);
 
                /* clear r_mat locations to avoid double transform */
index ec22b8d..f5b3cab 100644 (file)
@@ -787,8 +787,7 @@ static void ffmpeg_postprocess(struct anim *anim)
                int *dstStride   = anim->pFrameRGB->linesize;
                uint8_t **dst     = anim->pFrameRGB->data;
                int dstStride2[4] = { -dstStride[0], 0, 0, 0 };
-               uint8_t *dst2[4]  = { dst[0] + (anim->y - 1) * dstStride[0],
-                                         0, 0, 0 };
+               uint8_t *dst2[4]  = { dst[0] + (anim->y - 1) * dstStride[0], 0, 0, 0 };
 
                sws_scale(anim->img_convert_ctx,
                          (const uint8_t *const *)input->data,
@@ -885,13 +884,13 @@ static int ffmpeg_decode_video_frame(struct anim *anim)
                anim->pFrameComplete = 0;
 
                avcodec_decode_video2(
-                       anim->pCodecCtx,
-                       anim->pFrame, &anim->pFrameComplete,
-                       &anim->next_packet);
+                       anim->pCodecCtx,
+                       anim->pFrame, &anim->pFrameComplete,
+                       &anim->next_packet);
 
                if (anim->pFrameComplete) {
                        anim->next_pts = av_get_pts_from_frame(
-                               anim->pFormatCtx, anim->pFrame);
+                               anim->pFormatCtx, anim->pFrame);
 
                        av_log(anim->pFormatCtx,
                               AV_LOG_DEBUG,
index d9f1c92..b3e08ba 100644 (file)
@@ -183,7 +183,7 @@ LogImageFile *cineonOpen(const unsigned char *byteStuff, int fromMemory, size_t
        }
        else {
                if (verbose) printf("Cineon: Bad magic number %lu in \"%s\".\n",
-                                       (unsigned long)header.fileHeader.magic_num, byteStuff);
+                                   (unsigned long)header.fileHeader.magic_num, byteStuff);
                logImageClose(cineon);
                return NULL;
        }
index 5d88acd..6de3cab 100644 (file)
@@ -879,11 +879,11 @@ static void index_rebuild_ffmpeg_proc_decoded_frame(
                                tc_frameno = context->frameno_gapless;
 
                        IMB_index_builder_proc_frame(
-                               context->indexer[i],
-                               curr_packet->data,
-                               curr_packet->size,
-                               tc_frameno,
-                               s_pos, s_dts, pts);
+                               context->indexer[i],
+                               curr_packet->data,
+                               curr_packet->size,
+                               tc_frameno,
+                               s_pos, s_dts, pts);
                }
        }
 
@@ -937,7 +937,7 @@ static int index_rebuild_ffmpeg(FFmpegIndexBuilderContext *context,
 
                if (frame_finished) {
                        index_rebuild_ffmpeg_proc_decoded_frame(
-                               context, &next_packet, in_frame);
+                               context, &next_packet, in_frame);
                }
                av_free_packet(&next_packet);
        }
@@ -957,12 +957,12 @@ static int index_rebuild_ffmpeg(FFmpegIndexBuilderContext *context,
                        frame_finished = 0;
 
                        avcodec_decode_video2(
-                               context->iCodecCtx, in_frame, &frame_finished,
-                               &next_packet);
+                               context->iCodecCtx, in_frame, &frame_finished,
+                               &next_packet);
 
                        if (frame_finished) {
                                index_rebuild_ffmpeg_proc_decoded_frame(
-                                       context, &next_packet, in_frame);
+                                       context, &next_packet, in_frame);
                        }
                } while (frame_finished);
        }
index aba1f08..b14e97b 100644 (file)
@@ -1051,9 +1051,10 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "angle", PROP_FLOAT, PROP_ANGLE);
        RNA_def_property_float_sdna(prop, NULL, "draw_angle");
        RNA_def_property_range(prop, -M_PI_2, M_PI_2);
-       RNA_def_property_ui_text(prop, "Angle",
-               "Direction of the stroke at which brush gives maximal thickness "
-               "(0° for horizontal)");
+       RNA_def_property_ui_text(
+               prop, "Angle",
+               "Direction of the stroke at which brush gives maximal thickness "
+               "(0° for horizontal)");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1061,8 +1062,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "angle_factor", PROP_FLOAT, PROP_FACTOR);
        RNA_def_property_float_sdna(prop, NULL, "draw_angle_factor");
        RNA_def_property_range(prop, 0.0f, 1.0f);
-       RNA_def_property_ui_text(prop, "Angle Factor",
-               "Reduce brush thickness by this factor when stroke is perpendicular to 'Angle' direction");
+       RNA_def_property_ui_text(
+               prop, "Angle Factor",
+               "Reduce brush thickness by this factor when stroke is perpendicular to 'Angle' direction");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1070,8 +1072,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "pen_smooth_factor", PROP_FLOAT, PROP_NONE);
        RNA_def_property_float_sdna(prop, NULL, "draw_smoothfac");
        RNA_def_property_range(prop, 0.0, 2.0f);
-       RNA_def_property_ui_text(prop, "Smooth",
-               "Amount of smoothing to apply after finish newly created strokes, to reduce jitter/noise");
+       RNA_def_property_ui_text(
+               prop, "Smooth",
+               "Amount of smoothing to apply after finish newly created strokes, to reduce jitter/noise");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1079,8 +1082,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "pen_smooth_steps", PROP_INT, PROP_NONE);
        RNA_def_property_int_sdna(prop, NULL, "draw_smoothlvl");
        RNA_def_property_range(prop, 1, 3);
-       RNA_def_property_ui_text(prop, "Iterations",
-               "Number of times to smooth newly created strokes");
+       RNA_def_property_ui_text(
+               prop, "Iterations",
+               "Number of times to smooth newly created strokes");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1088,8 +1092,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "pen_thick_smooth_factor", PROP_FLOAT, PROP_NONE);
        RNA_def_property_float_sdna(prop, NULL, "thick_smoothfac");
        RNA_def_property_range(prop, 0.0, 2.0f);
-       RNA_def_property_ui_text(prop, "Smooth Thickness",
-               "Amount of thickness smoothing to apply after finish newly created strokes, to reduce jitter/noise");
+       RNA_def_property_ui_text(
+               prop, "Smooth Thickness",
+               "Amount of thickness smoothing to apply after finish newly created strokes, to reduce jitter/noise");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1097,8 +1102,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "pen_thick_smooth_steps", PROP_INT, PROP_NONE);
        RNA_def_property_int_sdna(prop, NULL, "thick_smoothlvl");
        RNA_def_property_range(prop, 1, 3);
-       RNA_def_property_ui_text(prop, "Iterations Thickness",
-               "Number of times to smooth thickness for newly created strokes");
+       RNA_def_property_ui_text(
+               prop, "Iterations Thickness",
+               "Number of times to smooth thickness for newly created strokes");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1106,8 +1112,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "pen_subdivision_steps", PROP_INT, PROP_NONE);
        RNA_def_property_int_sdna(prop, NULL, "draw_subdivide");
        RNA_def_property_range(prop, 0, 3);
-       RNA_def_property_ui_text(prop, "Subdivision Steps",
-               "Number of times to subdivide newly created strokes, for less jagged strokes");
+       RNA_def_property_ui_text(
+               prop, "Subdivision Steps",
+               "Number of times to subdivide newly created strokes, for less jagged strokes");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1137,8 +1144,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "fill_threshold", PROP_FLOAT, PROP_FACTOR);
        RNA_def_property_float_sdna(prop, NULL, "fill_threshold");
        RNA_def_property_range(prop, 0.0f, 1.0f);
-       RNA_def_property_ui_text(prop, "Threshold",
-               "Threshold to consider color transparent for filling");
+       RNA_def_property_ui_text(
+               prop, "Threshold",
+               "Threshold to consider color transparent for filling");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1146,8 +1154,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "fill_leak", PROP_INT, PROP_PIXEL);
        RNA_def_property_int_sdna(prop, NULL, "fill_leak");
        RNA_def_property_range(prop, 0, 100);
-       RNA_def_property_ui_text(prop, "Leak Size",
-               "Size in pixels to consider the leak closed");
+       RNA_def_property_ui_text(
+               prop, "Leak Size",
+               "Size in pixels to consider the leak closed");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1155,8 +1164,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "fill_simplify_level", PROP_INT, PROP_NONE);
        RNA_def_property_int_sdna(prop, NULL, "fill_simplylvl");
        RNA_def_property_range(prop, 0, 10);
-       RNA_def_property_ui_text(prop, "Simplify",
-               "Number of simplify steps (large values reduce fill accuracy)");
+       RNA_def_property_ui_text(
+               prop, "Simplify",
+               "Number of simplify steps (large values reduce fill accuracy)");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1178,8 +1188,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "active_smooth_factor", PROP_FLOAT, PROP_FACTOR);
        RNA_def_property_float_sdna(prop, NULL, "active_smooth");
        RNA_def_property_range(prop, 0.0f, 1.0f);
-       RNA_def_property_ui_text(prop, "Active Smooth",
-               "Amount of smoothing while drawing ");
+       RNA_def_property_ui_text(
+               prop, "Active Smooth",
+               "Amount of smoothing while drawing ");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1187,8 +1198,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        RNA_def_property_float_sdna(prop, NULL, "era_strength_f");
        RNA_def_property_range(prop, 0.0, 100.0);
        RNA_def_property_ui_range(prop, 0.0, 100.0, 10, 1);
-       RNA_def_property_ui_text(prop, "Affect Stroke Strength",
-               "Amount of erasing for strength ");
+       RNA_def_property_ui_text(
+               prop, "Affect Stroke Strength",
+               "Amount of erasing for strength ");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1196,8 +1208,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        RNA_def_property_float_sdna(prop, NULL, "era_thickness_f");
        RNA_def_property_range(prop, 0.0, 100.0);
        RNA_def_property_ui_range(prop, 0.0, 100.0, 10, 1);
-       RNA_def_property_ui_text(prop, "Affect Stroke Thickness",
-               "Amount of erasing for thickness ");
+       RNA_def_property_ui_text(
+               prop, "Affect Stroke Thickness",
+               "Amount of erasing for thickness ");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
@@ -1233,8 +1246,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
        prop = RNA_def_property(srna, "use_settings_stabilizer", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flag", GP_BRUSH_STABILIZE_MOUSE);
        RNA_def_property_boolean_default(prop, true);
-       RNA_def_property_ui_text(prop, "Use Stabilizer",
-               "Draw lines with a delay to allow smooth strokes. Press Shift key to override while drawing");
+       RNA_def_property_ui_text(
+               prop, "Use Stabilizer",
+               "Draw lines with a delay to allow smooth strokes. Press Shift key to override while drawing");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
 
        prop = RNA_def_property(srna, "use_cursor", PROP_BOOLEAN, PROP_NONE);
@@ -1314,8 +1328,9 @@ static void rna_def_gpencil_options(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "use_occlude_eraser", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_negative_sdna(prop, NULL, "flag", GP_BRUSH_OCCLUDE_ERASER);
-       RNA_def_property_ui_text(prop, "Occlude Eraser",
-               "Erase only strokes visible and not occluded");
+       RNA_def_property_ui_text(
+               prop, "Occlude Eraser",
+               "Erase only strokes visible and not occluded");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
 }
 
index 6203d06..7c8a79a 100644 (file)
@@ -505,12 +505,14 @@ static void rna_GPencil_stroke_point_add(ID *id, bGPDstroke *stroke, int count,
 
        if (count > 0) {
                /* create space at the end of the array for extra points */
-               stroke->points = MEM_recallocN_id(stroke->points,
-                       sizeof(bGPDspoint) * (stroke->totpoints + count),
-                       "gp_stroke_points");
-               stroke->dvert = MEM_recallocN_id(stroke->dvert,
-                       sizeof(MDeformVert) * (stroke->totpoints + count),
-                       "gp_stroke_weight");
+               stroke->points = MEM_recallocN_id(
+                       stroke->points,
+                       sizeof(bGPDspoint) * (stroke->totpoints + count),
+                       "gp_stroke_points");
+               stroke->dvert = MEM_recallocN_id(
+                       stroke->dvert,
+                       sizeof(MDeformVert) * (stroke->totpoints + count),
+                       "gp_stroke_weight");
 
                /* init the pressure and strength values so that old scripts won't need to
                 * be modified to give these initial values...
@@ -931,8 +933,9 @@ static void rna_def_gpencil_stroke(BlenderRNA *brna)
 
        /* vertex groups */
        prop = RNA_def_property(srna, "groups", PROP_COLLECTION, PROP_NONE);
-       RNA_def_property_collection_funcs(prop, "rna_GpencilVertex_groups_begin", "rna_iterator_array_next",
-               "rna_iterator_array_end", "rna_iterator_array_get", NULL, NULL, NULL, NULL);
+       RNA_def_property_collection_funcs(
+               prop, "rna_GpencilVertex_groups_begin", "rna_iterator_array_next",
+               "rna_iterator_array_end", "rna_iterator_array_get", NULL, NULL, NULL, NULL);
        RNA_def_property_struct_type(prop, "GpencilVertexGroupElement");
        RNA_def_property_ui_text(prop, "Groups", "Weights for the vertex groups this vertex is member of");
 
@@ -1077,8 +1080,9 @@ static void rna_def_gpencil_frames_api(BlenderRNA *brna, PropertyRNA *cprop)
        func = RNA_def_function(srna, "new", "rna_GPencil_frame_new");
        RNA_def_function_ui_description(func, "Add a new grease pencil frame");
        RNA_def_function_flag(func, FUNC_USE_REPORTS);
-       parm = RNA_def_int(func, "frame_number", 1, MINAFRAME, MAXFRAME, "Frame Number",
-               "The frame on which this sketch appears", MINAFRAME, MAXFRAME);
+       parm = RNA_def_int(
+               func, "frame_number", 1, MINAFRAME, MAXFRAME, "Frame Number",
+               "The frame on which this sketch appears", MINAFRAME, MAXFRAME);
        RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
        parm = RNA_def_pointer(func, "frame", "GPencilFrame", "", "The newly created frame");
        RNA_def_function_return(func, parm);
@@ -1189,22 +1193,25 @@ static void rna_def_gpencil_layer(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "use_annotation_onion_skinning", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "onion_flag", GP_LAYER_ONIONSKIN);
-       RNA_def_property_ui_text(prop, "Onion Skinning",
-               "Display annotation onion skins before and after the current frame");
+       RNA_def_property_ui_text(
+               prop, "Onion Skinning",
+               "Display annotation onion skins before and after the current frame");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        prop = RNA_def_property(srna, "annotation_onion_before_range", PROP_INT, PROP_NONE);
        RNA_def_property_int_sdna(prop, NULL, "gstep");
        RNA_def_property_range(prop, -1, 120);
-       RNA_def_property_ui_text(prop, "Frames Before",
-               "Maximum number of frames to show before current frame");
+       RNA_def_property_ui_text(
+               prop, "Frames Before",
+               "Maximum number of frames to show before current frame");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        prop = RNA_def_property(srna, "annotation_onion_after_range", PROP_INT, PROP_NONE);
        RNA_def_property_int_sdna(prop, NULL, "gstep_next");
        RNA_def_property_range(prop, -1, 120);
-       RNA_def_property_ui_text(prop, "Frames After",
-               "Maximum number of frames to show after current frame");
+       RNA_def_property_ui_text(
+               prop, "Frames After",
+               "Maximum number of frames to show after current frame");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        prop = RNA_def_property(srna, "annotation_onion_before_color", PROP_FLOAT, PROP_COLOR_GAMMA);
@@ -1231,8 +1238,9 @@ static void rna_def_gpencil_layer(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "viewlayer_render", PROP_STRING, PROP_NONE);
        RNA_def_property_string_sdna(prop, NULL, "viewlayername");
-       RNA_def_property_ui_text(prop, "ViewLayer",
-               "Only include Layer in this View Layer render output (leave blank to include always)");
+       RNA_def_property_ui_text(
+               prop, "ViewLayer",
+               "Only include Layer in this View Layer render output (leave blank to include always)");
 
        /* blend mode */
        prop = RNA_def_property(srna, "blend_mode", PROP_ENUM, PROP_NONE);
@@ -1269,15 +1277,17 @@ static void rna_def_gpencil_layer(BlenderRNA *brna)
        prop = RNA_def_property(srna, "clamp_layer", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flag", GP_LAYER_USE_MASK);
        RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
-       RNA_def_property_ui_text(prop, "Clamp Layer",
-               "Clamp any pixel outside underlying layers drawing");
+       RNA_def_property_ui_text(
+               prop, "Clamp Layer",
+               "Clamp any pixel outside underlying layers drawing");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL);
 
        /* solo mode: Only display frames with keyframe */
        prop = RNA_def_property(srna, "use_solo_mode", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flag", GP_LAYER_SOLO_MODE);
-       RNA_def_property_ui_text(prop, "Solo Mode",
-               "In Paint mode display only layers with keyframe in current frame");
+       RNA_def_property_ui_text(
+               prop, "Solo Mode",
+               "In Paint mode display only layers with keyframe in current frame");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        /* exposed as layers.active */
@@ -1392,20 +1402,20 @@ static void rna_def_gpencil_layers_api(BlenderRNA *brna, PropertyRNA *cprop)
 
        prop = RNA_def_property(srna, "active_index", PROP_INT, PROP_UNSIGNED);
        RNA_def_property_int_funcs(
-               prop,
-               "rna_GPencil_active_layer_index_get",
-               "rna_GPencil_active_layer_index_set",
-               "rna_GPencil_active_layer_index_range");
+               prop,
+               "rna_GPencil_active_layer_index_get",
+               "rna_GPencil_active_layer_index_set",
+               "rna_GPencil_active_layer_index_range");
        RNA_def_property_ui_text(prop, "Active Layer Index", "Index of active grease pencil layer");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA | NA_SELECTED, NULL);
 
        /* Active Layer - As an enum (for selecting active layer for annotations) */
        prop = RNA_def_property(srna, "active_note", PROP_ENUM, PROP_NONE);
        RNA_def_property_enum_funcs(
-               prop,
-               "rna_GPencil_active_layer_index_get",
-               "rna_GPencil_active_layer_index_set",
-               "rna_GPencil_active_layer_itemf");
+               prop,
+               "rna_GPencil_active_layer_index_get",
+               "rna_GPencil_active_layer_index_set",
+               "rna_GPencil_active_layer_itemf");
        RNA_def_property_enum_items(prop, DummyRNA_DEFAULT_items); /* purely dynamic, as it maps to user-data */
        RNA_def_property_ui_text(prop, "Active Note", "Note/Layer to add annotation strokes to");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
@@ -1423,8 +1433,9 @@ static void rna_def_gpencil_grid(BlenderRNA *brna)
        RNA_def_struct_nested(brna, srna, "GreasePencil");
 
        RNA_def_struct_path_func(srna, "rna_GreasePencilGrid_path");
-       RNA_def_struct_ui_text(srna, "Grid and Canvas Settings",
-               "Settings for grid and canvas in 3D viewport");
+       RNA_def_struct_ui_text(
+               srna, "Grid and Canvas Settings",
+               "Settings for grid and canvas in 3D viewport");
 
        prop = RNA_def_property(srna, "scale", PROP_FLOAT, PROP_XYZ);
        RNA_def_property_float_sdna(prop, NULL, "scale");
@@ -1499,8 +1510,9 @@ static void rna_def_gpencil_data(BlenderRNA *brna)
        prop = RNA_def_property(srna, "stroke_depth_order", PROP_ENUM, PROP_NONE);
        RNA_def_property_enum_sdna(prop, NULL, "draw_mode");
        RNA_def_property_enum_items(prop, rna_enum_gpencil_stroke_depth_order_items);
-       RNA_def_property_ui_text(prop, "Stroke Depth Order",
-               "Defines how the strokes are ordered in 3D space");
+       RNA_def_property_ui_text(
+               prop, "Stroke Depth Order",
+               "Defines how the strokes are ordered in 3D space");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        /* Flags */
@@ -1569,8 +1581,9 @@ static void rna_def_gpencil_data(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "use_autolock_layers", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flag", GP_DATA_AUTOLOCK_LAYERS);
-       RNA_def_property_ui_text(prop, "Autolock Layers",
-               "Lock automatically all layers except active one to avoid accidental changes");
+       RNA_def_property_ui_text(
+               prop, "Autolock Layers",
+               "Lock automatically all layers except active one to avoid accidental changes");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_autolock");
 
        prop = RNA_def_property(srna, "edit_line_color", PROP_FLOAT, PROP_COLOR_GAMMA);
@@ -1586,18 +1599,20 @@ static void rna_def_gpencil_data(BlenderRNA *brna)
        RNA_def_property_int_sdna(prop, NULL, "gstep");
        RNA_def_property_range(prop, 0, 120);
        RNA_def_property_int_default(prop, 1);
-       RNA_def_property_ui_text(prop, "Frames Before",
-               "Maximum number of frames to show before current frame "
-               "(0 = don't show any frames before current)");
+       RNA_def_property_ui_text(
+               prop, "Frames Before",
+               "Maximum number of frames to show before current frame "
+               "(0 = don't show any frames before current)");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        prop = RNA_def_property(srna, "ghost_after_range", PROP_INT, PROP_NONE);
        RNA_def_property_int_sdna(prop, NULL, "gstep_next");
        RNA_def_property_range(prop, 0, 120);
        RNA_def_property_int_default(prop, 1);
-       RNA_def_property_ui_text(prop, "Frames After",
-               "Maximum number of frames to show after current frame "
-               "(0 = don't show any frames after current)");
+       RNA_def_property_ui_text(
+               prop, "Frames After",
+               "Maximum number of frames to show after current frame "
+               "(0 = don't show any frames after current)");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        prop = RNA_def_property(srna, "use_ghost_custom_colors", PROP_BOOLEAN, PROP_NONE);
@@ -1623,8 +1638,9 @@ static void rna_def_gpencil_data(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "use_ghosts_always", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "onion_flag", GP_ONION_GHOST_ALWAYS);
-       RNA_def_property_ui_text(prop, "Always Show Ghosts",
-               "Ghosts are shown in renders and animation playback. Useful for special effects (e.g. motion blur)");
+       RNA_def_property_ui_text(
+               prop, "Always Show Ghosts",
+               "Ghosts are shown in renders and animation playback. Useful for special effects (e.g. motion blur)");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        prop = RNA_def_property(srna, "onion_mode", PROP_ENUM, PROP_NONE);
@@ -1635,14 +1651,16 @@ static void rna_def_gpencil_data(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "use_onion_fade", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "onion_flag", GP_ONION_FADE);
-       RNA_def_property_ui_text(prop, "Fade",
-               "Display onion keyframes with a fade in color transparency");
+       RNA_def_property_ui_text(
+               prop, "Fade",
+               "Display onion keyframes with a fade in color transparency");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        prop = RNA_def_property(srna, "use_onion_loop", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "onion_flag", GP_ONION_LOOP);
-       RNA_def_property_ui_text(prop, "Loop",
-               "Display first onion keyframes using next frame color to show indication of loop start frame");
+       RNA_def_property_ui_text(
+               prop, "Loop",
+               "Display first onion keyframes using next frame color to show indication of loop start frame");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        prop = RNA_def_property(srna, "onion_factor", PROP_FLOAT, PROP_NONE);
@@ -1656,8 +1674,9 @@ static void rna_def_gpencil_data(BlenderRNA *brna)
        RNA_def_property_float_sdna(prop, NULL, "zdepth_offset");
        RNA_def_property_range(prop, 0.0f, 1.0f);
        RNA_def_property_ui_range(prop, 0.0f, 1.0f, 0.001, 5);
-       RNA_def_property_ui_text(prop, "Surface Offset",
-               "Offset amount when drawing in surface mode");
+       RNA_def_property_ui_text(
+               prop, "Surface Offset",
+               "Offset amount when drawing in surface mode");
        RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, "rna_GPencil_update");
 
        /* Nested Structs */
index 1787642..f0be1a2 100644 (file)
@@ -892,8 +892,9 @@ static void rna_def_modifier_gpenciltime(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "use_custom_frame_range", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flag", GP_TIME_CUSTOM_RANGE);
-       RNA_def_property_ui_text(prop, "Custom Range",
-               "Define a custom range of frames to use in modifier");
+       RNA_def_property_ui_text(
+               prop, "Custom Range",
+               "Define a custom range of frames to use in modifier");
        RNA_def_property_update(prop, 0, "rna_GpencilModifier_update");
 }
 
@@ -1071,9 +1072,10 @@ static void rna_def_modifier_gpencilinstance(BlenderRNA *brna)
        /* Offset parameters */
        prop = RNA_def_property(srna, "offset_object", PROP_POINTER, PROP_NONE);
        RNA_def_property_pointer_sdna(prop, NULL, "object");
-       RNA_def_property_ui_text(prop, "Object Offset",
-               "Use the location and rotation of another object to determine the distance and "
-               "rotational change between arrayed items");
+       RNA_def_property_ui_text(
+               prop, "Object Offset",
+               "Use the location and rotation of another object to determine the distance and "
+               "rotational change between arrayed items");
        RNA_def_property_flag(prop, PROP_EDITABLE | PROP_ID_SELF_CHECK);
        RNA_def_property_update(prop, 0, "rna_GpencilModifier_dependency_update");
 
@@ -1152,8 +1154,9 @@ static void rna_def_modifier_gpencilinstance(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "keep_on_top", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flag", GP_ARRAY_KEEP_ONTOP);
-       RNA_def_property_ui_text(prop, "Keep On Top",
-               "Keep the original stroke in front of new instances (only affect by layer)");
+       RNA_def_property_ui_text(
+               prop, "Keep On Top",
+               "Keep the original stroke in front of new instances (only affect by layer)");
        RNA_def_property_update(prop, 0, "rna_GpencilModifier_update");
 }
 
@@ -1431,8 +1434,9 @@ static void rna_def_modifier_gpencilhook(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "subtarget", PROP_STRING, PROP_NONE);
        RNA_def_property_string_sdna(prop, NULL, "subtarget");
-       RNA_def_property_ui_text(prop, "Sub-Target",
-               "Name of Parent Bone for hook (if applicable), also recalculates and clears offset");
+       RNA_def_property_ui_text(
+               prop, "Sub-Target",
+               "Name of Parent Bone for hook (if applicable), also recalculates and clears offset");
        RNA_def_property_update(prop, 0, "rna_GpencilModifier_dependency_update");
 
        prop = RNA_def_property(srna, "layer", PROP_STRING, PROP_NONE);
@@ -1554,15 +1558,17 @@ static void rna_def_modifier_gpencilarmature(BlenderRNA *brna)
 #if 0 /* GPXX keep disabled now */
        prop = RNA_def_property(srna, "use_multi_modifier", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "multi", 0);
-       RNA_def_property_ui_text(prop, "Multi Modifier",
-               "Use same input as previous modifier, and mix results using overall vgroup");
+       RNA_def_property_ui_text(
+               prop, "Multi Modifier",
+               "Use same input as previous modifier, and mix results using overall vgroup");
        RNA_def_property_update(prop, 0, "rna_GpencilModifier_dependency_update");
 #endif
 
        prop = RNA_def_property(srna, "vertex_group", PROP_STRING, PROP_NONE);
        RNA_def_property_string_sdna(prop, NULL, "vgname");
-       RNA_def_property_ui_text(prop, "Vertex Group",
-               "Name of Vertex Group which determines influence of modifier per point");
+       RNA_def_property_ui_text(
+               prop, "Vertex Group",
+               "Name of Vertex Group which determines influence of modifier per point");
        RNA_def_property_string_funcs(prop, NULL, NULL, "rna_ArmatureGpencilModifier_vgname_set");
        RNA_def_property_update(prop, 0, "rna_GpencilModifier_dependency_update");
 
index f9f9456..00dec55 100644 (file)
@@ -122,9 +122,9 @@ const EnumPropertyItem rna_enum_modifier_triangulate_quad_method_items[] = {
        {MOD_TRIANGULATE_QUAD_BEAUTY, "BEAUTY", 0, "Beauty ", "Split the quads in nice triangles, slower method"},
        {MOD_TRIANGULATE_QUAD_FIXED, "FIXED", 0, "Fixed", "Split the quads on the first and third vertices"},
        {MOD_TRIANGULATE_QUAD_ALTERNATE, "FIXED_ALTERNATE", 0, "Fixed Alternate",
-                                            "Split the quads on the 2nd and 4th vertices"},
+        "Split the quads on the 2nd and 4th vertices"},
        {MOD_TRIANGULATE_QUAD_SHORTEDGE, "SHORTEST_DIAGONAL", 0, "Shortest Diagonal",
-                                            "Split the quads based on the distance between the vertices"},
+        "Split the quads based on the distance between the vertices"},
        {0, NULL, 0, NULL, NULL},
 };
 
@@ -3043,7 +3043,7 @@ static void rna_def_modifier_bevel(BlenderRNA *brna)
                { MOD_BEVEL_FACE_STRENGTH_NONE, "FSTR_NONE", 0, "None", "Do not set face strength" },
                { MOD_BEVEL_FACE_STRENGTH_NEW, "FSTR_NEW", 0, "New", "Set face strength on new faces only" },
                { MOD_BEVEL_FACE_STRENGTH_AFFECTED, "FSTR_AFFECTED", 0, "Affected",
-                       "Set face strength on new and affected faces only" },
+                 "Set face strength on new and affected faces only" },
                { MOD_BEVEL_FACE_STRENGTH_ALL, "FSTR_ALL", 0, "All", "Set face strength on all faces" },
                { 0, NULL, 0, NULL, NULL },
        };
@@ -3144,8 +3144,9 @@ static void rna_def_modifier_bevel(BlenderRNA *brna)
 
        prop = RNA_def_property(srna, "harden_normals", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flags", MOD_BEVEL_HARDEN_NORMALS);
-       RNA_def_property_ui_text(prop, "Harden Normals",
-               "Match normals of new faces to adjacent faces");
+       RNA_def_property_ui_text(
+               prop, "Harden Normals",
+               "Match normals of new faces to adjacent faces");
        RNA_def_property_update(prop, 0, "rna_Modifier_update");
 
        prop = RNA_def_property(srna, "face_strength_mode", PROP_ENUM, PROP_NONE);
index 69ad550..01da2be 100644 (file)
@@ -4145,19 +4145,19 @@ static void def_sh_tex_pointdensity(StructRNA *srna)
 
        static const EnumPropertyItem particle_color_source_items[] = {
                {SHD_POINTDENSITY_COLOR_PARTAGE, "PARTICLE_AGE", 0, "Particle Age",
-                                                "Lifetime mapped as 0.0 - 1.0 intensity"},
+                "Lifetime mapped as 0.0 - 1.0 intensity"},
                {SHD_POINTDENSITY_COLOR_PARTSPEED, "PARTICLE_SPEED", 0, "Particle Speed",
-                                                  "Particle speed (absolute magnitude of velocity) mapped as 0.0-1.0 intensity"},
+                "Particle speed (absolute magnitude of velocity) mapped as 0.0-1.0 intensity"},
                {SHD_POINTDENSITY_COLOR_PARTVEL, "PARTICLE_VELOCITY", 0, "Particle Velocity",
-                                                "XYZ velocity mapped to RGB colors"},
+                "XYZ velocity mapped to RGB colors"},
                {0, NULL, 0, NULL, NULL},
        };
 
        static const EnumPropertyItem vertex_color_source_items[] = {
-           {SHD_POINTDENSITY_COLOR_VERTCOL, "VERTEX_COLOR", 0, "Vertex Color", "Vertex color layer"},
-           {SHD_POINTDENSITY_COLOR_VERTWEIGHT, "VERTEX_WEIGHT", 0, "Vertex Weight", "Vertex group weight"},
-           {SHD_POINTDENSITY_COLOR_VERTNOR, "VERTEX_NORMAL", 0, "Vertex Normal",
-                                            "XYZ normal vector mapped to RGB colors"},
+               {SHD_POINTDENSITY_COLOR_VERTCOL, "VERTEX_COLOR", 0, "Vertex Color", "Vertex color layer"},
+               {SHD_POINTDENSITY_COLOR_VERTWEIGHT, "VERTEX_WEIGHT", 0, "Vertex Weight", "Vertex group weight"},
+               {SHD_POINTDENSITY_COLOR_VERTNOR, "VERTEX_NORMAL", 0, "Vertex Normal",
+                "XYZ normal vector mapped to RGB colors"},
                {0, NULL, 0, NULL, NULL},
        };
 
index d25c2ab..725f9ed 100644 (file)
@@ -2729,21 +2729,24 @@ static void rna_def_tool_settings(BlenderRNA  *brna)
 
        prop = RNA_def_property(srna, "use_gpencil_draw_onback", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "gpencil_flags", GP_TOOL_FLAG_PAINT_ONBACK);
-       RNA_def_property_ui_text(prop, "Draw Strokes on Back",
-               "When draw new strokes, the new stroke is drawn below of all strokes in the layer");
+       RNA_def_property_ui_text(
+               prop, "Draw Strokes on Back",
+               "When draw new strokes, the new stroke is drawn below of all strokes in the layer");
        RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);
 
        prop = RNA_def_property(srna, "use_gpencil_thumbnail_list", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_negative_sdna(prop, NULL, "gpencil_flags", GP_TOOL_FLAG_THUMBNAIL_LIST);
-       RNA_def_property_ui_text(prop, "Compact List",
-               "Show compact list of color instead of thumbnails");
+       RNA_def_property_ui_text(
+               prop, "Compact List",
+               "Show compact list of color instead of thumbnails");
        RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);
 
        prop = RNA_def_property(srna, "use_gpencil_weight_data_add", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "gpencil_flags", GP_TOOL_FLAG_CREATE_WEIGHTS);
-       RNA_def_property_ui_text(prop, "Add weight data for new strokes",
-               "When creating new strokes, the weight data is added according to the current vertex group and weight, "
-               "if no vertex group selected, weight is not added");
+       RNA_def_property_ui_text(
+               prop, "Add weight data for new strokes",
+               "When creating new strokes, the weight data is added according to the current vertex group and weight, "
+               "if no vertex group selected, weight is not added");
        RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);
 
        prop = RNA_def_property(srna, "gpencil_sculpt", PROP_POINTER, PROP_NONE);
index d1fdd22..1393a9d 100644 (file)
@@ -1370,8 +1370,9 @@ static void rna_def_gpencil_sculpt(BlenderRNA *brna)
        prop = RNA_def_property(srna, "multiframe_falloff_curve", PROP_POINTER, PROP_NONE);
        RNA_def_property_pointer_sdna(prop, NULL, "cur_falloff");
        RNA_def_property_struct_type(prop, "CurveMapping");
-       RNA_def_property_ui_text(prop, "Curve",
-               "Custom curve to control falloff of brush effect by Grease Pencil frames");
+       RNA_def_property_ui_text(
+               prop, "Curve",
+               "Custom curve to control falloff of brush effect by Grease Pencil frames");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);
 
@@ -1379,8 +1380,9 @@ static void rna_def_gpencil_sculpt(BlenderRNA *brna)
        prop = RNA_def_property(srna, "thickness_primitive_curve", PROP_POINTER, PROP_NONE);
        RNA_def_property_pointer_sdna(prop, NULL, "cur_primitive");
        RNA_def_property_struct_type(prop, "CurveMapping");
-       RNA_def_property_ui_text(prop, "Curve",
-               "Custom curve to control primitive thickness");
+       RNA_def_property_ui_text(
+               prop, "Curve",
+               "Custom curve to control primitive thickness");
        RNA_def_parameter_clear_flags(prop, PROP_ANIMATABLE, 0);
        RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);
 
index d6c78fd..f827615 100644 (file)
@@ -2974,26 +2974,30 @@ static void rna_def_space_view3d_overlay(BlenderRNA *brna)
        /* grease pencil paper settings */
        prop = RNA_def_property(srna, "show_annotation", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flag2", V3D_SHOW_ANNOTATION);
-       RNA_def_property_ui_text(prop, "Show Annotation",
-               "Show annotations for this view");
+       RNA_def_property_ui_text(
+               prop, "Show Annotation",
+               "Show annotations for this view");
        RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL);
 
        prop = RNA_def_property(srna, "use_gpencil_paper", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "gp_flag", V3D_GP_SHOW_PAPER);
-       RNA_def_property_ui_text(prop, "Use Paper",
-               "Cover all viewport with a full color layer to improve visibility while drawing over complex scenes");
+       RNA_def_property_ui_text(
+               prop, "Use Paper",
+               "Cover all viewport with a full color layer to improve visibility while drawing over complex scenes");
        RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL);
 
        prop = RNA_def_property(srna, "use_gpencil_grid", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "gp_flag", V3D_GP_SHOW_GRID);
-       RNA_def_property_ui_text(prop, "Use Grid",
-               "Display a grid over grease pencil paper");
+       RNA_def_property_ui_text(
+               prop, "Use Grid",
+               "Display a grid over grease pencil paper");
        RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL);
 
        prop = RNA_def_property(srna, "use_gpencil_fade_layers", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "gp_flag", V3D_GP_FADE_NOACTIVE_LAYERS);
-       RNA_def_property_ui_text(prop, "Fade Layers",
-               "Toggle fading of Grease Pencil layers except the active one");
+       RNA_def_property_ui_text(
+               prop, "Fade Layers",
+               "Toggle fading of Grease Pencil layers except the active one");
        RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, "rna_GPencil_update");
 
        prop = RNA_def_property(srna, "gpencil_grid_opacity", PROP_FLOAT, PROP_NONE);
@@ -3016,8 +3020,9 @@ static void rna_def_space_view3d_overlay(BlenderRNA *brna)
        RNA_def_property_float_sdna(prop, NULL, "overlay.gpencil_fade_layer");
        RNA_def_property_range(prop, 0.0f, 1.0f);
        RNA_def_property_float_default(prop, 0.5f);
-       RNA_def_property_ui_text(prop, "Opacity",
-               "Fade layer opacity for Grease Pencil layers except the active one");
+       RNA_def_property_ui_text(
+               prop, "Opacity",
+               "Fade layer opacity for Grease Pencil layers except the active one");
        RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, "rna_GPencil_update");
 
        /* show edit lines */
@@ -4421,24 +4426,24 @@ static void rna_def_fileselect_params(BlenderRNA *brna)
        };
 
        static const EnumPropertyItem file_filter_idcategories_items[] = {
-           {FILTER_ID_SCE,
-            "SCENE", ICON_SCENE_DATA, "Scenes", "Show/hide scenes"},
-           {FILTER_ID_AC,
-            "ANIMATION", ICON_ANIM_DATA, "Animations", "Show/hide animation data"},
+               {FILTER_ID_SCE,
+                "SCENE", ICON_SCENE_DATA, "Scenes", "Show/hide scenes"},
+               {FILTER_ID_AC,
+                "ANIMATION", ICON_ANIM_DATA, "Animations", "Show/hide animation data"},
                {FILTER_ID_OB | FILTER_ID_GR,
-            "OBJECT", ICON_GROUP, "Objects & Collections", "Show/hide objects and groups"},
+                "OBJECT", ICON_GROUP, "Objects & Collections", "Show/hide objects and groups"},
                {FILTER_ID_AR | FILTER_ID_CU | FILTER_ID_LT | FILTER_ID_MB | FILTER_ID_ME,
-            "GEOMETRY", ICON_MESH_DATA, "Geometry", "Show/hide meshes, curves, lattice, armatures and metaballs data"},
+                "GEOMETRY", ICON_MESH_DATA, "Geometry", "Show/hide meshes, curves, lattice, armatures and metaballs data"},
                {FILTER_ID_LS | FILTER_ID_MA | FILTER_ID_NT | FILTER_ID_TE,
-            "SHADING", ICON_MATERIAL_DATA, "Shading",
-            "Show/hide materials, nodetrees, textures and Freestyle's linestyles"},
+                "SHADING", ICON_MATERIAL_DATA, "Shading",
+                "Show/hide materials, nodetrees, textures and Freestyle's linestyles"},
                {FILTER_ID_IM | FILTER_ID_MC | FILTER_ID_MSK | FILTER_ID_SO,
-            "IMAGE", ICON_IMAGE_DATA, "Images & Sounds", "Show/hide images, movie clips, sounds and masks"},
+                "IMAGE", ICON_IMAGE_DATA, "Images & Sounds", "Show/hide images, movie clips, sounds and masks"},
                {FILTER_ID_CA | FILTER_ID_LA | FILTER_ID_SPK | FILTER_ID_WO | FILTER_ID_WS,
-            "ENVIRONMENT", ICON_WORLD_DATA, "Environment", "Show/hide worlds, lights, cameras and speakers"},
+                "ENVIRONMENT", ICON_WORLD_DATA, "Environment", "Show/hide worlds, lights, cameras and speakers"},
                {FILTER_ID_BR | FILTER_ID_GD | FILTER_ID_PA | FILTER_ID_PAL | FILTER_ID_PC | FILTER_ID_TXT | FILTER_ID_VF | FILTER_ID_CF,
-            "MISC", ICON_GREASEPENCIL, "Miscellaneous", "Show/hide other data types"},
-           {0, NULL, 0, NULL, NULL},
+                "MISC", ICON_GREASEPENCIL, "Miscellaneous", "Show/hide other data types"},
+               {0, NULL, 0, NULL, NULL},
        };
 
        srna = RNA_def_struct(brna, "FileSelectParams", NULL);
index 046e68a..151b0b9 100644 (file)
@@ -770,9 +770,9 @@ void RNA_api_ui_layout(StructRNA *srna)
        func = RNA_def_function(srna, "separator", "uiItemS_ex");
        RNA_def_function_ui_description(func, "Item. Inserts empty space into the layout between items");
        RNA_def_float(
-               func, "factor", 1.0f, 0.0f, FLT_MAX, "Percentage",
-               "Percentage of width to space (leave unset for default space)",
-               0.0f, FLT_MAX);
+               func, "factor", 1.0f, 0.0f, FLT_MAX, "Percentage",
+               "Percentage of width to space (leave unset for default space)",
+               0.0f, FLT_MAX);
 
        func = RNA_def_function(srna, "separator_spacer", "uiItemSpacer");
        RNA_def_function_ui_description(func, "Item. Inserts horizontal spacing empty space into the layout between items");
@@ -892,8 +892,9 @@ void RNA_api_ui_layout(StructRNA *srna)
        RNA_def_int(func, "rows", 0, 0, INT_MAX, "Number of thumbnail preview rows to display", "", 0, INT_MAX);
        RNA_def_int(func, "cols", 0, 0, INT_MAX, "Number of thumbnail preview columns to display", "", 0, INT_MAX);
        RNA_def_float(func, "scale", 1.0f, 0.1f, 1.5f, "Scale of the image thumbnails", "", 0.5f, 1.0f);
-       RNA_def_enum(func, "filter", id_template_filter_items, UI_TEMPLATE_ID_FILTER_ALL,
-               "", "Optionally limit the items which can be selected");
+       RNA_def_enum(
+               func, "filter", id_template_filter_items, UI_TEMPLATE_ID_FILTER_ALL,
+               "", "Optionally limit the items which can be selected");
 
        func = RNA_def_function(srna, "template_constraint", "uiTemplateConstraint");
        RNA_def_function_ui_description(func, "Generates the UI layout for constraints");
index 7cd9dfa..97380a6 100644 (file)
@@ -99,7 +99,7 @@ static Mesh *multires_as_mesh(MultiresModifierData *mmd,
        Object *object = ctx->object;
        SubdivToMeshSettings mesh_settings;
        BKE_multires_subdiv_mesh_settings_init(
-        &mesh_settings, scene, object, mmd, use_render_params, ignore_simplify);
+               &mesh_settings, scene, object, mmd, use_render_params, ignore_simplify);
        if (mesh_settings.resolution < 3) {
                return result;
        }
index fb7d85c..2443213 100644 (file)
@@ -59,10 +59,12 @@ static void node_shader_exec_mix_rgb(void *UNUSED(data), int UNUSED(thread), bNo
 
 static int gpu_shader_mix_rgb(GPUMaterial *mat, bNode *node, bNodeExecData *UNUSED(execdata), GPUNodeStack *in, GPUNodeStack *out)
 {
-       static const char *names[] = {"mix_blend", "mix_add", "mix_mult", "mix_sub",
-                                         "mix_screen", "mix_div", "mix_diff", "mix_dark", "mix_light",
-                                         "mix_overlay", "mix_dodge", "mix_burn", "mix_hue", "mix_sat",
-                                         "mix_val", "mix_color", "mix_soft", "mix_linear"};
+       static const char *names[] = {
+               "mix_blend", "mix_add", "mix_mult", "mix_sub",
+               "mix_screen", "mix_div", "mix_diff", "mix_dark", "mix_light",
+               "mix_overlay", "mix_dodge", "mix_burn", "mix_hue", "mix_sat",
+               "mix_val", "mix_color", "mix_soft", "mix_linear",
+       };
 
        int ret = GPU_stack_link(mat, node, names[node->custom1], in, out);
        if (ret && node->custom2 & SHD_MIXRGB_CLAMP) {
index 673cb9d..bbb1f60 100644 (file)
@@ -50,8 +50,9 @@ static int node_shader_gpu_tangent(GPUMaterial *mat, bNode *node, bNodeExecData
                else
                        GPU_link(mat, "tangent_orco_z", orco, &orco);
 
-               return GPU_stack_link(mat, node, "node_tangent", in, out, GPU_builtin(GPU_VIEW_NORMAL), orco,
-                       GPU_builtin(GPU_OBJECT_MATRIX), GPU_builtin(GPU_INVERSE_VIEW_MATRIX));
+               return GPU_stack_link(
+                       mat, node, "node_tangent", in, out, GPU_builtin(GPU_VIEW_NORMAL), orco,
+                       GPU_builtin(GPU_OBJECT_MATRIX), GPU_builtin(GPU_INVERSE_VIEW_MATRIX));
        }
 }
 
index cd7a568..5d6c1b6 100644 (file)
@@ -93,9 +93,11 @@ static void node_shader_exec_vect_math(void *UNUSED(data), int UNUSED(thread), b
 
 static int gpu_shader_vect_math(GPUMaterial *mat, bNode *node, bNodeExecData *UNUSED(execdata), GPUNodeStack *in, GPUNodeStack *out)
 {
-       static const char *names[] = {"vec_math_add", "vec_math_sub",
+       static const char *names[] = {
+               "vec_math_add", "vec_math_sub",
                "vec_math_average", "vec_math_dot", "vec_math_cross",
-               "vec_math_normalize"};
+               "vec_math_normalize",
+       };
 
        switch (node->custom1) {
                case 0:
index b371b48..6b59a9e 100644 (file)
@@ -67,7 +67,7 @@ PyC_FlagSet bpy_bm_htype_vert_edge_face_flags[] = {
        {BM_VERT, "VERT"},
        {BM_EDGE, "EDGE"},
        {BM_FACE, "FACE"},
-               {0, NULL},
+       {0, NULL},
 };
 
 PyC_FlagSet bpy_bm_htype_all_flags[] = {
index 373a663..354d375 100644 (file)
@@ -465,10 +465,12 @@ static PyObject *C_Matrix_Rotation(PyObject *cls, PyObject *args)
        const char *axis = NULL;
        int matSize;
        double angle; /* use double because of precision problems at high values */
-       float mat[16] = {0.0f, 0.0f, 0.0f, 0.0f,
-                            0.0f, 0.0f, 0.0f, 0.0f,
-                            0.0f, 0.0f, 0.0f, 0.0f,
-                            0.0f, 0.0f, 0.0f, 1.0f};
+       float mat[16] = {
+               0.0f, 0.0f, 0.0f, 0.0f,
+               0.0f, 0.0f, 0.0f, 0.0f,
+               0.0f, 0.0f, 0.0f, 0.0f,
+               0.0f, 0.0f, 0.0f, 1.0f,
+       };
 
        if (!PyArg_ParseTuple(args, "di|O:Matrix.Rotation", &angle, &matSize, &vec)) {
                return NULL;
index 346d57e..a658a0e 100644 (file)
@@ -368,12 +368,12 @@ static bool cast_ray_highpoly(
 
                /* compute barycentric differentials from position differentials */
                barycentric_differentials_from_position(
-                       hits[hit_mesh].co, triangle_high->mverts[0]->co,
-                       triangle_high->mverts[1]->co, triangle_high->mverts[2]->co,
-                       dxco, dyco, triangle_high->normal, true,
-                       &pixel_high->uv[0], &pixel_high->uv[1],
-                       &pixel_high->du_dx, &pixel_high->dv_dx,
-                       &pixel_high->du_dy, &pixel_high->dv_dy);
+                       hits[hit_mesh].co, triangle_high->mverts[0]->co,
+                       triangle_high->mverts[1]->co, triangle_high->mverts[2]->co,
+                       dxco, dyco, triangle_high->normal, true,
+                       &pixel_high->uv[0], &pixel_high->uv[1],
+                       &pixel_high->du_dx, &pixel_high->dv_dx,
+                       &pixel_high->du_dy, &pixel_high->dv_dy);
 
                /* verify we have valid uvs */
                BLI_assert(pixel_high->uv[0] >= -1e-3f &&