Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <campbell@blender.org>2022-01-07 03:38:08 +0300
committerCampbell Barton <campbell@blender.org>2022-01-07 06:16:26 +0300
commit3d3bc748849834ef74563deb603ab43859cffeeb (patch)
treede74ce4722b2cb032c22dbc090a15dd2e172c29b /source/blender/editors
parentbb69c19f08ac681d4386325e4318ebfbef2e9531 (diff)
Cleanup: remove redundant const qualifiers for POD types
MSVC used to warn about const mismatch for arguments passed by value. Remove these as newer versions of MSVC no longer show this warning.
Diffstat (limited to 'source/blender/editors')
-rw-r--r--source/blender/editors/armature/armature_intern.h2
-rw-r--r--source/blender/editors/curve/curve_intern.h2
-rw-r--r--source/blender/editors/gizmo_library/gizmo_library_intern.h21
-rw-r--r--source/blender/editors/gpencil/gpencil_intern.h4
-rw-r--r--source/blender/editors/gpencil/gpencil_trace.h10
-rw-r--r--source/blender/editors/include/ED_armature.h26
-rw-r--r--source/blender/editors/include/ED_buttons.h4
-rw-r--r--source/blender/editors/include/ED_curve.h2
-rw-r--r--source/blender/editors/include/ED_file_indexer.h2
-rw-r--r--source/blender/editors/include/ED_fileselect.h8
-rw-r--r--source/blender/editors/include/ED_gizmo_library.h10
-rw-r--r--source/blender/editors/include/ED_gpencil.h38
-rw-r--r--source/blender/editors/include/ED_image.h10
-rw-r--r--source/blender/editors/include/ED_keyframes_edit.h4
-rw-r--r--source/blender/editors/include/ED_keyframes_keylist.h27
-rw-r--r--source/blender/editors/include/ED_keyframing.h12
-rw-r--r--source/blender/editors/include/ED_lattice.h2
-rw-r--r--source/blender/editors/include/ED_mask.h29
-rw-r--r--source/blender/editors/include/ED_mesh.h195
-rw-r--r--source/blender/editors/include/ED_numinput.h2
-rw-r--r--source/blender/editors/include/ED_object.h59
-rw-r--r--source/blender/editors/include/ED_particle.h9
-rw-r--r--source/blender/editors/include/ED_render.h8
-rw-r--r--source/blender/editors/include/ED_screen.h40
-rw-r--r--source/blender/editors/include/ED_sculpt.h2
-rw-r--r--source/blender/editors/include/ED_select_utils.h16
-rw-r--r--source/blender/editors/include/ED_transform.h12
-rw-r--r--source/blender/editors/include/ED_transform_snap_object_context.h4
-rw-r--r--source/blender/editors/include/ED_transverts.h2
-rw-r--r--source/blender/editors/include/ED_util.h2
-rw-r--r--source/blender/editors/include/ED_uvedit.h78
-rw-r--r--source/blender/editors/include/ED_view3d.h140
-rw-r--r--source/blender/editors/include/ED_view3d_offscreen.h8
-rw-r--r--source/blender/editors/include/UI_interface.h52
-rw-r--r--source/blender/editors/include/UI_interface.hh4
-rw-r--r--source/blender/editors/include/UI_interface_icons.h15
-rw-r--r--source/blender/editors/include/UI_resources.h2
-rw-r--r--source/blender/editors/include/UI_view2d.h4
-rw-r--r--source/blender/editors/interface/interface_eyedropper_intern.h2
-rw-r--r--source/blender/editors/interface/interface_intern.h44
-rw-r--r--source/blender/editors/mask/mask_intern.h12
-rw-r--r--source/blender/editors/mesh/mesh_intern.h8
-rw-r--r--source/blender/editors/object/object_intern.h4
-rw-r--r--source/blender/editors/screen/screen_intern.h25
-rw-r--r--source/blender/editors/sculpt_paint/paint_intern.h20
-rw-r--r--source/blender/editors/sculpt_paint/sculpt_intern.h123
-rw-r--r--source/blender/editors/space_clip/clip_intern.h2
-rw-r--r--source/blender/editors/space_file/file_intern.h4
-rw-r--r--source/blender/editors/space_file/filelist.h38
-rw-r--r--source/blender/editors/space_file/fsmenu.h2
-rw-r--r--source/blender/editors/space_info/textview.h2
-rw-r--r--source/blender/editors/space_node/node_intern.hh10
-rw-r--r--source/blender/editors/space_outliner/outliner_intern.h14
-rw-r--r--source/blender/editors/space_sequencer/sequencer_intern.h4
-rw-r--r--source/blender/editors/space_spreadsheet/spreadsheet_column.hh2
-rw-r--r--source/blender/editors/space_text/text_format.h6
-rw-r--r--source/blender/editors/space_text/text_intern.h2
-rw-r--r--source/blender/editors/space_view3d/view3d_intern.h16
-rw-r--r--source/blender/editors/transform/transform.h6
-rw-r--r--source/blender/editors/transform/transform_convert.h20
-rw-r--r--source/blender/editors/transform/transform_mode.h6
-rw-r--r--source/blender/editors/transform/transform_orientations.h8
-rw-r--r--source/blender/editors/transform/transform_snap.h10
-rw-r--r--source/blender/editors/uvedit/uvedit_intern.h20
64 files changed, 583 insertions, 694 deletions
diff --git a/source/blender/editors/armature/armature_intern.h b/source/blender/editors/armature/armature_intern.h
index 97f8c0cf630..252cf806e34 100644
--- a/source/blender/editors/armature/armature_intern.h
+++ b/source/blender/editors/armature/armature_intern.h
@@ -297,7 +297,7 @@ void armature_tag_select_mirrored(struct bArmature *arm);
* Helper function for tools to work on mirrored parts.
* it leaves mirrored bones selected then too, which is a good indication of what happened.
*/
-void armature_select_mirrored_ex(struct bArmature *arm, const int flag);
+void armature_select_mirrored_ex(struct bArmature *arm, int flag);
void armature_select_mirrored(struct bArmature *arm);
/** Only works when tagged. */
void armature_tag_unselect(struct bArmature *arm);
diff --git a/source/blender/editors/curve/curve_intern.h b/source/blender/editors/curve/curve_intern.h
index 03ddeebde42..0d17af1983d 100644
--- a/source/blender/editors/curve/curve_intern.h
+++ b/source/blender/editors/curve/curve_intern.h
@@ -155,7 +155,7 @@ void ed_editnurb_translate_flag(struct ListBase *editnurb,
/**
* Only for #OB_SURF.
*/
-bool ed_editnurb_extrude_flag(struct EditNurb *editnurb, const uint8_t flag);
+bool ed_editnurb_extrude_flag(struct EditNurb *editnurb, uint8_t flag);
/**
* \param axis: is in world-space.
* \param cent: is in object-space.
diff --git a/source/blender/editors/gizmo_library/gizmo_library_intern.h b/source/blender/editors/gizmo_library/gizmo_library_intern.h
index a75a6b9a6ef..4a481f4bc59 100644
--- a/source/blender/editors/gizmo_library/gizmo_library_intern.h
+++ b/source/blender/editors/gizmo_library/gizmo_library_intern.h
@@ -52,22 +52,19 @@ typedef struct GizmoInteraction {
float precision_offset;
} GizmoInteraction;
-float gizmo_offset_from_value(GizmoCommonData *data,
- const float value,
- const bool constrained,
- const bool inverted);
+float gizmo_offset_from_value(GizmoCommonData *data, float value, bool constrained, bool inverted);
float gizmo_value_from_offset(GizmoCommonData *data,
GizmoInteraction *inter,
- const float offset,
- const bool constrained,
- const bool inverted,
- const bool use_precision);
+ float offset,
+ bool constrained,
+ bool inverted,
+ bool use_precision);
void gizmo_property_data_update(struct wmGizmo *gz,
GizmoCommonData *data,
wmGizmoProperty *gz_prop,
- const bool constrained,
- const bool inverted);
+ bool constrained,
+ bool inverted);
void gizmo_property_value_reset(bContext *C,
const struct wmGizmo *gz,
@@ -76,7 +73,7 @@ void gizmo_property_value_reset(bContext *C,
/* -------------------------------------------------------------------- */
-void gizmo_color_get(const struct wmGizmo *gz, const bool highlight, float r_color[4]);
+void gizmo_color_get(const struct wmGizmo *gz, bool highlight, float r_color[4]);
/**
* Takes mouse coordinates and returns them in relation to the gizmo.
@@ -101,7 +98,7 @@ bool gizmo_window_project_3d(
* Main draw call for #GizmoGeomInfo data
*/
void wm_gizmo_geometryinfo_draw(const struct GizmoGeomInfo *info,
- const bool select,
+ bool select,
const float color[4]);
void wm_gizmo_vec_draw(
const float color[4], const float (*verts)[3], uint vert_count, uint pos, uint primitive_type);
diff --git a/source/blender/editors/gpencil/gpencil_intern.h b/source/blender/editors/gpencil/gpencil_intern.h
index 601780ea651..0802b806060 100644
--- a/source/blender/editors/gpencil/gpencil_intern.h
+++ b/source/blender/editors/gpencil/gpencil_intern.h
@@ -322,7 +322,7 @@ void gpencil_apply_parent_point(struct Depsgraph *depsgraph,
* generic based on gpencil_point_to_xy_fl
*/
void gpencil_point_3d_to_xy(const GP_SpaceConversion *gsc,
- const short flag,
+ short flag,
const float pt[3],
float xy[2]);
@@ -410,7 +410,7 @@ int gpencil_delete_selected_point_wrap(bContext *C);
* \param gps: Stroke data
* \param subdivide: Number of times to subdivide
*/
-void gpencil_subdivide_stroke(bGPdata *gpd, bGPDstroke *gps, const int subdivide);
+void gpencil_subdivide_stroke(bGPdata *gpd, bGPDstroke *gps, int subdivide);
/* Layers Enums -------------------------------------- */
diff --git a/source/blender/editors/gpencil/gpencil_trace.h b/source/blender/editors/gpencil/gpencil_trace.h
index 7c62288f65d..77fb823b3b6 100644
--- a/source/blender/editors/gpencil/gpencil_trace.h
+++ b/source/blender/editors/gpencil/gpencil_trace.h
@@ -91,7 +91,7 @@ void ED_gpencil_trace_bitmap_invert(const potrace_bitmap_t *bm);
*/
void ED_gpencil_trace_image_to_bitmap(struct ImBuf *ibuf,
const potrace_bitmap_t *bm,
- const float threshold);
+ float threshold);
/**
* Convert Potrace Bitmap to Grease Pencil strokes
@@ -106,7 +106,7 @@ void ED_gpencil_trace_data_to_strokes(struct Main *bmain,
struct Object *ob,
struct bGPDframe *gpf,
int32_t offset[2],
- const float scale,
- const float sample,
- const int32_t resolution,
- const int32_t thickness);
+ float scale,
+ float sample,
+ int32_t resolution,
+ int32_t thickness);
diff --git a/source/blender/editors/include/ED_armature.h b/source/blender/editors/include/ED_armature.h
index 0053bf5c865..7631bd35e79 100644
--- a/source/blender/editors/include/ED_armature.h
+++ b/source/blender/editors/include/ED_armature.h
@@ -94,7 +94,7 @@ struct EditBone *ED_armature_ebone_add_primitive(struct Object *obedit_arm,
*/
float ED_armature_ebone_roll_to_vector(const struct EditBone *bone,
const float align_axis[3],
- const bool axis_only);
+ bool axis_only);
/**
* \param centermode: 0 == do center, 1 == center new, 2 == center cursor.
*
@@ -105,8 +105,8 @@ void ED_armature_origin_set(
/**
* See #BKE_armature_transform for object-mode transform.
*/
-void ED_armature_edit_transform(struct bArmature *arm, const float mat[4][4], const bool do_props);
-void ED_armature_transform(struct bArmature *arm, const float mat[4][4], const bool do_props);
+void ED_armature_edit_transform(struct bArmature *arm, const float mat[4][4], bool do_props);
+void ED_armature_transform(struct bArmature *arm, const float mat[4][4], bool do_props);
/* armature_naming.c */
@@ -138,7 +138,7 @@ void ED_armature_bone_rename(struct Main *bmain,
void ED_armature_bones_flip_names(struct Main *bmain,
struct bArmature *arm,
struct ListBase *bones_names,
- const bool do_strip_numbers);
+ bool do_strip_numbers);
/* armature_ops.c */
@@ -203,7 +203,7 @@ bool ED_armature_edit_select_pick(
*
* \note Visibility checks must be done by the caller.
*/
-bool ED_armature_edit_select_op_from_tagged(struct bArmature *arm, const int sel_op);
+bool ED_armature_edit_select_op_from_tagged(struct bArmature *arm, int sel_op);
/* armature_skinning.c */
@@ -215,8 +215,8 @@ void ED_object_vgroup_calc_from_armature(struct ReportList *reports,
struct Scene *scene,
struct Object *ob,
struct Object *par,
- const int mode,
- const bool mirror);
+ int mode,
+ bool mirror);
/* editarmature_undo.c */
@@ -251,7 +251,7 @@ bool ED_armature_ebone_is_child_recursive(struct EditBone *ebone_parent,
* \return The shared parent or NULL.
*/
struct EditBone *ED_armature_ebone_find_shared_parent(struct EditBone *ebone_child[],
- const unsigned int ebone_child_tot);
+ unsigned int ebone_child_tot);
void ED_armature_ebone_to_mat3(struct EditBone *ebone, float r_mat[3][3]);
void ED_armature_ebone_to_mat4(struct EditBone *ebone, float r_mat[4][4]);
void ED_armature_ebone_from_mat3(struct EditBone *ebone, const float mat[3][3]);
@@ -282,10 +282,10 @@ void ED_armature_ebone_listbase_temp_clear(struct ListBase *lb);
/**
* Free's bones and their properties.
*/
-void ED_armature_ebone_listbase_free(struct ListBase *lb, const bool do_id_user);
+void ED_armature_ebone_listbase_free(struct ListBase *lb, bool do_id_user);
void ED_armature_ebone_listbase_copy(struct ListBase *lb_dst,
struct ListBase *lb_src,
- const bool do_id_user);
+ bool do_id_user);
int ED_armature_ebone_selectflag_get(const struct EditBone *ebone);
void ED_armature_ebone_selectflag_set(struct EditBone *ebone, int flag);
@@ -353,14 +353,14 @@ void ED_armature_pose_select_in_wpaint_mode(struct ViewLayer *view_layer,
bool ED_pose_deselect_all_multi_ex(struct Base **bases,
uint bases_len,
int select_mode,
- const bool ignore_visibility);
-bool ED_pose_deselect_all_multi(struct bContext *C, int select_mode, const bool ignore_visibility);
+ bool ignore_visibility);
+bool ED_pose_deselect_all_multi(struct bContext *C, int select_mode, bool ignore_visibility);
/**
* 'select_mode' is usual SEL_SELECT/SEL_DESELECT/SEL_TOGGLE/SEL_INVERT.
* When true, 'ignore_visibility' makes this func also affect invisible bones
* (hidden or on hidden layers).
*/
-bool ED_pose_deselect_all(struct Object *ob, int select_mode, const bool ignore_visibility);
+bool ED_pose_deselect_all(struct Object *ob, int select_mode, bool ignore_visibility);
void ED_pose_bone_select_tag_update(struct Object *ob);
/**
* Utility method for changing the selection status of a bone.
diff --git a/source/blender/editors/include/ED_buttons.h b/source/blender/editors/include/ED_buttons.h
index 79404aada41..c3479c10d58 100644
--- a/source/blender/editors/include/ED_buttons.h
+++ b/source/blender/editors/include/ED_buttons.h
@@ -36,7 +36,7 @@ struct bContext;
* \return The total number of items in the array returned.
*/
int ED_buttons_tabs_list(struct SpaceProperties *sbuts, short *context_tabs_array);
-bool ED_buttons_tab_has_search_result(struct SpaceProperties *sbuts, const int index);
+bool ED_buttons_tab_has_search_result(struct SpaceProperties *sbuts, int index);
void ED_buttons_search_string_set(struct SpaceProperties *sbuts, const char *value);
int ED_buttons_search_string_length(struct SpaceProperties *sbuts);
@@ -48,7 +48,7 @@ bool ED_buttons_should_sync_with_outliner(const struct bContext *C,
void ED_buttons_set_context(const struct bContext *C,
struct SpaceProperties *sbuts,
PointerRNA *ptr,
- const int context);
+ int context);
#ifdef __cplusplus
}
diff --git a/source/blender/editors/include/ED_curve.h b/source/blender/editors/include/ED_curve.h
index 805d42b6fbc..a9225a5db60 100644
--- a/source/blender/editors/include/ED_curve.h
+++ b/source/blender/editors/include/ED_curve.h
@@ -100,7 +100,7 @@ void ED_curve_editfont_load(struct Object *obedit);
void ED_curve_editfont_make(struct Object *obedit);
void ED_curve_editfont_free(struct Object *obedit);
-void ED_text_to_object(struct bContext *C, const struct Text *text, const bool split_lines);
+void ED_text_to_object(struct bContext *C, const struct Text *text, bool split_lines);
void ED_curve_beztcpy(struct EditNurb *editnurb,
struct BezTriple *dst,
diff --git a/source/blender/editors/include/ED_file_indexer.h b/source/blender/editors/include/ED_file_indexer.h
index 0afa8819def..3b19a738b90 100644
--- a/source/blender/editors/include/ED_file_indexer.h
+++ b/source/blender/editors/include/ED_file_indexer.h
@@ -146,7 +146,7 @@ void ED_file_indexer_entries_clear(FileIndexerEntries *indexer_entries);
void ED_file_indexer_entries_extend_from_datablock_infos(
FileIndexerEntries *indexer_entries,
const LinkNode * /* BLODataBlockInfo */ datablock_infos,
- const int idcode);
+ int idcode);
#ifdef __cplusplus
}
diff --git a/source/blender/editors/include/ED_fileselect.h b/source/blender/editors/include/ED_fileselect.h
index 460de58bdb2..0528057fb54 100644
--- a/source/blender/editors/include/ED_fileselect.h
+++ b/source/blender/editors/include/ED_fileselect.h
@@ -127,7 +127,7 @@ void ED_fileselect_set_params_from_userdef(struct SpaceFile *sfile);
*/
void ED_fileselect_params_to_userdef(struct SpaceFile *sfile,
const int temp_win_size[2],
- const bool is_maximized);
+ bool is_maximized);
void ED_fileselect_init_layout(struct SpaceFile *sfile, struct ARegion *region);
@@ -171,9 +171,7 @@ void ED_fileselect_activate_asset_catalog(const struct SpaceFile *sfile, bUUID c
* Activate and select the file that corresponds to the given ID.
* Pass deferred=true to wait for the next refresh before activating.
*/
-void ED_fileselect_activate_by_id(struct SpaceFile *sfile,
- struct ID *asset_id,
- const bool deferred);
+void ED_fileselect_activate_by_id(struct SpaceFile *sfile, struct ID *asset_id, bool deferred);
void ED_fileselect_deselect_all(struct SpaceFile *sfile);
void ED_fileselect_activate_by_relpath(struct SpaceFile *sfile, const char *relative_path);
@@ -256,7 +254,7 @@ char *ED_fsmenu_entry_get_name(struct FSMenuEntry *fsentry);
void ED_fsmenu_entry_set_name(struct FSMenuEntry *fsentry, const char *name);
int ED_fsmenu_entry_get_icon(struct FSMenuEntry *fsentry);
-void ED_fsmenu_entry_set_icon(struct FSMenuEntry *fsentry, const int icon);
+void ED_fsmenu_entry_set_icon(struct FSMenuEntry *fsentry, int icon);
#ifdef __cplusplus
}
diff --git a/source/blender/editors/include/ED_gizmo_library.h b/source/blender/editors/include/ED_gizmo_library.h
index 55beff40177..8d4177faa0c 100644
--- a/source/blender/editors/include/ED_gizmo_library.h
+++ b/source/blender/editors/include/ED_gizmo_library.h
@@ -65,7 +65,7 @@ void ED_gizmo_draw_preset_circle(const struct wmGizmo *gz,
void ED_gizmo_draw_preset_facemap(const struct bContext *C,
const struct wmGizmo *gz,
struct Object *ob,
- const int facemap,
+ int facemap,
int select_id);
/* -------------------------------------------------------------------- */
@@ -97,13 +97,13 @@ enum {
*
* \note Needs to be called before #WM_gizmo_target_property_def_rna!
*/
-void ED_gizmo_arrow3d_set_ui_range(struct wmGizmo *gz, const float min, const float max);
+void ED_gizmo_arrow3d_set_ui_range(struct wmGizmo *gz, float min, float max);
/**
* Define a custom factor for arrow min/max distance.
*
* \note Needs to be called before #WM_gizmo_target_property_def_rna!
*/
-void ED_gizmo_arrow3d_set_range_fac(struct wmGizmo *gz, const float range_fac);
+void ED_gizmo_arrow3d_set_range_fac(struct wmGizmo *gz, float range_fac);
/* -------------------------------------------------------------------- */
/* Cage Gizmo */
@@ -248,9 +248,9 @@ struct Dial3dParams {
};
void ED_gizmotypes_dial_3d_draw_util(const float matrix_basis[4][4],
const float matrix_final[4][4],
- const float line_width,
+ float line_width,
const float color[4],
- const bool select,
+ bool select,
struct Dial3dParams *params);
/* snap3d_gizmo.c */
diff --git a/source/blender/editors/include/ED_gpencil.h b/source/blender/editors/include/ED_gpencil.h
index 49ca5a4c5a3..919ea3e4a6b 100644
--- a/source/blender/editors/include/ED_gpencil.h
+++ b/source/blender/editors/include/ED_gpencil.h
@@ -193,7 +193,7 @@ bool ED_gpencil_has_keyframe_v3d(struct Scene *scene, struct Object *ob, int cfr
/* ----------- Stroke Editing Utilities ---------------- */
bool ED_gpencil_frame_has_selected_stroke(const struct bGPDframe *gpf);
-bool ED_gpencil_layer_has_selected_stroke(const struct bGPDlayer *gpl, const bool is_multiedit);
+bool ED_gpencil_layer_has_selected_stroke(const struct bGPDlayer *gpl, bool is_multiedit);
/**
* Check whether given stroke can be edited given the supplied context.
@@ -250,12 +250,8 @@ void ED_annotation_draw_view3d(struct Scene *scene,
struct View3D *v3d,
struct ARegion *region,
bool only3d);
-void ED_annotation_draw_ex(struct Scene *scene,
- struct bGPdata *gpd,
- int winx,
- int winy,
- const int cfra,
- const char spacetype);
+void ED_annotation_draw_ex(
+ struct Scene *scene, struct bGPdata *gpd, int winx, int winy, int cfra, char spacetype);
/* ----------- Grease-Pencil AnimEdit API ------------------ */
/**
@@ -315,7 +311,7 @@ void ED_gpencil_layer_frames_duplicate(struct bGPDlayer *gpl);
void ED_gpencil_layer_merge(struct bGPdata *gpd,
struct bGPDlayer *gpl_src,
struct bGPDlayer *gpl_dst,
- const bool reverse);
+ bool reverse);
/**
* Set keyframe type for selected frames from given gp-layer
@@ -348,14 +344,14 @@ bool ED_gpencil_anim_copybuf_copy(struct bAnimContext *ac);
/**
* Pastes keyframes from buffer, and reports success.
*/
-bool ED_gpencil_anim_copybuf_paste(struct bAnimContext *ac, const short copy_mode);
+bool ED_gpencil_anim_copybuf_paste(struct bAnimContext *ac, short copy_mode);
/* ------------ Grease-Pencil Undo System ------------------ */
int ED_gpencil_session_active(void);
/**
* \param step: eUndoStepDir.
*/
-int ED_undo_gpencil_step(struct bContext *C, const int step); /* eUndoStepDir. */
+int ED_undo_gpencil_step(struct bContext *C, int step); /* eUndoStepDir. */
/* ------------ Grease-Pencil Armature ------------------ */
bool ED_gpencil_add_armature(const struct bContext *C,
@@ -410,7 +406,7 @@ void ED_gpencil_brush_draw_eraser(struct Brush *brush, int x, int y);
*/
void ED_gpencil_stroke_init_data(struct bGPDstroke *gps,
const float *array,
- const int totpoints,
+ int totpoints,
const float mat[4][4]);
/**
@@ -457,7 +453,7 @@ void ED_gpencil_project_stroke_to_plane(const struct Scene *scene,
struct bGPDlayer *gpl,
struct bGPDstroke *gps,
const float origin[3],
- const int axis);
+ int axis);
/**
* Reproject given point to a plane locked to axis to avoid stroke offset
* \param pt: Point to affect (used for input & output).
@@ -467,7 +463,7 @@ void ED_gpencil_project_point_to_plane(const struct Scene *scene,
struct bGPDlayer *gpl,
const struct RegionView3D *rv3d,
const float origin[3],
- const int axis,
+ int axis,
struct bGPDspoint *pt);
/**
* Get drawing reference point for conversion or projection of the stroke
@@ -490,8 +486,8 @@ void ED_gpencil_stroke_reproject(struct Depsgraph *depsgraph,
struct bGPDlayer *gpl,
struct bGPDframe *gpf,
struct bGPDstroke *gps,
- const eGP_ReprojectModes mode,
- const bool keep_original);
+ eGP_ReprojectModes mode,
+ bool keep_original);
/**
* Turn brush cursor in on/off.
@@ -552,7 +548,7 @@ int ED_gpencil_select_stroke_segment(struct bGPdata *gpd,
struct bGPDspoint *pt,
bool select,
bool insert,
- const float scale,
+ float scale,
float r_hita[3],
float r_hitb[3]);
@@ -566,7 +562,7 @@ void ED_gpencil_select_curve_toggle_all(struct bContext *C, int action);
struct tGPspoint *ED_gpencil_sbuffer_ensure(struct tGPspoint *buffer_array,
int *buffer_size,
int *buffer_used,
- const bool clear);
+ bool clear);
void ED_gpencil_sbuffer_update_eval(struct bGPdata *gpd, struct Object *ob_eval);
/**
@@ -600,7 +596,7 @@ void ED_gpencil_init_random_settings(struct Brush *brush,
bool ED_gpencil_stroke_check_collision(const struct GP_SpaceConversion *gsc,
struct bGPDstroke *gps,
const float mouse[2],
- const int radius,
+ int radius,
const float diff_mat[4][4]);
/**
* Check if a point is inside of the stroke.
@@ -631,7 +627,7 @@ struct bGPDstroke *ED_gpencil_stroke_nearest_to_ends(struct bContext *C,
struct bGPDstroke *gps,
const float ctrl1[2],
const float ctrl2[2],
- const float radius,
+ float radius,
int *r_index);
/**
* Get extremes of stroke in 2D using current view.
@@ -649,12 +645,12 @@ struct bGPDstroke *ED_gpencil_stroke_join_and_trim(struct bGPdata *gpd,
struct bGPDframe *gpf,
struct bGPDstroke *gps,
struct bGPDstroke *gps_dst,
- const int pt_index);
+ int pt_index);
/**
* Close if the distance between extremes is below threshold.
*/
-void ED_gpencil_stroke_close_by_distance(struct bGPDstroke *gps, const float threshold);
+void ED_gpencil_stroke_close_by_distance(struct bGPDstroke *gps, float threshold);
#ifdef __cplusplus
}
diff --git a/source/blender/editors/include/ED_image.h b/source/blender/editors/include/ED_image.h
index 3308ae2c178..c5e8c2ee096 100644
--- a/source/blender/editors/include/ED_image.h
+++ b/source/blender/editors/include/ED_image.h
@@ -44,18 +44,18 @@ struct wmWindowManager;
struct View2D;
/* image_draw.c */
-float ED_space_image_zoom_level(const struct View2D *v2d, const int grid_dimension);
+float ED_space_image_zoom_level(const struct View2D *v2d, int grid_dimension);
void ED_space_image_grid_steps(struct SpaceImage *sima,
float grid_steps[SI_GRID_STEPS_LEN],
- const int grid_dimension);
+ int grid_dimension);
/**
* Calculate the increment snapping value for UV/image editor based on the zoom factor
* The code in here (except the offset part) is used in `grid_frag.glsl` (see `grid_res`) for
* drawing the grid overlay for the UV/Image editor.
*/
-float ED_space_image_increment_snap_value(const int grid_dimesnions,
+float ED_space_image_increment_snap_value(int grid_dimesnions,
const float grid_steps[SI_GRID_STEPS_LEN],
- const float zoom_factor);
+ float zoom_factor);
/* image_edit.c, exported for transform. */
@@ -198,7 +198,7 @@ typedef struct ImageFrameRange {
*/
ListBase ED_image_filesel_detect_sequences(struct Main *bmain,
struct wmOperator *op,
- const bool detect_udim);
+ bool detect_udim);
#ifdef __cplusplus
}
diff --git a/source/blender/editors/include/ED_keyframes_edit.h b/source/blender/editors/include/ED_keyframes_edit.h
index a7b580d5257..c7e89030ee2 100644
--- a/source/blender/editors/include/ED_keyframes_edit.h
+++ b/source/blender/editors/include/ED_keyframes_edit.h
@@ -413,8 +413,8 @@ void ANIM_fcurves_copybuf_free(void);
short copy_animedit_keys(struct bAnimContext *ac, ListBase *anim_data);
short paste_animedit_keys(struct bAnimContext *ac,
ListBase *anim_data,
- const eKeyPasteOffset offset_mode,
- const eKeyMergeMode merge_mode,
+ eKeyPasteOffset offset_mode,
+ eKeyMergeMode merge_mode,
bool flip);
/* ************************************************ */
diff --git a/source/blender/editors/include/ED_keyframes_keylist.h b/source/blender/editors/include/ED_keyframes_keylist.h
index 4194444ca0f..36a30bd5ee6 100644
--- a/source/blender/editors/include/ED_keyframes_keylist.h
+++ b/source/blender/editors/include/ED_keyframes_keylist.h
@@ -140,12 +140,9 @@ typedef enum eKeyframeExtremeDrawOpts {
struct AnimKeylist *ED_keylist_create(void);
void ED_keylist_free(struct AnimKeylist *keylist);
void ED_keylist_prepare_for_direct_access(struct AnimKeylist *keylist);
-const struct ActKeyColumn *ED_keylist_find_exact(const struct AnimKeylist *keylist,
- const float cfra);
-const struct ActKeyColumn *ED_keylist_find_next(const struct AnimKeylist *keylist,
- const float cfra);
-const struct ActKeyColumn *ED_keylist_find_prev(const struct AnimKeylist *keylist,
- const float cfra);
+const struct ActKeyColumn *ED_keylist_find_exact(const struct AnimKeylist *keylist, float cfra);
+const struct ActKeyColumn *ED_keylist_find_next(const struct AnimKeylist *keylist, float cfra);
+const struct ActKeyColumn *ED_keylist_find_prev(const struct AnimKeylist *keylist, float cfra);
const struct ActKeyColumn *ED_keylist_find_any_between(const struct AnimKeylist *keylist,
const Range2f frame_range);
bool ED_keylist_is_empty(const struct AnimKeylist *keylist);
@@ -160,41 +157,39 @@ int64_t ED_keylist_array_len(const struct AnimKeylist *keylist);
void fcurve_to_keylist(struct AnimData *adt,
struct FCurve *fcu,
struct AnimKeylist *keylist,
- const int saction_flag);
+ int saction_flag);
/* Action Group */
void agroup_to_keylist(struct AnimData *adt,
struct bActionGroup *agrp,
struct AnimKeylist *keylist,
- const int saction_flag);
+ int saction_flag);
/* Action */
void action_to_keylist(struct AnimData *adt,
struct bAction *act,
struct AnimKeylist *keylist,
- const int saction_flag);
+ int saction_flag);
/* Object */
void ob_to_keylist(struct bDopeSheet *ads,
struct Object *ob,
struct AnimKeylist *keylist,
- const int saction_flag);
+ int saction_flag);
/* Cache File */
void cachefile_to_keylist(struct bDopeSheet *ads,
struct CacheFile *cache_file,
struct AnimKeylist *keylist,
- const int saction_flag);
+ int saction_flag);
/* Scene */
void scene_to_keylist(struct bDopeSheet *ads,
struct Scene *sce,
struct AnimKeylist *keylist,
- const int saction_flag);
+ int saction_flag);
/* DopeSheet Summary */
-void summary_to_keylist(struct bAnimContext *ac,
- struct AnimKeylist *keylist,
- const int saction_flag);
+void summary_to_keylist(struct bAnimContext *ac, struct AnimKeylist *keylist, int saction_flag);
/* Grease Pencil datablock summary */
void gpencil_to_keylist(struct bDopeSheet *ads,
struct bGPdata *gpd,
struct AnimKeylist *keylist,
- const bool active);
+ bool active);
/* Grease Pencil Layer */
void gpl_to_keylist(struct bDopeSheet *ads, struct bGPDlayer *gpl, struct AnimKeylist *keylist);
/* Mask */
diff --git a/source/blender/editors/include/ED_keyframing.h b/source/blender/editors/include/ED_keyframing.h
index d539c7b688c..8d89555c732 100644
--- a/source/blender/editors/include/ED_keyframing.h
+++ b/source/blender/editors/include/ED_keyframing.h
@@ -62,7 +62,7 @@ struct NlaKeyframingContext;
* \param use_autokey_mode: include settings from key-framing mode in the result
* (i.e. replace only).
*/
-eInsertKeyFlags ANIM_get_keyframing_flags(struct Scene *scene, const bool use_autokey_mode);
+eInsertKeyFlags ANIM_get_keyframing_flags(struct Scene *scene, bool use_autokey_mode);
/* -------- */
@@ -81,15 +81,13 @@ struct FCurve *ED_action_fcurve_ensure(struct Main *bmain,
const char group[],
struct PointerRNA *ptr,
const char rna_path[],
- const int array_index);
+ int array_index);
/**
* Find the F-Curve from the Active Action,
* for the given Animation Data block. This assumes that all the destinations are valid.
*/
-struct FCurve *ED_action_fcurve_find(struct bAction *act,
- const char rna_path[],
- const int array_index);
+struct FCurve *ED_action_fcurve_find(struct bAction *act, const char rna_path[], int array_index);
/* -------- */
@@ -449,11 +447,11 @@ typedef enum eDriverFCurveCreationMode {
*/
struct FCurve *verify_driver_fcurve(struct ID *id,
const char rna_path[],
- const int array_index,
+ int array_index,
eDriverFCurveCreationMode creation_mode);
struct FCurve *alloc_driver_fcurve(const char rna_path[],
- const int array_index,
+ int array_index,
eDriverFCurveCreationMode creation_mode);
/* -------- */
diff --git a/source/blender/editors/include/ED_lattice.h b/source/blender/editors/include/ED_lattice.h
index dc800d78007..3d779fd14ef 100644
--- a/source/blender/editors/include/ED_lattice.h
+++ b/source/blender/editors/include/ED_lattice.h
@@ -43,7 +43,7 @@ bool ED_lattice_flags_set(struct Object *obedit, int flag);
bool ED_lattice_select_pick(
struct bContext *C, const int mval[2], bool extend, bool deselect, bool toggle);
-bool ED_lattice_deselect_all_multi_ex(struct Base **bases, const uint bases_len);
+bool ED_lattice_deselect_all_multi_ex(struct Base **bases, uint bases_len);
bool ED_lattice_deselect_all_multi(struct bContext *C);
/* editlattice_undo.c */
diff --git a/source/blender/editors/include/ED_mask.h b/source/blender/editors/include/ED_mask.h
index 3aab6882dc2..1a4c36acff9 100644
--- a/source/blender/editors/include/ED_mask.h
+++ b/source/blender/editors/include/ED_mask.h
@@ -79,7 +79,7 @@ bool ED_mask_selected_minmax(const struct bContext *C,
/* mask_draw.c */
-void ED_mask_draw(const struct bContext *C, const char draw_flag, const char draw_type);
+void ED_mask_draw(const struct bContext *C, char draw_flag, char draw_type);
/**
* Sets up the opengl context.
* width, height are to match the values from #ED_mask_get_size().
@@ -87,26 +87,25 @@ void ED_mask_draw(const struct bContext *C, const char draw_flag, const char dra
void ED_mask_draw_region(struct Depsgraph *depsgraph,
struct Mask *mask,
struct ARegion *region,
- const char draw_flag,
- const char draw_type,
- const eMaskOverlayMode overlay_mode,
- const int width_i,
- const int height_i,
- const float aspx,
- const float aspy,
- const bool do_scale_applied,
- const bool do_draw_cb,
+ char draw_flag,
+ char draw_type,
+ eMaskOverlayMode overlay_mode,
+ int width_i,
+ int height_i,
+ float aspx,
+ float aspy,
+ bool do_scale_applied,
+ bool do_draw_cb,
float stabmat[4][4],
const struct bContext *C);
-void ED_mask_draw_frames(
- struct Mask *mask, struct ARegion *region, const int cfra, const int sfra, const int efra);
+void ED_mask_draw_frames(struct Mask *mask, struct ARegion *region, int cfra, int sfra, int efra);
/* mask_shapekey.c */
-void ED_mask_layer_shape_auto_key(struct MaskLayer *mask_layer, const int frame);
-bool ED_mask_layer_shape_auto_key_all(struct Mask *mask, const int frame);
-bool ED_mask_layer_shape_auto_key_select(struct Mask *mask, const int frame);
+void ED_mask_layer_shape_auto_key(struct MaskLayer *mask_layer, int frame);
+bool ED_mask_layer_shape_auto_key_all(struct Mask *mask, int frame);
+bool ED_mask_layer_shape_auto_key_select(struct Mask *mask, int frame);
/* ----------- Mask AnimEdit API ------------------ */
diff --git a/source/blender/editors/include/ED_mesh.h b/source/blender/editors/include/ED_mesh.h
index 3d8bdd09711..c6f02cb3bcf 100644
--- a/source/blender/editors/include/ED_mesh.h
+++ b/source/blender/editors/include/ED_mesh.h
@@ -70,20 +70,20 @@ struct wmOperator;
* (length of total verts).
*/
void EDBM_verts_mirror_cache_begin_ex(struct BMEditMesh *em,
- const int axis,
- const bool use_self,
- const bool use_select,
- const bool respecthide,
- const bool use_topology,
+ int axis,
+ bool use_self,
+ bool use_select,
+ bool respecthide,
+ bool use_topology,
float maxdist,
int *r_index);
void EDBM_verts_mirror_cache_begin(struct BMEditMesh *em,
- const int axis,
- const bool use_self,
- const bool use_select,
- const bool respecthide,
- const bool use_topology);
-void EDBM_verts_mirror_apply(struct BMEditMesh *em, const int sel_from, const int sel_to);
+ int axis,
+ bool use_self,
+ bool use_select,
+ bool respecthide,
+ bool use_topology);
+void EDBM_verts_mirror_apply(struct BMEditMesh *em, int sel_from, int sel_to);
struct BMVert *EDBM_verts_mirror_get(struct BMEditMesh *em, struct BMVert *v);
struct BMEdge *EDBM_verts_mirror_get_edge(struct BMEditMesh *em, struct BMEdge *e);
struct BMFace *EDBM_verts_mirror_get_face(struct BMEditMesh *em, struct BMFace *f);
@@ -96,7 +96,7 @@ void EDBM_mesh_normals_update(struct BMEditMesh *em);
void EDBM_mesh_clear(struct BMEditMesh *em);
void EDBM_selectmode_to_scene(struct bContext *C);
-void EDBM_mesh_make(struct Object *ob, const int select_mode, const bool add_key_index);
+void EDBM_mesh_make(struct Object *ob, int select_mode, bool add_key_index);
/**
* Should only be called on the active edit-mesh, otherwise call #BKE_editmesh_free_data.
*/
@@ -115,10 +115,10 @@ void EDBM_mesh_load(struct Main *bmain, struct Object *ob);
* edges select/deselect faces and vertices, and in face select mode faces select/deselect
* edges and vertices.
*/
-void EDBM_select_more(struct BMEditMesh *em, const bool use_face_step);
-void EDBM_select_less(struct BMEditMesh *em, const bool use_face_step);
+void EDBM_select_more(struct BMEditMesh *em, bool use_face_step);
+void EDBM_select_less(struct BMEditMesh *em, bool use_face_step);
-void EDBM_selectmode_flush_ex(struct BMEditMesh *em, const short selectmode);
+void EDBM_selectmode_flush_ex(struct BMEditMesh *em, short selectmode);
void EDBM_selectmode_flush(struct BMEditMesh *em);
void EDBM_deselect_flush(struct BMEditMesh *em);
@@ -145,17 +145,17 @@ void EDBM_update(struct Mesh *me, const struct EDBMUpdate_Params *params);
/**
* Bad level call from Python API.
*/
-void EDBM_update_extern(struct Mesh *me, const bool do_tessellation, const bool is_destructive);
+void EDBM_update_extern(struct Mesh *me, bool do_tessellation, bool is_destructive);
/**
* A specialized vert map used by stitch operator.
*/
struct UvElementMap *BM_uv_element_map_create(struct BMesh *bm,
const struct Scene *scene,
- const bool face_selected,
- const bool uv_selected,
- const bool use_winding,
- const bool do_islands);
+ bool face_selected,
+ bool uv_selected,
+ bool use_winding,
+ bool do_islands);
void BM_uv_element_map_free(struct UvElementMap *element_map);
struct UvElement *BM_uv_element_get(struct UvElementMap *map,
struct BMFace *efa,
@@ -169,21 +169,17 @@ bool EDBM_uv_check(struct BMEditMesh *em);
* last_sel, use em->act_face otherwise get the last selected face in the editselections
* at the moment, last_sel is mainly useful for making sure the space image doesn't flicker.
*/
-struct BMFace *EDBM_uv_active_face_get(struct BMEditMesh *em,
- const bool sloppy,
- const bool selected);
+struct BMFace *EDBM_uv_active_face_get(struct BMEditMesh *em, bool sloppy, bool selected);
void BM_uv_vert_map_free(struct UvVertMap *vmap);
struct UvMapVert *BM_uv_vert_map_at_index(struct UvVertMap *vmap, unsigned int v);
/**
* Return a new #UvVertMap from the edit-mesh.
*/
-struct UvVertMap *BM_uv_vert_map_create(struct BMesh *bm,
- const bool use_select,
- const bool use_winding);
+struct UvVertMap *BM_uv_vert_map_create(struct BMesh *bm, bool use_select, bool use_winding);
-void EDBM_flag_enable_all(struct BMEditMesh *em, const char hflag);
-void EDBM_flag_disable_all(struct BMEditMesh *em, const char hflag);
+void EDBM_flag_enable_all(struct BMEditMesh *em, char hflag);
+void EDBM_flag_disable_all(struct BMEditMesh *em, char hflag);
bool BMBVH_EdgeVisible(struct BMBVHTree *tree,
struct BMEdge *e,
@@ -200,13 +196,9 @@ void EDBM_project_snap_verts(struct bContext *C,
/* editmesh_automerge.c */
-void EDBM_automerge(struct Object *ob, bool update, const char hflag, const float dist);
-void EDBM_automerge_and_split(struct Object *ob,
- const bool split_edges,
- const bool split_faces,
- const bool update,
- const char hflag,
- const float dist);
+void EDBM_automerge(struct Object *ob, bool update, char hflag, float dist);
+void EDBM_automerge_and_split(
+ struct Object *ob, bool split_edges, bool split_faces, bool update, char hflag, float dist);
/* editmesh_undo.c */
@@ -217,8 +209,8 @@ void ED_mesh_undosys_type(struct UndoType *ut);
void EDBM_select_mirrored(struct BMEditMesh *em,
const struct Mesh *me,
- const int axis,
- const bool extend,
+ int axis,
+ bool extend,
int *r_totmirr,
int *r_totfail);
@@ -235,7 +227,7 @@ void EDBM_select_mirrored(struct BMEditMesh *em,
*/
struct BMVert *EDBM_vert_find_nearest_ex(struct ViewContext *vc,
float *dist_px_manhattan_p,
- const bool use_select_bias,
+ bool use_select_bias,
bool use_cycle,
struct Base **bases,
uint bases_len,
@@ -245,7 +237,7 @@ struct BMVert *EDBM_vert_find_nearest(struct ViewContext *vc, float *dist_px_man
struct BMEdge *EDBM_edge_find_nearest_ex(struct ViewContext *vc,
float *dist_px_manhattan,
float *r_dist_center,
- const bool use_select_bias,
+ bool use_select_bias,
bool use_cycle,
struct BMEdge **r_eed_zbuf,
struct Base **bases,
@@ -263,8 +255,8 @@ struct BMEdge *EDBM_edge_find_nearest(struct ViewContext *vc, float *dist_px_man
struct BMFace *EDBM_face_find_nearest_ex(struct ViewContext *vc,
float *dist_px_manhattan,
float *r_dist_center,
- const bool use_zbuf_single_px,
- const bool use_select_bias,
+ bool use_zbuf_single_px,
+ bool use_select_bias,
bool use_cycle,
struct BMFace **r_efa_zbuf,
struct Base **bases,
@@ -274,7 +266,7 @@ struct BMFace *EDBM_face_find_nearest(struct ViewContext *vc, float *dist_px_man
bool EDBM_unified_findnearest(struct ViewContext *vc,
struct Base **bases,
- const uint bases_len,
+ uint bases_len,
int *r_base_index,
struct BMVert **r_eve,
struct BMEdge **r_eed,
@@ -282,7 +274,7 @@ bool EDBM_unified_findnearest(struct ViewContext *vc,
bool EDBM_unified_findnearest_from_raycast(struct ViewContext *vc,
struct Base **bases,
- const uint bases_len,
+ uint bases_len,
bool use_boundary_vertices,
bool use_boundary_edges,
int *r_base_index_vert,
@@ -314,22 +306,17 @@ void EDBM_selectmode_set(struct BMEditMesh *em);
* - face -> vert
* - edge -> vert
*/
-void EDBM_selectmode_convert(struct BMEditMesh *em,
- const short selectmode_old,
- const short selectmode_new);
+void EDBM_selectmode_convert(struct BMEditMesh *em, short selectmode_old, short selectmode_new);
/**
* User access this.
*/
-bool EDBM_selectmode_set_multi(struct bContext *C, const short selectmode);
+bool EDBM_selectmode_set_multi(struct bContext *C, short selectmode);
/**
* User facing function, does notification.
*/
-bool EDBM_selectmode_toggle_multi(struct bContext *C,
- const short selectmode_new,
- const int action,
- const bool use_extend,
- const bool use_expand);
+bool EDBM_selectmode_toggle_multi(
+ struct bContext *C, short selectmode_new, int action, bool use_extend, bool use_expand);
/**
* Use to disable a select-mode if its enabled, Using another mode as a fallback
@@ -339,10 +326,10 @@ bool EDBM_selectmode_toggle_multi(struct bContext *C,
*/
bool EDBM_selectmode_disable(struct Scene *scene,
struct BMEditMesh *em,
- const short selectmode_disable,
- const short selectmode_fallback);
+ short selectmode_disable,
+ short selectmode_fallback);
-bool EDBM_deselect_by_material(struct BMEditMesh *em, const short index, const bool select);
+bool EDBM_deselect_by_material(struct BMEditMesh *em, short index, bool select);
void EDBM_select_toggle_all(struct BMEditMesh *em);
@@ -350,16 +337,16 @@ void EDBM_select_swap(struct BMEditMesh *em); /* exported for UV */
bool EDBM_select_interior_faces(struct BMEditMesh *em);
void em_setup_viewcontext(struct bContext *C, struct ViewContext *vc); /* rename? */
-bool EDBM_mesh_deselect_all_multi_ex(struct Base **bases, const uint bases_len);
+bool EDBM_mesh_deselect_all_multi_ex(struct Base **bases, uint bases_len);
bool EDBM_mesh_deselect_all_multi(struct bContext *C);
bool EDBM_selectmode_disable_multi_ex(struct Scene *scene,
struct Base **bases,
- const uint bases_len,
- const short selectmode_disable,
- const short selectmode_fallback);
+ uint bases_len,
+ short selectmode_disable,
+ short selectmode_fallback);
bool EDBM_selectmode_disable_multi(struct bContext *C,
- const short selectmode_disable,
- const short selectmode_fallback);
+ short selectmode_disable,
+ short selectmode_fallback);
/* editmesh_preselect_edgering.c */
struct EditMesh_PreSelEdgeRing;
@@ -429,11 +416,11 @@ bool paintface_deselect_all_visible(struct bContext *C,
void paintface_select_linked(struct bContext *C,
struct Object *ob,
const int mval[2],
- const bool select);
+ bool select);
bool paintface_minmax(struct Object *ob, float r_min[3], float r_max[3]);
-void paintface_hide(struct bContext *C, struct Object *ob, const bool unselected);
-void paintface_reveal(struct bContext *C, struct Object *ob, const bool select);
+void paintface_hide(struct bContext *C, struct Object *ob, bool unselected);
+void paintface_reveal(struct bContext *C, struct Object *ob, bool select);
/**
* \note if the caller passes false to flush_flags,
@@ -463,7 +450,7 @@ bool ED_mesh_mirrtopo_recalc_check(struct BMEditMesh *em,
void ED_mesh_mirrtopo_init(struct BMEditMesh *em,
struct Mesh *me,
MirrTopoStore_t *mesh_topo_store,
- const bool skip_em_vert_array_init);
+ bool skip_em_vert_array_init);
void ED_mesh_mirrtopo_free(MirrTopoStore_t *mesh_topo_store);
/* object_vgroup.c */
@@ -476,7 +463,7 @@ void ED_vgroup_select_by_name(struct Object *ob, const char *name);
/**
* Removes out of range #MDeformWeights
*/
-void ED_vgroup_data_clamp_range(struct ID *id, const int total);
+void ED_vgroup_data_clamp_range(struct ID *id, int total);
/**
* Matching index only.
*/
@@ -484,7 +471,7 @@ bool ED_vgroup_array_copy(struct Object *ob, struct Object *ob_from);
bool ED_vgroup_parray_alloc(struct ID *id,
struct MDeformVert ***dvert_arr,
int *dvert_tot,
- const bool use_vert_sel);
+ bool use_vert_sel);
/**
* For use with tools that use ED_vgroup_parray_alloc with \a use_vert_sel == true.
* This finds the unselected mirror deform verts and copies the weights to them from the selected.
@@ -494,9 +481,9 @@ bool ED_vgroup_parray_alloc(struct ID *id,
*/
void ED_vgroup_parray_mirror_sync(struct Object *ob,
struct MDeformVert **dvert_array,
- const int dvert_tot,
+ int dvert_tot,
const bool *vgroup_validmap,
- const int vgroup_tot);
+ int vgroup_tot);
/**
* Fill in the pointers for mirror verts (as if all mirror verts were selected too).
*
@@ -504,27 +491,27 @@ void ED_vgroup_parray_mirror_sync(struct Object *ob,
*/
void ED_vgroup_parray_mirror_assign(struct Object *ob,
struct MDeformVert **dvert_array,
- const int dvert_tot);
+ int dvert_tot);
void ED_vgroup_parray_remove_zero(struct MDeformVert **dvert_array,
- const int dvert_tot,
+ int dvert_tot,
const bool *vgroup_validmap,
- const int vgroup_tot,
- const float epsilon,
- const bool keep_single);
+ int vgroup_tot,
+ float epsilon,
+ bool keep_single);
void ED_vgroup_parray_to_weight_array(const struct MDeformVert **dvert_array,
- const int dvert_tot,
+ int dvert_tot,
float *dvert_weights,
- const int def_nr);
+ int def_nr);
void ED_vgroup_parray_from_weight_array(struct MDeformVert **dvert_array,
- const int dvert_tot,
+ int dvert_tot,
const float *dvert_weights,
- const int def_nr,
- const bool remove_zero);
+ int def_nr,
+ bool remove_zero);
void ED_vgroup_mirror(struct Object *ob,
- const bool mirror_weights,
- const bool flip_vgroups,
- const bool all_vgroups,
- const bool use_topology,
+ bool mirror_weights,
+ bool flip_vgroups,
+ bool all_vgroups,
+ bool use_topology,
int *r_totmirr,
int *r_totfail);
@@ -560,36 +547,27 @@ void ED_mesh_geometry_clear(struct Mesh *mesh);
void ED_mesh_update(struct Mesh *mesh, struct bContext *C, bool calc_edges, bool calc_edges_loose);
void ED_mesh_uv_texture_ensure(struct Mesh *me, const char *name);
-int ED_mesh_uv_texture_add(struct Mesh *me,
- const char *name,
- const bool active_set,
- const bool do_init,
- struct ReportList *reports);
-bool ED_mesh_uv_texture_remove_index(struct Mesh *me, const int n);
+int ED_mesh_uv_texture_add(
+ struct Mesh *me, const char *name, bool active_set, bool do_init, struct ReportList *reports);
+bool ED_mesh_uv_texture_remove_index(struct Mesh *me, int n);
bool ED_mesh_uv_texture_remove_active(struct Mesh *me);
bool ED_mesh_uv_texture_remove_named(struct Mesh *me, const char *name);
void ED_mesh_uv_loop_reset(struct bContext *C, struct Mesh *me);
/**
* Without a #bContext, called when UV-editing.
*/
-void ED_mesh_uv_loop_reset_ex(struct Mesh *me, const int layernum);
+void ED_mesh_uv_loop_reset_ex(struct Mesh *me, int layernum);
bool ED_mesh_color_ensure(struct Mesh *me, const char *name);
-int ED_mesh_color_add(struct Mesh *me,
- const char *name,
- const bool active_set,
- const bool do_init,
- struct ReportList *reports);
-bool ED_mesh_color_remove_index(struct Mesh *me, const int n);
+int ED_mesh_color_add(
+ struct Mesh *me, const char *name, bool active_set, bool do_init, struct ReportList *reports);
+bool ED_mesh_color_remove_index(struct Mesh *me, int n);
bool ED_mesh_color_remove_active(struct Mesh *me);
bool ED_mesh_color_remove_named(struct Mesh *me, const char *name);
bool ED_mesh_sculpt_color_ensure(struct Mesh *me, const char *name);
-int ED_mesh_sculpt_color_add(struct Mesh *me,
- const char *name,
- const bool active_set,
- const bool do_init,
- struct ReportList *reports);
-bool ED_mesh_sculpt_color_remove_index(struct Mesh *me, const int n);
+int ED_mesh_sculpt_color_add(
+ struct Mesh *me, const char *name, bool active_set, bool do_init, struct ReportList *reports);
+bool ED_mesh_sculpt_color_remove_index(struct Mesh *me, int n);
bool ED_mesh_sculpt_color_remove_active(struct Mesh *me);
bool ED_mesh_sculpt_color_remove_named(struct Mesh *me, const char *name);
@@ -654,16 +632,13 @@ void ED_mesh_mirror_topo_table_end(struct Object *ob);
* Retrieves mirrored cache vert, or NULL if there isn't one.
* \note calling this without ensuring the mirror cache state is bad.
*/
-int mesh_get_x_mirror_vert(struct Object *ob,
- struct Mesh *me_eval,
- int index,
- const bool use_topology);
+int mesh_get_x_mirror_vert(struct Object *ob, struct Mesh *me_eval, int index, bool use_topology);
struct BMVert *editbmesh_get_x_mirror_vert(struct Object *ob,
struct BMEditMesh *em,
struct BMVert *eve,
const float co[3],
int index,
- const bool use_topology);
+ bool use_topology);
/**
* This is a Mesh-based copy of #mesh_get_x_mirror_faces().
*/
@@ -702,12 +677,10 @@ struct MDeformVert *ED_mesh_active_dvert_get_ob(struct Object *ob, int *r_index)
struct MDeformVert *ED_mesh_active_dvert_get_only(struct Object *ob);
void EDBM_mesh_stats_multi(struct Object **objects,
- const uint objects_len,
+ uint objects_len,
int totelem[3],
int totelem_sel[3]);
-void EDBM_mesh_elem_index_ensure_multi(struct Object **objects,
- const uint objects_len,
- const char htype);
+void EDBM_mesh_elem_index_ensure_multi(struct Object **objects, uint objects_len, char htype);
#define ED_MESH_PICK_DEFAULT_VERT_DIST 25
#define ED_MESH_PICK_DEFAULT_FACE_DIST 1
diff --git a/source/blender/editors/include/ED_numinput.h b/source/blender/editors/include/ED_numinput.h
index 84fa4488374..9fd77fa858e 100644
--- a/source/blender/editors/include/ED_numinput.h
+++ b/source/blender/editors/include/ED_numinput.h
@@ -114,7 +114,7 @@ bool user_string_to_number(bContext *C,
const struct UnitSettings *unit,
int type,
double *r_value,
- const bool use_single_line_error,
+ bool use_single_line_error,
char **r_error);
/** \} */
diff --git a/source/blender/editors/include/ED_object.h b/source/blender/editors/include/ED_object.h
index 576c6f51362..805b48d9195 100644
--- a/source/blender/editors/include/ED_object.h
+++ b/source/blender/editors/include/ED_object.h
@@ -82,12 +82,12 @@ Object **ED_object_array_in_mode_or_selected(struct bContext *C,
/* object_utils.c */
bool ED_object_calc_active_center_for_editmode(struct Object *obedit,
- const bool select_only,
+ bool select_only,
float r_center[3]);
bool ED_object_calc_active_center_for_posemode(struct Object *ob,
- const bool select_only,
+ bool select_only,
float r_center[3]);
-bool ED_object_calc_active_center(struct Object *ob, const bool select_only, float r_center[3]);
+bool ED_object_calc_active_center(struct Object *ob, bool select_only, float r_center[3]);
/* Object Data Container helper API. */
struct XFormObjectData_Container;
@@ -189,10 +189,10 @@ bool ED_object_parent_set(struct ReportList *reports,
struct Object *const ob,
struct Object *const par,
int partype,
- const bool xmirror,
- const bool keep_transform,
+ bool xmirror,
+ bool keep_transform,
const int vert_par[3]);
-void ED_object_parent_clear(struct Object *ob, const int type);
+void ED_object_parent_clear(struct Object *ob, int type);
/**
* Simple API for object selection, rather than just using the flag
@@ -243,12 +243,9 @@ struct Base *ED_object_add_duplicate(struct Main *bmain,
struct Scene *scene,
struct ViewLayer *view_layer,
struct Base *base,
- const eDupli_ID_Flags dupflag);
+ eDupli_ID_Flags dupflag);
-void ED_object_parent(struct Object *ob,
- struct Object *parent,
- const int type,
- const char *substr);
+void ED_object_parent(struct Object *ob, struct Object *parent, int type, const char *substr);
char *ED_object_ot_drop_named_material_tooltip(struct bContext *C,
struct PointerRNA *properties,
const int mval[2]);
@@ -323,7 +320,7 @@ void ED_object_sculptmode_enter_ex(struct Main *bmain,
struct Depsgraph *depsgraph,
struct Scene *scene,
struct Object *ob,
- const bool force_dyntopo,
+ bool force_dyntopo,
struct ReportList *reports);
void ED_object_sculptmode_enter(struct bContext *C,
struct Depsgraph *depsgraph,
@@ -335,8 +332,8 @@ void ED_object_sculptmode_exit_ex(struct Main *bmain,
void ED_object_sculptmode_exit(struct bContext *C, struct Depsgraph *depsgraph);
void ED_object_location_from_view(struct bContext *C, float loc[3]);
-void ED_object_rotation_from_quat(float rot[3], const float quat[4], const char align_axis);
-void ED_object_rotation_from_view(struct bContext *C, float rot[3], const char align_axis);
+void ED_object_rotation_from_quat(float rot[3], const float quat[4], char align_axis);
+void ED_object_rotation_from_view(struct bContext *C, float rot[3], char align_axis);
void ED_object_base_init_transform_on_add(struct Object *object,
const float loc[3],
const float rot[3]);
@@ -363,7 +360,7 @@ void ED_object_add_generic_props(struct wmOperatorType *ot, bool do_editmode);
void ED_object_add_mesh_props(struct wmOperatorType *ot);
bool ED_object_add_generic_get_opts(struct bContext *C,
struct wmOperator *op,
- const char view_align_axis,
+ char view_align_axis,
float r_loc[3],
float r_rot[3],
float r_scale[3],
@@ -378,20 +375,20 @@ bool ED_object_add_generic_get_opts(struct bContext *C,
* \note Do not call undo push in this function (users of this function have to).
*/
struct Object *ED_object_add_type_with_obdata(struct bContext *C,
- const int type,
+ int type,
const char *name,
const float loc[3],
const float rot[3],
- const bool enter_editmode,
- const ushort local_view_bits,
+ bool enter_editmode,
+ ushort local_view_bits,
struct ID *obdata);
struct Object *ED_object_add_type(struct bContext *C,
- const int type,
+ int type,
const char *name,
const float loc[3],
const float rot[3],
- const bool enter_editmode,
- const unsigned short local_view_bits)
+ bool enter_editmode,
+ unsigned short local_view_bits)
ATTR_NONNULL(1) ATTR_RETURNS_NONNULL;
/**
@@ -468,9 +465,7 @@ void ED_object_constraint_dependency_tag_update(struct Main *bmain,
struct Object *ob,
struct bConstraint *con);
-bool ED_object_constraint_move_to_index(struct Object *ob,
- struct bConstraint *con,
- const int index);
+bool ED_object_constraint_move_to_index(struct Object *ob, struct bConstraint *con, int index);
void ED_object_constraint_link(struct Main *bmain,
struct Object *ob_dst,
struct ListBase *dst,
@@ -514,7 +509,7 @@ bool ED_object_mode_generic_has_data(struct Depsgraph *depsgraph, const struct O
void ED_object_posemode_set_for_weight_paint(struct bContext *C,
struct Main *bmain,
struct Object *ob,
- const bool is_mode_set);
+ bool is_mode_set);
/* object_modifier.c */
@@ -550,7 +545,7 @@ bool ED_object_modifier_move_up(struct ReportList *reports,
bool ED_object_modifier_move_to_index(struct ReportList *reports,
struct Object *ob,
struct ModifierData *md,
- const int index);
+ int index);
bool ED_object_modifier_convert(struct ReportList *reports,
struct Main *bmain,
@@ -588,7 +583,7 @@ void ED_object_modifier_copy_to_object(struct bContext *C,
*/
bool ED_object_iter_other(struct Main *bmain,
struct Object *orig_ob,
- const bool include_orig,
+ bool include_orig,
bool (*callback)(struct Object *ob, void *callback_data),
void *callback_data);
@@ -619,7 +614,7 @@ bool ED_object_gpencil_modifier_move_up(struct ReportList *reports,
bool ED_object_gpencil_modifier_move_to_index(struct ReportList *reports,
struct Object *ob,
struct GpencilModifierData *md,
- const int index);
+ int index);
bool ED_object_gpencil_modifier_apply(struct Main *bmain,
struct ReportList *reports,
struct Depsgraph *depsgraph,
@@ -653,7 +648,7 @@ int ED_object_shaderfx_move_up(struct ReportList *reports,
bool ED_object_shaderfx_move_to_index(struct ReportList *reports,
struct Object *ob,
struct ShaderFxData *fx,
- const int index);
+ int index);
void ED_object_shaderfx_link(struct Object *dst, struct Object *src);
void ED_object_shaderfx_copy(struct Object *dst, struct ShaderFxData *fx);
@@ -665,7 +660,7 @@ const struct EnumPropertyItem *ED_object_vgroup_selection_itemf_helper(
struct PointerRNA *ptr,
struct PropertyRNA *prop,
bool *r_free,
- const unsigned int selection_mask);
+ unsigned int selection_mask);
void ED_object_check_force_modifiers(struct Main *bmain,
struct Scene *scene,
@@ -683,7 +678,7 @@ struct Base *ED_object_find_first_by_data_id(struct ViewLayer *view_layer, struc
*
* \returns false if not found in current view layer
*/
-bool ED_object_jump_to_object(struct bContext *C, struct Object *ob, const bool reveal_hidden);
+bool ED_object_jump_to_object(struct bContext *C, struct Object *ob, bool reveal_hidden);
/**
* Select and make the target object and bone active.
* Switches to Pose mode if in Object mode so the selection is visible.
@@ -694,7 +689,7 @@ bool ED_object_jump_to_object(struct bContext *C, struct Object *ob, const bool
bool ED_object_jump_to_bone(struct bContext *C,
struct Object *ob,
const char *bone_name,
- const bool reveal_hidden);
+ bool reveal_hidden);
/* object_facemap_ops.c */
diff --git a/source/blender/editors/include/ED_particle.h b/source/blender/editors/include/ED_particle.h
index ce25943b40a..9671f5b2b09 100644
--- a/source/blender/editors/include/ED_particle.h
+++ b/source/blender/editors/include/ED_particle.h
@@ -72,16 +72,13 @@ void PE_update_object(struct Depsgraph *depsgraph,
bool PE_mouse_particles(
struct bContext *C, const int mval[2], bool extend, bool deselect, bool toggle);
-bool PE_box_select(struct bContext *C, const struct rcti *rect, const int sel_op);
+bool PE_box_select(struct bContext *C, const struct rcti *rect, int sel_op);
bool PE_circle_select(struct bContext *C,
struct wmGenericUserData *wm_userdata,
- const int sel_op,
+ int sel_op,
const int mval[2],
float rad);
-int PE_lasso_select(struct bContext *C,
- const int mcoords[][2],
- const int mcoords_len,
- const int sel_op);
+int PE_lasso_select(struct bContext *C, const int mcoords[][2], int mcoords_len, int sel_op);
bool PE_deselect_all_visible_ex(struct PTCacheEdit *edit);
bool PE_deselect_all_visible(struct bContext *C);
diff --git a/source/blender/editors/include/ED_render.h b/source/blender/editors/include/ED_render.h
index b91569cee03..dabf8fb838b 100644
--- a/source/blender/editors/include/ED_render.h
+++ b/source/blender/editors/include/ED_render.h
@@ -49,7 +49,7 @@ void ED_operatortypes_render(void);
/* render_update.c */
-void ED_render_engine_changed(struct Main *bmain, const bool update_scene_data);
+void ED_render_engine_changed(struct Main *bmain, bool update_scene_data);
void ED_render_engine_area_exit(struct Main *bmain, struct ScrArea *area);
void ED_render_view_layer_changed(struct Main *bmain, struct bScreen *screen);
@@ -60,14 +60,14 @@ void ED_render_id_flush_update(const struct DEGEditorUpdateContext *update_ctx,
* Update all 3D viewport render and draw engines on changes to the scene.
* This is called by the dependency graph when it detects changes.
*/
-void ED_render_scene_update(const struct DEGEditorUpdateContext *update_ctx, const bool updated);
+void ED_render_scene_update(const struct DEGEditorUpdateContext *update_ctx, bool updated);
/**
* Update 3D viewport render or draw engine on changes to the scene or view settings.
*/
void ED_render_view3d_update(struct Depsgraph *depsgraph,
struct wmWindow *window,
struct ScrArea *area,
- const bool updated);
+ bool updated);
struct Scene *ED_render_job_get_scene(const struct bContext *C);
struct Scene *ED_render_job_get_current_scene(const struct bContext *C);
@@ -113,7 +113,7 @@ void ED_preview_icon_job(const struct bContext *C,
unsigned int *rect,
int sizex,
int sizey,
- const bool delay);
+ bool delay);
void ED_preview_restart_queue_free(void);
void ED_preview_restart_queue_add(struct ID *id, enum eIconSizes size);
diff --git a/source/blender/editors/include/ED_screen.h b/source/blender/editors/include/ED_screen.h
index c65ef3e397d..651ae1de8be 100644
--- a/source/blender/editors/include/ED_screen.h
+++ b/source/blender/editors/include/ED_screen.h
@@ -160,11 +160,11 @@ void ED_region_visibility_change_update_animated(struct bContext *C,
void ED_region_info_draw(struct ARegion *region,
const char *text,
float fill_color[4],
- const bool full_redraw);
+ bool full_redraw);
void ED_region_info_draw_multiline(ARegion *region,
const char *text_array[],
float fill_color[4],
- const bool full_redraw);
+ bool full_redraw);
void ED_region_image_metadata_panel_draw(struct ImBuf *ibuf, struct uiLayout *layout);
void ED_region_grid_draw(struct ARegion *region, float zoomx, float zoomy, float x0, float y0);
float ED_region_blend_alpha(struct ARegion *region);
@@ -238,7 +238,7 @@ void ED_area_status_text(ScrArea *area, const char *str);
/**
* \param skip_region_exit: Skip calling area exit callback. Set for opening temp spaces.
*/
-void ED_area_newspace(struct bContext *C, ScrArea *area, int type, const bool skip_region_exit);
+void ED_area_newspace(struct bContext *C, ScrArea *area, int type, bool skip_region_exit);
void ED_area_prevspace(struct bContext *C, ScrArea *area);
void ED_area_swapspace(struct bContext *C, ScrArea *sa1, ScrArea *sa2);
int ED_area_headersize(void);
@@ -316,7 +316,7 @@ bool ED_screen_change(struct bContext *C, struct bScreen *screen);
void ED_screen_scene_change(struct bContext *C,
struct wmWindow *win,
struct Scene *scene,
- const bool refresh_toolsystem);
+ bool refresh_toolsystem);
/**
* Called in wm_event_system.c. sets state vars in screen, cursors.
* event type is mouse move.
@@ -360,7 +360,7 @@ bScreen *ED_screen_state_maximized_create(struct bContext *C);
struct ScrArea *ED_screen_state_toggle(struct bContext *C,
struct wmWindow *win,
struct ScrArea *area,
- const short state);
+ short state);
/**
* Wrapper to open a temporary space either as fullscreen space, or as separate window, as defined
* by \a display_type.
@@ -397,7 +397,7 @@ Scene *ED_screen_scene_find_with_window(const struct bScreen *screen,
struct wmWindow **r_window);
ScrArea *ED_screen_area_find_with_spacedata(const bScreen *screen,
const struct SpaceLink *sl,
- const bool only_visible);
+ bool only_visible);
struct wmWindow *ED_screen_window_find(const struct bScreen *screen,
const struct wmWindowManager *wm);
/**
@@ -473,9 +473,8 @@ struct WorkSpaceLayout *ED_workspace_layout_duplicate(struct Main *bmain,
bool ED_workspace_layout_delete(struct WorkSpace *workspace,
struct WorkSpaceLayout *layout_old,
struct bContext *C) ATTR_NONNULL();
-bool ED_workspace_layout_cycle(struct WorkSpace *workspace,
- const short direction,
- struct bContext *C) ATTR_NONNULL();
+bool ED_workspace_layout_cycle(struct WorkSpace *workspace, short direction, struct bContext *C)
+ ATTR_NONNULL();
void ED_workspace_status_text(struct bContext *C, const char *str);
@@ -644,12 +643,9 @@ void ED_screen_user_menu_register(void);
/* Cache display helpers */
void ED_region_cache_draw_background(struct ARegion *region);
-void ED_region_cache_draw_curfra_label(const int framenr, const float x, const float y);
-void ED_region_cache_draw_cached_segments(struct ARegion *region,
- const int num_segments,
- const int *points,
- const int sfra,
- const int efra);
+void ED_region_cache_draw_curfra_label(int framenr, float x, float y);
+void ED_region_cache_draw_cached_segments(
+ struct ARegion *region, int num_segments, const int *points, int sfra, int efra);
/* area_utils.c */
@@ -664,19 +660,15 @@ void ED_region_generic_tools_region_message_subscribe(
int ED_region_generic_tools_region_snap_size(const struct ARegion *region, int size, int axis);
/* area_query.c */
-bool ED_region_overlap_isect_x(const ARegion *region, const int event_x);
-bool ED_region_overlap_isect_y(const ARegion *region, const int event_y);
+bool ED_region_overlap_isect_x(const ARegion *region, int event_x);
+bool ED_region_overlap_isect_y(const ARegion *region, int event_y);
bool ED_region_overlap_isect_xy(const ARegion *region, const int event_xy[2]);
bool ED_region_overlap_isect_any_xy(const ScrArea *area, const int event_xy[2]);
-bool ED_region_overlap_isect_x_with_margin(const ARegion *region,
- const int event_x,
- const int margin);
-bool ED_region_overlap_isect_y_with_margin(const ARegion *region,
- const int event_y,
- const int margin);
+bool ED_region_overlap_isect_x_with_margin(const ARegion *region, int event_x, int margin);
+bool ED_region_overlap_isect_y_with_margin(const ARegion *region, int event_y, int margin);
bool ED_region_overlap_isect_xy_with_margin(const ARegion *region,
const int event_xy[2],
- const int margin);
+ int margin);
bool ED_region_panel_category_gutter_calc_rect(const ARegion *region, rcti *r_region_gutter);
bool ED_region_panel_category_gutter_isect_xy(const ARegion *region, const int event_xy[2]);
diff --git a/source/blender/editors/include/ED_sculpt.h b/source/blender/editors/include/ED_sculpt.h
index 0cdd8873cb2..7c1124d705f 100644
--- a/source/blender/editors/include/ED_sculpt.h
+++ b/source/blender/editors/include/ED_sculpt.h
@@ -60,7 +60,7 @@ void ED_sculpt_undo_geometry_end(struct Object *ob);
/* Face sets. */
int ED_sculpt_face_sets_find_next_available_id(struct Mesh *mesh);
-void ED_sculpt_face_sets_initialize_none_to_id(struct Mesh *mesh, const int new_id);
+void ED_sculpt_face_sets_initialize_none_to_id(struct Mesh *mesh, int new_id);
int ED_sculpt_face_sets_active_update_and_get(struct bContext *C,
struct Object *ob,
diff --git a/source/blender/editors/include/ED_select_utils.h b/source/blender/editors/include/ED_select_utils.h
index 4656099799b..295268c7719 100644
--- a/source/blender/editors/include/ED_select_utils.h
+++ b/source/blender/editors/include/ED_select_utils.h
@@ -64,27 +64,25 @@ enum {
* Use when we've de-selected all first for 'SEL_OP_SET'.
* 1: select, 0: deselect, -1: pass.
*/
-int ED_select_op_action(const eSelectOp sel_op, const bool is_select, const bool is_inside);
+int ED_select_op_action(eSelectOp sel_op, bool is_select, bool is_inside);
/**
* Use when we've de-selected all items first (for modes that need it).
*
* \note In some cases changing selection needs to perform other checks,
* so it's more straightforward to deselect all, then select.
*/
-int ED_select_op_action_deselected(const eSelectOp sel_op,
- const bool is_select,
- const bool is_inside);
+int ED_select_op_action_deselected(eSelectOp sel_op, bool is_select, bool is_inside);
-int ED_select_similar_compare_float(const float delta, const float thresh, const int compare);
+int ED_select_similar_compare_float(float delta, float thresh, int compare);
bool ED_select_similar_compare_float_tree(const struct KDTree_1d *tree,
- const float length,
- const float thresh,
- const int compare);
+ float length,
+ float thresh,
+ int compare);
/**
* Utility to use for selection operations that run multiple times (circle select).
*/
-eSelectOp ED_select_op_modal(const eSelectOp sel_op, const bool is_first);
+eSelectOp ED_select_op_modal(eSelectOp sel_op, bool is_first);
#ifdef __cplusplus
}
diff --git a/source/blender/editors/include/ED_transform.h b/source/blender/editors/include/ED_transform.h
index 4f9bdfadbdf..b76f882e706 100644
--- a/source/blender/editors/include/ED_transform.h
+++ b/source/blender/editors/include/ED_transform.h
@@ -104,16 +104,16 @@ void BIF_removeTransformOrientationIndex(struct bContext *C, int index);
bool BIF_createTransformOrientation(struct bContext *C,
struct ReportList *reports,
const char *name,
- const bool use_view,
- const bool activate,
- const bool overwrite);
+ bool use_view,
+ bool activate,
+ bool overwrite);
void BIF_selectTransformOrientation(struct bContext *C, struct TransformOrientation *target);
void ED_getTransformOrientationMatrix(struct ViewLayer *view_layer,
const struct View3D *v3d,
struct Object *ob,
struct Object *obedit,
- const short around,
+ short around,
float r_orientation_mat[3][3]);
int BIF_countTransformOrientation(const struct bContext *C);
@@ -161,8 +161,8 @@ short ED_transform_calc_orientation_from_type_ex(const struct Scene *scene,
const struct RegionView3D *rv3d,
struct Object *ob,
struct Object *obedit,
- const short orientation_index,
- const int pivot_point,
+ short orientation_index,
+ int pivot_point,
float r_mat[3][3]);
/* transform gizmos */
diff --git a/source/blender/editors/include/ED_transform_snap_object_context.h b/source/blender/editors/include/ED_transform_snap_object_context.h
index 6f25a63188d..fd65d8f3663 100644
--- a/source/blender/editors/include/ED_transform_snap_object_context.h
+++ b/source/blender/editors/include/ED_transform_snap_object_context.h
@@ -138,7 +138,7 @@ short ED_transform_snap_object_project_view3d_ex(struct SnapObjectContext *sctx,
struct Depsgraph *depsgraph,
const ARegion *region,
const View3D *v3d,
- const unsigned short snap_to,
+ unsigned short snap_to,
const struct SnapObjectParams *params,
const float mval[2],
const float prev_co[3],
@@ -166,7 +166,7 @@ short ED_transform_snap_object_project_view3d(struct SnapObjectContext *sctx,
struct Depsgraph *depsgraph,
const ARegion *region,
const View3D *v3d,
- const unsigned short snap_to,
+ unsigned short snap_to,
const struct SnapObjectParams *params,
const float mval[2],
const float prev_co[3],
diff --git a/source/blender/editors/include/ED_transverts.h b/source/blender/editors/include/ED_transverts.h
index 28955da6ef1..cbcf28d53d5 100644
--- a/source/blender/editors/include/ED_transverts.h
+++ b/source/blender/editors/include/ED_transverts.h
@@ -42,7 +42,7 @@ typedef struct TransVertStore {
int mode;
} TransVertStore;
-void ED_transverts_create_from_obedit(TransVertStore *tvs, struct Object *obedit, const int mode);
+void ED_transverts_create_from_obedit(TransVertStore *tvs, struct Object *obedit, int mode);
void ED_transverts_update_obedit(TransVertStore *tvs, struct Object *obedit);
void ED_transverts_free(TransVertStore *tvs);
bool ED_transverts_check_obedit(Object *obedit);
diff --git a/source/blender/editors/include/ED_util.h b/source/blender/editors/include/ED_util.h
index 69378d436ab..8a669a2afc2 100644
--- a/source/blender/editors/include/ED_util.h
+++ b/source/blender/editors/include/ED_util.h
@@ -108,7 +108,7 @@ float ED_slider_factor_get(struct tSlider *slider);
void ED_slider_factor_set(struct tSlider *slider, float factor);
bool ED_slider_allow_overshoot_get(struct tSlider *slider);
-void ED_slider_allow_overshoot_set(struct tSlider *slider, const bool value);
+void ED_slider_allow_overshoot_set(struct tSlider *slider, bool value);
/* ************** XXX OLD CRUFT WARNING ************* */
diff --git a/source/blender/editors/include/ED_uvedit.h b/source/blender/editors/include/ED_uvedit.h
index d5303904842..0af98fc367f 100644
--- a/source/blender/editors/include/ED_uvedit.h
+++ b/source/blender/editors/include/ED_uvedit.h
@@ -100,93 +100,87 @@ bool ED_uvedit_test(struct Object *obedit);
bool uvedit_face_visible_test_ex(const struct ToolSettings *ts, struct BMFace *efa);
bool uvedit_face_select_test_ex(const struct ToolSettings *ts,
struct BMFace *efa,
- const int cd_loop_uv_offset);
+ int cd_loop_uv_offset);
bool uvedit_edge_select_test_ex(const struct ToolSettings *ts,
struct BMLoop *l,
- const int cd_loop_uv_offset);
+ int cd_loop_uv_offset);
bool uvedit_uv_select_test_ex(const struct ToolSettings *ts,
struct BMLoop *l,
- const int cd_loop_uv_offset);
+ int cd_loop_uv_offset);
bool uvedit_face_visible_test(const struct Scene *scene, struct BMFace *efa);
-bool uvedit_face_select_test(const struct Scene *scene,
- struct BMFace *efa,
- const int cd_loop_uv_offset);
-bool uvedit_edge_select_test(const struct Scene *scene,
- struct BMLoop *l,
- const int cd_loop_uv_offset);
-bool uvedit_uv_select_test(const struct Scene *scene,
- struct BMLoop *l,
- const int cd_loop_uv_offset);
+bool uvedit_face_select_test(const struct Scene *scene, struct BMFace *efa, int cd_loop_uv_offset);
+bool uvedit_edge_select_test(const struct Scene *scene, struct BMLoop *l, int cd_loop_uv_offset);
+bool uvedit_uv_select_test(const struct Scene *scene, struct BMLoop *l, int cd_loop_uv_offset);
/* uv face */
void uvedit_face_select_set_with_sticky(const struct SpaceImage *sima,
const struct Scene *scene,
struct BMEditMesh *em,
struct BMFace *efa,
- const bool select,
- const bool do_history,
- const int cd_loop_uv_offset);
+ bool select,
+ bool do_history,
+ int cd_loop_uv_offset);
void uvedit_face_select_set(const struct Scene *scene,
struct BMEditMesh *em,
struct BMFace *efa,
- const bool select,
- const bool do_history,
- const int cd_loop_uv_offset);
+ bool select,
+ bool do_history,
+ int cd_loop_uv_offset);
void uvedit_face_select_enable(const struct Scene *scene,
struct BMEditMesh *em,
struct BMFace *efa,
- const bool do_history,
- const int cd_loop_uv_offset);
+ bool do_history,
+ int cd_loop_uv_offset);
void uvedit_face_select_disable(const struct Scene *scene,
struct BMEditMesh *em,
struct BMFace *efa,
- const int cd_loop_uv_offset);
+ int cd_loop_uv_offset);
/* uv edge */
void uvedit_edge_select_set_with_sticky(const struct SpaceImage *sima,
const struct Scene *scene,
struct BMEditMesh *em,
struct BMLoop *l,
- const bool select,
- const bool do_history,
- const uint cd_loop_uv_offset);
+ bool select,
+ bool do_history,
+ uint cd_loop_uv_offset);
void uvedit_edge_select_set(const struct Scene *scene,
struct BMEditMesh *em,
struct BMLoop *l,
- const bool select,
- const bool do_history,
- const int cd_loop_uv_offset);
+ bool select,
+ bool do_history,
+ int cd_loop_uv_offset);
void uvedit_edge_select_enable(const struct Scene *scene,
struct BMEditMesh *em,
struct BMLoop *l,
- const bool do_history,
- const int cd_loop_uv_offset);
+ bool do_history,
+ int cd_loop_uv_offset);
void uvedit_edge_select_disable(const struct Scene *scene,
struct BMEditMesh *em,
struct BMLoop *l,
- const int cd_loop_uv_offset);
+ int cd_loop_uv_offset);
/* uv vert */
void uvedit_uv_select_set_with_sticky(const struct SpaceImage *sima,
const struct Scene *scene,
struct BMEditMesh *em,
struct BMLoop *l,
- const bool select,
- const bool do_history,
- const uint cd_loop_uv_offset);
+ bool select,
+ bool do_history,
+ uint cd_loop_uv_offset);
void uvedit_uv_select_set(const struct Scene *scene,
struct BMEditMesh *em,
struct BMLoop *l,
- const bool select,
- const bool do_history,
- const int cd_loop_uv_offset);
+ bool select,
+ bool do_history,
+ int cd_loop_uv_offset);
void uvedit_uv_select_enable(const struct Scene *scene,
struct BMEditMesh *em,
struct BMLoop *l,
- const bool do_history,
- const int cd_loop_uv_offset);
+ bool do_history,
+ int cd_loop_uv_offset);
void uvedit_uv_select_disable(const struct Scene *scene,
struct BMEditMesh *em,
struct BMLoop *l,
- const int cd_loop_uv_offset);
+ int cd_loop_uv_offset);
bool ED_uvedit_nearest_uv(const struct Scene *scene,
struct Object *obedit,
@@ -195,7 +189,7 @@ bool ED_uvedit_nearest_uv(const struct Scene *scene,
float r_uv[2]);
bool ED_uvedit_nearest_uv_multi(const struct Scene *scene,
struct Object **objects,
- const uint objects_len,
+ uint objects_len,
const float co[2],
float *dist_sq,
float r_uv[2]);
@@ -228,7 +222,7 @@ struct BMLoop *ED_uvedit_active_edge_loop_get(struct BMesh *bm);
char ED_uvedit_select_mode_get(const struct Scene *scene);
void ED_uvedit_select_sync_flush(const struct ToolSettings *ts,
struct BMEditMesh *em,
- const bool select);
+ bool select);
/* uvedit_unwrap_ops.c */
@@ -278,7 +272,7 @@ bool uv_coords_isect_udim(const struct Image *image,
const float coords[2]);
void ED_uvedit_pack_islands_multi(const struct Scene *scene,
Object **objects,
- const uint objects_len,
+ uint objects_len,
const struct UVMapUDIM_Params *udim_params,
const struct UVPackIsland_Params *params);
diff --git a/source/blender/editors/include/ED_view3d.h b/source/blender/editors/include/ED_view3d.h
index 6c986d8efe1..0398c209c68 100644
--- a/source/blender/editors/include/ED_view3d.h
+++ b/source/blender/editors/include/ED_view3d.h
@@ -114,17 +114,17 @@ bool ED_view3d_has_workbench_in_texture_color(const struct Scene *scene,
*/
void ED_view3d_cursor3d_position(struct bContext *C,
const int mval[2],
- const bool use_depth,
+ bool use_depth,
float r_cursor_co[3]);
void ED_view3d_cursor3d_position_rotation(struct bContext *C,
const int mval[2],
- const bool use_depth,
+ bool use_depth,
enum eV3DCursorOrient orientation,
float r_cursor_co[3],
float r_cursor_quat[4]);
void ED_view3d_cursor3d_update(struct bContext *C,
const int mval[2],
- const bool use_depth,
+ bool use_depth,
enum eV3DCursorOrient orientation);
struct Camera *ED_view3d_camera_data_get(struct View3D *v3d, struct RegionView3D *rv3d);
@@ -137,7 +137,7 @@ struct Camera *ED_view3d_camera_data_get(struct View3D *v3d, struct RegionView3D
* \param quat: The view rotation, quaternion normally from #RegionView3D.viewquat.
* \param dist: The view distance from ofs, normally from #RegionView3D.dist.
*/
-void ED_view3d_to_m4(float mat[4][4], const float ofs[3], const float quat[4], const float dist);
+void ED_view3d_to_m4(float mat[4][4], const float ofs[3], const float quat[4], float dist);
/**
* Set the view transformation from a 4x4 matrix.
*
@@ -171,7 +171,7 @@ void ED_view3d_to_object(const struct Depsgraph *depsgraph,
struct Object *ob,
const float ofs[3],
const float quat[4],
- const float dist);
+ float dist);
bool ED_view3d_camera_to_view_selected(struct Main *bmain,
struct Depsgraph *depsgraph,
@@ -213,7 +213,7 @@ bool ED_view3d_depth_read_cached_normal(const struct ARegion *region,
float r_normal[3]);
bool ED_view3d_depth_unproject_v3(const struct ARegion *region,
const int mval[2],
- const double depth,
+ double depth,
float r_location_world[3]);
/* Projection */
@@ -280,7 +280,7 @@ typedef enum {
/* view3d_snap.c */
bool ED_view3d_snap_selected_to_location(struct bContext *C,
const float snap_target_global[3],
- const int pivot_point);
+ int pivot_point);
/* view3d_cursor_snap.c */
#define USE_SNAP_DETECT_FROM_KEYMAP_HACK
@@ -343,8 +343,8 @@ void ED_view3d_cursor_snap_deactive(V3DSnapCursorState *state);
void ED_view3d_cursor_snap_prevpoint_set(V3DSnapCursorState *state, const float prev_point[3]);
V3DSnapCursorData *ED_view3d_cursor_snap_data_get(V3DSnapCursorState *state,
const struct bContext *C,
- const int x,
- const int y);
+ int x,
+ int y);
struct SnapObjectContext *ED_view3d_cursor_snap_context_ensure(struct Scene *scene);
void ED_view3d_cursor_snap_draw_util(struct RegionView3D *rv3d,
const float loc_prev[3],
@@ -352,7 +352,7 @@ void ED_view3d_cursor_snap_draw_util(struct RegionView3D *rv3d,
const float normal[3],
const uchar color_line[4],
const uchar color_point[4],
- const short snap_elem_type);
+ short snap_elem_type);
/* view3d_iterators.c */
@@ -362,12 +362,12 @@ void meshobject_foreachScreenVert(
struct ViewContext *vc,
void (*func)(void *userData, struct MVert *eve, const float screen_co[2], int index),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
void mesh_foreachScreenVert(
struct ViewContext *vc,
void (*func)(void *userData, struct BMVert *eve, const float screen_co[2], int index),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
void mesh_foreachScreenEdge(struct ViewContext *vc,
void (*func)(void *userData,
struct BMEdge *eed,
@@ -375,7 +375,7 @@ void mesh_foreachScreenEdge(struct ViewContext *vc,
const float screen_co_b[2],
int index),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
/**
* A version of #mesh_foreachScreenEdge that clips the segment when
@@ -388,13 +388,13 @@ void mesh_foreachScreenEdge_clip_bb_segment(struct ViewContext *vc,
const float screen_co_b[2],
int index),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
void mesh_foreachScreenFace(
struct ViewContext *vc,
void (*func)(void *userData, struct BMFace *efa, const float screen_co[2], int index),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
void nurbs_foreachScreenVert(struct ViewContext *vc,
void (*func)(void *userData,
struct Nurb *nu,
@@ -404,7 +404,7 @@ void nurbs_foreachScreenVert(struct ViewContext *vc,
bool handle_visible,
const float screen_co[2]),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
/**
* #ED_view3d_init_mats_rv3d must be called first.
*/
@@ -413,13 +413,13 @@ void mball_foreachScreenElem(struct ViewContext *vc,
struct MetaElem *ml,
const float screen_co[2]),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
void lattice_foreachScreenVert(struct ViewContext *vc,
void (*func)(void *userData,
struct BPoint *bp,
const float screen_co[2]),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
/**
* #ED_view3d_init_mats_rv3d must be called first.
*/
@@ -429,7 +429,7 @@ void armature_foreachScreenBone(struct ViewContext *vc,
const float screen_co_a[2],
const float screen_co_b[2]),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
/**
* ED_view3d_init_mats_rv3d must be called first.
@@ -440,7 +440,7 @@ void pose_foreachScreenBone(struct ViewContext *vc,
const float screen_co_a[2],
const float screen_co_b[2]),
void *userData,
- const eV3DProjTest clip_flag);
+ eV3DProjTest clip_flag);
/* *** end iterators *** */
/* view3d_project.c */
@@ -465,58 +465,58 @@ eV3DProjStatus ED_view3d_project_base(const struct ARegion *region, struct Base
/* *** short *** */
eV3DProjStatus ED_view3d_project_short_ex(const struct ARegion *region,
float perspmat[4][4],
- const bool is_local,
+ bool is_local,
const float co[3],
short r_co[2],
- const eV3DProjTest flag);
+ eV3DProjTest flag);
/* --- short --- */
eV3DProjStatus ED_view3d_project_short_global(const struct ARegion *region,
const float co[3],
short r_co[2],
- const eV3DProjTest flag);
+ eV3DProjTest flag);
/* object space, use ED_view3d_init_mats_rv3d before calling */
eV3DProjStatus ED_view3d_project_short_object(const struct ARegion *region,
const float co[3],
short r_co[2],
- const eV3DProjTest flag);
+ eV3DProjTest flag);
/* *** int *** */
eV3DProjStatus ED_view3d_project_int_ex(const struct ARegion *region,
float perspmat[4][4],
- const bool is_local,
+ bool is_local,
const float co[3],
int r_co[2],
- const eV3DProjTest flag);
+ eV3DProjTest flag);
/* --- int --- */
eV3DProjStatus ED_view3d_project_int_global(const struct ARegion *region,
const float co[3],
int r_co[2],
- const eV3DProjTest flag);
+ eV3DProjTest flag);
/* object space, use ED_view3d_init_mats_rv3d before calling */
eV3DProjStatus ED_view3d_project_int_object(const struct ARegion *region,
const float co[3],
int r_co[2],
- const eV3DProjTest flag);
+ eV3DProjTest flag);
/* *** float *** */
eV3DProjStatus ED_view3d_project_float_ex(const struct ARegion *region,
float perspmat[4][4],
- const bool is_local,
+ bool is_local,
const float co[3],
float r_co[2],
- const eV3DProjTest flag);
+ eV3DProjTest flag);
/* --- float --- */
eV3DProjStatus ED_view3d_project_float_global(const struct ARegion *region,
const float co[3],
float r_co[2],
- const eV3DProjTest flag);
+ eV3DProjTest flag);
/**
* Object space, use #ED_view3d_init_mats_rv3d before calling.
*/
eV3DProjStatus ED_view3d_project_float_object(const struct ARegion *region,
const float co[3],
float r_co[2],
- const eV3DProjTest flag);
+ eV3DProjTest flag);
float ED_view3d_pixel_size(const struct RegionView3D *rv3d, const float co[3]);
float ED_view3d_pixel_size_no_ui_scale(const struct RegionView3D *rv3d, const float co[3]);
@@ -550,7 +550,7 @@ bool ED_view3d_win_to_ray_clipped(struct Depsgraph *depsgraph,
const float mval[2],
float r_ray_start[3],
float r_ray_normal[3],
- const bool do_clip_planes);
+ bool do_clip_planes);
/**
* Calculate a 3d viewpoint and direction vector from 2d window coordinates.
* This ray_start is located at the viewpoint, ray_normal is the direction towards `mval`.
@@ -620,7 +620,7 @@ void ED_view3d_win_to_3d_int(const struct View3D *v3d,
bool ED_view3d_win_to_3d_on_plane(const struct ARegion *region,
const float plane[4],
const float mval[2],
- const bool do_clip,
+ bool do_clip,
float r_out[3]);
/**
* A wrapper for #ED_view3d_win_to_3d_on_plane that projects onto \a plane_fallback
@@ -632,13 +632,13 @@ bool ED_view3d_win_to_3d_on_plane(const struct ARegion *region,
bool ED_view3d_win_to_3d_on_plane_with_fallback(const struct ARegion *region,
const float plane[4],
const float mval[2],
- const bool do_clip,
+ bool do_clip,
const float plane_fallback[4],
float r_out[3]);
bool ED_view3d_win_to_3d_on_plane_int(const struct ARegion *region,
const float plane[4],
const int mval[2],
- const bool do_clip,
+ bool do_clip,
float r_out[3]);
/**
* Calculate a 3d difference vector from 2d window offset.
@@ -651,7 +651,7 @@ bool ED_view3d_win_to_3d_on_plane_int(const struct ARegion *region,
void ED_view3d_win_to_delta(const struct ARegion *region,
const float mval[2],
float out[3],
- const float zfac);
+ float zfac);
/**
* Calculate a 3d origin from 2d window coordinates.
* \note Orthographic views have a less obvious origin,
@@ -697,7 +697,7 @@ bool ED_view3d_win_to_segment_clipped(struct Depsgraph *depsgraph,
const float mval[2],
float r_ray_start[3],
float r_ray_end[3],
- const bool do_clip_planes);
+ bool do_clip_planes);
void ED_view3d_ob_project_mat_get(const struct RegionView3D *v3d,
const struct Object *ob,
float r_pmat[4][4]);
@@ -729,7 +729,7 @@ bool ED_view3d_clip_range_get(struct Depsgraph *depsgraph,
const struct RegionView3D *rv3d,
float *r_clipsta,
float *r_clipend,
- const bool use_ortho_factor);
+ bool use_ortho_factor);
bool ED_view3d_viewplane_get(struct Depsgraph *depsgraph,
const struct View3D *v3d,
const struct RegionView3D *rv3d,
@@ -743,7 +743,7 @@ bool ED_view3d_viewplane_get(struct Depsgraph *depsgraph,
/**
* Use instead of: `GPU_polygon_offset(rv3d->dist, ...)` see bug T37727.
*/
-void ED_view3d_polygon_offset(const struct RegionView3D *rv3d, const float dist);
+void ED_view3d_polygon_offset(const struct RegionView3D *rv3d, float dist);
void ED_view3d_calc_camera_border(const struct Scene *scene,
struct Depsgraph *depsgraph,
@@ -751,7 +751,7 @@ void ED_view3d_calc_camera_border(const struct Scene *scene,
const struct View3D *v3d,
const struct RegionView3D *rv3d,
struct rctf *r_viewborder,
- const bool no_shift);
+ bool no_shift);
void ED_view3d_calc_camera_border_size(const struct Scene *scene,
struct Depsgraph *depsgraph,
const struct ARegion *region,
@@ -766,7 +766,7 @@ bool ED_view3d_calc_render_border(const struct Scene *scene,
void ED_view3d_clipping_calc_from_boundbox(float clip[4][4],
const struct BoundBox *clipbb,
- const bool is_flip);
+ bool is_flip);
void ED_view3d_clipping_calc(struct BoundBox *bb,
float planes[4][4],
const struct ARegion *region,
@@ -796,12 +796,10 @@ void ED_view3d_clipping_local(struct RegionView3D *rv3d, const float mat[4][4]);
*
* \note Callers should check #RV3D_CLIPPING_ENABLED first.
*/
-bool ED_view3d_clipping_test(const struct RegionView3D *rv3d,
- const float co[3],
- const bool is_local);
+bool ED_view3d_clipping_test(const struct RegionView3D *rv3d, const float co[3], bool is_local);
-float ED_view3d_radius_to_dist_persp(const float angle, const float radius);
-float ED_view3d_radius_to_dist_ortho(const float lens, const float radius);
+float ED_view3d_radius_to_dist_persp(float angle, float radius);
+float ED_view3d_radius_to_dist_ortho(float lens, float radius);
/**
* Return a new #RegionView3D.dist value to fit the \a radius.
*
@@ -830,9 +828,9 @@ float ED_view3d_radius_to_dist_ortho(const float lens, const float radius);
float ED_view3d_radius_to_dist(const struct View3D *v3d,
const struct ARegion *region,
const struct Depsgraph *depsgraph,
- const char persp,
- const bool use_aspect,
- const float radius);
+ char persp,
+ bool use_aspect,
+ float radius);
/**
* Back-buffer select and draw support.
@@ -842,7 +840,7 @@ void ED_view3d_backbuf_depth_validate(struct ViewContext *vc);
* allow for small values [0.5 - 2.5],
* and large values, FLT_MAX by clamping by the area size
*/
-int ED_view3d_backbuf_sample_size_clamp(struct ARegion *region, const float dist);
+int ED_view3d_backbuf_sample_size_clamp(struct ARegion *region, float dist);
void ED_view3d_select_id_validate(struct ViewContext *vc);
@@ -859,7 +857,7 @@ bool ED_view3d_autodist(struct Depsgraph *depsgraph,
struct View3D *v3d,
const int mval[2],
float mouse_worldloc[3],
- const bool alphaoverride,
+ bool alphaoverride,
const float fallback_depth_pt[3]);
/**
@@ -919,7 +917,7 @@ int view3d_opengl_select_ex(struct ViewContext *vc,
const struct rcti *input,
eV3DSelectMode select_mode,
eV3DSelectObjectFilter select_filter,
- const bool do_material_slot_selection);
+ bool do_material_slot_selection);
int view3d_opengl_select(struct ViewContext *vc,
unsigned int *buffer,
unsigned int bufsize,
@@ -1004,7 +1002,7 @@ void ED_view3d_mats_rv3d_restore(struct RegionView3D *rv3d, struct RV3DMatrixSto
void ED_draw_object_facemap(struct Depsgraph *depsgraph,
struct Object *ob,
const float col[4],
- const int facemap);
+ int facemap);
struct RenderEngineType *ED_view3d_engine_type(const struct Scene *scene, int drawtype);
@@ -1046,9 +1044,9 @@ void ED_view3d_update_viewmat(struct Depsgraph *depsgraph,
const float winmat[4][4],
const struct rcti *rect,
bool offscreen);
-bool ED_view3d_quat_from_axis_view(const char view, const char view_axis_roll, float r_quat[4]);
+bool ED_view3d_quat_from_axis_view(char view, char view_axis_roll, float r_quat[4]);
bool ED_view3d_quat_to_axis_view(const float viewquat[4],
- const float epsilon,
+ float epsilon,
char *r_view,
char *r_view_axis_rotation);
@@ -1079,7 +1077,7 @@ bool ED_view3d_offset_lock_check(const struct View3D *v3d, const struct RegionVi
void ED_view3d_persp_switch_from_camera(const struct Depsgraph *depsgraph,
struct View3D *v3d,
struct RegionView3D *rv3d,
- const char persp);
+ char persp);
/**
* Action to take when rotating the view,
* handle auto-perspective and logic for switching out of views.
@@ -1105,7 +1103,7 @@ bool ED_view3d_camera_lock_check(const struct View3D *v3d, const struct RegionVi
void ED_view3d_camera_lock_init_ex(const struct Depsgraph *depsgraph,
struct View3D *v3d,
struct RegionView3D *rv3d,
- const bool calc_dist);
+ bool calc_dist);
void ED_view3d_camera_lock_init(const struct Depsgraph *depsgraph,
struct View3D *v3d,
struct RegionView3D *rv3d);
@@ -1123,8 +1121,8 @@ bool ED_view3d_camera_lock_sync(const struct Depsgraph *depsgraph,
bool ED_view3d_camera_autokey(const struct Scene *scene,
struct ID *id_key,
struct bContext *C,
- const bool do_rotate,
- const bool do_translate);
+ bool do_rotate,
+ bool do_translate);
/**
* Call after modifying a locked view.
*
@@ -1134,8 +1132,8 @@ bool ED_view3d_camera_autokey(const struct Scene *scene,
bool ED_view3d_camera_lock_autokey(struct View3D *v3d,
struct RegionView3D *rv3d,
struct bContext *C,
- const bool do_rotate,
- const bool do_translate);
+ bool do_rotate,
+ bool do_translate);
void ED_view3d_lock_clear(struct View3D *v3d);
@@ -1154,15 +1152,13 @@ void ED_view3d_lock_clear(struct View3D *v3d);
* \param fallback_dist: The distance to use if the object is too near or in front of \a ofs.
* \returns A newly calculated distance or the fallback.
*/
-float ED_view3d_offset_distance(const float mat[4][4],
- const float ofs[3],
- const float fallback_dist);
+float ED_view3d_offset_distance(const float mat[4][4], const float ofs[3], float fallback_dist);
/**
* Set the dist without moving the view (compensate with #RegionView3D.ofs)
*
* \note take care that #RegionView3d.viewinv is up to date, #ED_view3d_update_viewmat first.
*/
-void ED_view3d_distance_set(struct RegionView3D *rv3d, const float dist);
+void ED_view3d_distance_set(struct RegionView3D *rv3d, float dist);
/**
* Change the distance & offset to match the depth of \a dist_co along the view axis.
*
@@ -1172,7 +1168,7 @@ void ED_view3d_distance_set(struct RegionView3D *rv3d, const float dist);
*/
bool ED_view3d_distance_set_from_location(struct RegionView3D *rv3d,
const float dist_co[3],
- const float dist_min);
+ float dist_min);
/**
* Could move this elsewhere, but tied into #ED_view3d_grid_scale
@@ -1223,8 +1219,8 @@ void ED_view3d_draw_bgpic_test(const struct Scene *scene,
struct Depsgraph *depsgraph,
struct ARegion *region,
struct View3D *v3d,
- const bool do_foreground,
- const bool do_camera_frame);
+ bool do_foreground,
+ bool do_camera_frame);
/* view3d_gizmo_preselect_type.c */
@@ -1247,12 +1243,10 @@ void ED_view3d_buttons_region_layout_ex(const struct bContext *C,
* Try to keep the same UUID previously used to allow users to quickly toggle back and forth.
*/
bool ED_view3d_local_collections_set(struct Main *bmain, struct View3D *v3d);
-void ED_view3d_local_collections_reset(struct bContext *C, const bool reset_all);
+void ED_view3d_local_collections_reset(struct bContext *C, bool reset_all);
#ifdef WITH_XR_OPENXR
-void ED_view3d_xr_mirror_update(const struct ScrArea *area,
- const struct View3D *v3d,
- const bool enable);
+void ED_view3d_xr_mirror_update(const struct ScrArea *area, const struct View3D *v3d, bool enable);
void ED_view3d_xr_shading_update(struct wmWindowManager *wm,
const View3D *v3d,
const struct Scene *scene);
diff --git a/source/blender/editors/include/ED_view3d_offscreen.h b/source/blender/editors/include/ED_view3d_offscreen.h
index 1da0a282697..ae2329c457b 100644
--- a/source/blender/editors/include/ED_view3d_offscreen.h
+++ b/source/blender/editors/include/ED_view3d_offscreen.h
@@ -53,8 +53,8 @@ void ED_view3d_draw_offscreen(struct Depsgraph *depsgraph,
bool is_image_render,
bool draw_background,
const char *viewname,
- const bool do_color_management,
- const bool restore_rv3d_mats,
+ bool do_color_management,
+ bool restore_rv3d_mats,
struct GPUOffScreen *ofs,
struct GPUViewport *viewport);
/**
@@ -76,7 +76,7 @@ void ED_view3d_draw_offscreen_simple(struct Depsgraph *depsgraph,
bool is_image_render,
bool draw_background,
const char *viewname,
- const bool do_color_management,
+ bool do_color_management,
struct GPUOffScreen *ofs,
struct GPUViewport *viewport);
@@ -96,7 +96,7 @@ struct ImBuf *ED_view3d_draw_offscreen_imbuf(struct Depsgraph *depsgraph,
eImBufFlags imbuf_flag,
int alpha_mode,
const char *viewname,
- const bool restore_rv3d_mats,
+ bool restore_rv3d_mats,
struct GPUOffScreen *ofs,
char err_out[256]);
/**
diff --git a/source/blender/editors/include/UI_interface.h b/source/blender/editors/include/UI_interface.h
index cee323bd5c9..f01b8318e98 100644
--- a/source/blender/editors/include/UI_interface.h
+++ b/source/blender/editors/include/UI_interface.h
@@ -494,9 +494,9 @@ void UI_draw_widget_scroll(struct uiWidgetColors *wcol,
float UI_text_clip_middle_ex(const struct uiFontStyle *fstyle,
char *str,
float okwidth,
- const float minwidth,
+ float minwidth,
const size_t max_len,
- const char rpart_sep);
+ char rpart_sep);
/**
* Callbacks
@@ -531,11 +531,8 @@ typedef struct ARegion *(*uiButSearchCreateFn)(struct bContext *C,
* to display the full list of options. The value will be false after the button's text is edited
* (for every call except the first).
*/
-typedef void (*uiButSearchUpdateFn)(const struct bContext *C,
- void *arg,
- const char *str,
- uiSearchItems *items,
- const bool is_first);
+typedef void (*uiButSearchUpdateFn)(
+ const struct bContext *C, void *arg, const char *str, uiSearchItems *items, bool is_first);
typedef bool (*uiButSearchContextMenuFn)(struct bContext *C,
void *arg,
void *active,
@@ -621,7 +618,7 @@ bool UI_but_is_tool(const uiBut *but);
bool UI_but_is_utf8(const uiBut *but);
#define UI_but_is_decorator(but) ((but)->type == UI_BTYPE_DECORATOR)
-bool UI_block_is_empty_ex(const uiBlock *block, const bool skip_title);
+bool UI_block_is_empty_ex(const uiBlock *block, bool skip_title);
bool UI_block_is_empty(const uiBlock *block);
bool UI_block_can_add_separator(const uiBlock *block);
@@ -662,7 +659,7 @@ int UI_popup_menu_invoke(struct bContext *C, const char *idname, struct ReportLi
* Allow setting menu return value from externals.
* E.g. WM might need to do this for exiting files correctly.
*/
-void UI_popup_menu_retval_set(const uiBlock *block, const int retval, const bool enable);
+void UI_popup_menu_retval_set(const uiBlock *block, int retval, bool enable);
/**
* Setting the button makes the popup open from the button instead of the cursor.
*/
@@ -866,7 +863,7 @@ void UI_but_drag_set_id(uiBut *but, struct ID *id);
* Set an image to display while dragging. This works for any drag type (`WM_DRAG_XXX`).
* Not to be confused with #UI_but_drag_set_image(), which sets up dragging of an image.
*/
-void UI_but_drag_attach_image(uiBut *but, struct ImBuf *imb, const float scale);
+void UI_but_drag_attach_image(uiBut *but, struct ImBuf *imb, float scale);
/**
* \param asset: May be passed from a temporary variable, drag data only stores a copy of this.
*/
@@ -879,14 +876,14 @@ void UI_but_drag_set_asset(uiBut *but,
struct ImBuf *imb,
float scale);
void UI_but_drag_set_rna(uiBut *but, struct PointerRNA *ptr);
-void UI_but_drag_set_path(uiBut *but, const char *path, const bool use_free);
+void UI_but_drag_set_path(uiBut *but, const char *path, bool use_free);
void UI_but_drag_set_name(uiBut *but, const char *name);
/**
* Value from button itself.
*/
void UI_but_drag_set_value(uiBut *but);
void UI_but_drag_set_image(
- uiBut *but, const char *path, int icon, struct ImBuf *imb, float scale, const bool use_free);
+ uiBut *but, const char *path, int icon, struct ImBuf *imb, float scale, bool use_free);
uiBut *UI_but_active_drop_name_button(const struct bContext *C);
/**
@@ -918,7 +915,7 @@ bool UI_but_active_only_ex(const struct bContext *C,
struct ARegion *region,
uiBlock *block,
uiBut *but,
- const bool remove_on_failure);
+ bool remove_on_failure);
bool UI_but_active_only(const struct bContext *C,
struct ARegion *region,
uiBlock *block,
@@ -1373,7 +1370,7 @@ uiBut *uiDefIconTextButO_ptr(uiBlock *block,
/* for passing inputs to ButO buttons */
struct PointerRNA *UI_but_operator_ptr_get(uiBut *but);
-void UI_but_unit_type_set(uiBut *but, const int unit_type);
+void UI_but_unit_type_set(uiBut *but, int unit_type);
int UI_but_unit_type_get(const uiBut *but);
typedef enum uiStringInfoType {
@@ -1641,7 +1638,7 @@ eAutoPropButsReturn uiDefAutoButsRNA(uiLayout *layout,
void *user_data,
struct PropertyRNA *prop_activate_init,
eButLabelAlign label_align,
- const bool compact);
+ bool compact);
/**
* Public function exported for functions that use #UI_BTYPE_SEARCH_MENU.
@@ -1661,7 +1658,7 @@ bool UI_search_item_add(uiSearchItems *items,
void *poin,
int iconid,
int state,
- const uint8_t name_prefix_offset);
+ uint8_t name_prefix_offset);
/**
* \note The item-pointer (referred to below) is a per search item user pointer
@@ -1682,7 +1679,7 @@ void UI_but_func_search_set(uiBut *but,
uiButSearchCreateFn search_create_fn,
uiButSearchUpdateFn search_update_fn,
void *arg,
- const bool free_arg,
+ bool free_arg,
uiFreeArgFunc search_arg_free_fn,
uiButHandleFunc search_exec_fn,
void *active);
@@ -1693,7 +1690,7 @@ void UI_but_func_search_set_tooltip(uiBut *but, uiButSearchTooltipFn tooltip_fn)
* showing the icon and highlighted text after the last instance of this string.
*/
void UI_but_func_search_set_sep_string(uiBut *but, const char *search_sep_string);
-void UI_but_func_search_set_results_are_suggestions(uiBut *but, const bool value);
+void UI_but_func_search_set_results_are_suggestions(uiBut *but, bool value);
/**
* Height in pixels, it's using hard-coded values still.
@@ -1918,7 +1915,7 @@ void UI_region_handlers_add(struct ListBase *handlers);
void UI_popup_handlers_add(struct bContext *C,
struct ListBase *handlers,
uiPopupBlockHandle *popup,
- const char flag);
+ char flag);
void UI_popup_handlers_remove(struct ListBase *handlers, uiPopupBlockHandle *popup);
void UI_popup_handlers_remove_all(struct bContext *C, struct ListBase *handlers);
@@ -2168,7 +2165,7 @@ void uiTemplateID(uiLayout *layout,
const char *openop,
const char *unlinkop,
int filter,
- const bool live_icon,
+ bool live_icon,
const char *text);
void uiTemplateIDBrowse(uiLayout *layout,
struct bContext *C,
@@ -2189,7 +2186,7 @@ void uiTemplateIDPreview(uiLayout *layout,
int rows,
int cols,
int filter,
- const bool hide_buttons);
+ bool hide_buttons);
/**
* Version of #uiTemplateID using tabs.
*/
@@ -2233,8 +2230,8 @@ void uiTemplateSearchPreview(uiLayout *layout,
const char *searchpropname,
const char *newop,
const char *unlinkop,
- const int rows,
- const int cols);
+ int rows,
+ int cols);
/**
* This is creating/editing RNA-Paths
*
@@ -2541,7 +2538,7 @@ void uiTemplateAssetView(struct uiLayout *layout,
struct PointerRNA *active_dataptr,
const char *active_propname,
const struct AssetFilterSettings *filter_settings,
- const int display_flags,
+ int display_flags,
const char *activate_opname,
struct PointerRNA *r_activate_op_properties,
const char *drag_opname,
@@ -2750,8 +2747,7 @@ typedef struct uiPropertySplitWrapper {
uiPropertySplitWrapper uiItemPropertySplitWrapperCreate(uiLayout *parent_layout);
void uiItemL(uiLayout *layout, const char *name, int icon); /* label */
-void uiItemL_ex(
- uiLayout *layout, const char *name, int icon, const bool highlight, const bool redalert);
+void uiItemL_ex(uiLayout *layout, const char *name, int icon, bool highlight, bool redalert);
/**
* Helper to add a label and creates a property split layout if needed.
*/
@@ -2862,7 +2858,7 @@ const char *UI_layout_introspect(uiLayout *layout);
* Helper to add a big icon and create a split layout for alert popups.
* Returns the layout to place further items into the alert box.
*/
-uiLayout *uiItemsAlertBox(uiBlock *block, const int size, const eAlertIcon icon);
+uiLayout *uiItemsAlertBox(uiBlock *block, int size, eAlertIcon icon);
/* UI Operators */
typedef struct uiDragColorHandle {
@@ -3011,7 +3007,7 @@ int UI_fontstyle_string_width(const struct uiFontStyle *fs,
*/
int UI_fontstyle_string_width_with_block_aspect(const struct uiFontStyle *fs,
const char *str,
- const float aspect) ATTR_WARN_UNUSED_RESULT
+ float aspect) ATTR_WARN_UNUSED_RESULT
ATTR_NONNULL(1, 2);
int UI_fontstyle_height_max(const struct uiFontStyle *fs);
diff --git a/source/blender/editors/include/UI_interface.hh b/source/blender/editors/include/UI_interface.hh
index d18ec009108..a52b4ebd338 100644
--- a/source/blender/editors/include/UI_interface.hh
+++ b/source/blender/editors/include/UI_interface.hh
@@ -59,10 +59,10 @@ void template_breadcrumbs(uiLayout &layout, Span<ContextPathItem> context_path);
void attribute_search_add_items(
StringRefNull str,
- const bool is_output,
+ bool is_output,
Span<const nodes::geometry_nodes_eval_log::GeometryAttributeInfo *> infos,
uiSearchItems *items,
- const bool is_first);
+ bool is_first);
} // namespace blender::ui
diff --git a/source/blender/editors/include/UI_interface_icons.h b/source/blender/editors/include/UI_interface_icons.h
index 242b8504ae1..6ffeb4134ae 100644
--- a/source/blender/editors/include/UI_interface_icons.h
+++ b/source/blender/editors/include/UI_interface_icons.h
@@ -87,8 +87,8 @@ bool UI_icon_get_theme_color(int icon_id, unsigned char color[4]);
void UI_icon_render_id(const struct bContext *C,
struct Scene *scene,
struct ID *id,
- const enum eIconSizes size,
- const bool use_job);
+ enum eIconSizes size,
+ bool use_job);
/**
* Render size for preview images and icons
*/
@@ -108,7 +108,7 @@ void UI_icon_draw_ex(float x,
float alpha,
float desaturate,
const uchar mono_color[4],
- const bool mono_border);
+ bool mono_border);
void UI_icons_free(void);
void UI_icons_free_drawinfo(void *drawinfo);
@@ -121,13 +121,10 @@ int UI_iconfile_get_index(const char *filename);
struct PreviewImage *UI_icon_to_preview(int icon_id);
-int UI_icon_from_rnaptr(const struct bContext *C,
- struct PointerRNA *ptr,
- int rnaicon,
- const bool big);
-int UI_icon_from_idcode(const int idcode);
+int UI_icon_from_rnaptr(const struct bContext *C, struct PointerRNA *ptr, int rnaicon, bool big);
+int UI_icon_from_idcode(int idcode);
int UI_icon_from_library(const struct ID *id);
-int UI_icon_from_object_mode(const int mode);
+int UI_icon_from_object_mode(int mode);
int UI_icon_color_from_collection(const struct Collection *collection);
#ifdef __cplusplus
diff --git a/source/blender/editors/include/UI_resources.h b/source/blender/editors/include/UI_resources.h
index 98e141c65b5..40e4d8cee9c 100644
--- a/source/blender/editors/include/UI_resources.h
+++ b/source/blender/editors/include/UI_resources.h
@@ -502,7 +502,7 @@ int UI_ThemeMenuShadowWidth(void);
*/
const unsigned char *UI_ThemeGetColorPtr(struct bTheme *btheme, int spacetype, int colorid);
-void UI_make_axis_color(const unsigned char src_col[3], unsigned char dst_col[3], const char axis);
+void UI_make_axis_color(const unsigned char src_col[3], unsigned char dst_col[3], char axis);
#ifdef __cplusplus
}
diff --git a/source/blender/editors/include/UI_view2d.h b/source/blender/editors/include/UI_view2d.h
index 37246c2fe8f..a3f39e1286e 100644
--- a/source/blender/editors/include/UI_view2d.h
+++ b/source/blender/editors/include/UI_view2d.h
@@ -175,7 +175,7 @@ void UI_view2d_view_ortho(const struct View2D *v2d);
* \param xaxis: if non-zero, only use cur x-axis,
* otherwise use cur-yaxis (mostly this will be used for x).
*/
-void UI_view2d_view_orthoSpecial(struct ARegion *region, struct View2D *v2d, const bool xaxis);
+void UI_view2d_view_orthoSpecial(struct ARegion *region, struct View2D *v2d, bool xaxis);
/**
* Restore view matrices after drawing.
*/
@@ -435,7 +435,7 @@ void ED_keymap_view2d(struct wmKeyConfig *keyconf);
void UI_view2d_smooth_view(struct bContext *C,
struct ARegion *region,
const struct rctf *cur,
- const int smooth_viewtx);
+ int smooth_viewtx);
#define UI_MARKER_MARGIN_Y (42 * UI_DPI_FAC)
#define UI_TIME_SCRUB_MARGIN_Y (23 * UI_DPI_FAC)
diff --git a/source/blender/editors/interface/interface_eyedropper_intern.h b/source/blender/editors/interface/interface_eyedropper_intern.h
index 17bb78a7861..ec448ef9b9f 100644
--- a/source/blender/editors/interface/interface_eyedropper_intern.h
+++ b/source/blender/editors/interface/interface_eyedropper_intern.h
@@ -25,7 +25,7 @@
/* interface_eyedropper.c */
void eyedropper_draw_cursor_text_window(const struct wmWindow *window, const char *name);
-void eyedropper_draw_cursor_text_region(const int x, const int y, const char *name);
+void eyedropper_draw_cursor_text_region(int x, int y, const char *name);
/**
* Utility to retrieve a button representing a RNA property that is currently under the cursor.
*
diff --git a/source/blender/editors/interface/interface_intern.h b/source/blender/editors/interface/interface_intern.h
index dc8744aaae9..027f03d05c7 100644
--- a/source/blender/editors/interface/interface_intern.h
+++ b/source/blender/editors/interface/interface_intern.h
@@ -671,7 +671,7 @@ extern void ui_but_v3_get(uiBut *but, float vec[3]);
extern void ui_but_v3_set(uiBut *but, const float vec[3]);
extern void ui_hsvcircle_vals_from_pos(
- const rcti *rect, const float mx, const float my, float *r_val_rad, float *r_val_dist);
+ const rcti *rect, float mx, float my, float *r_val_rad, float *r_val_dist);
/**
* Cursor in HSV circle, in float units -1 to 1, to map on radius.
*/
@@ -689,8 +689,8 @@ extern void ui_hsvcube_pos_from_vals(
extern void ui_but_string_get_ex(uiBut *but,
char *str,
const size_t maxlen,
- const int float_precision,
- const bool use_exp_float,
+ int float_precision,
+ bool use_exp_float,
bool *r_use_exp_float) ATTR_NONNULL(1, 2);
extern void ui_but_string_get(uiBut *but, char *str, const size_t maxlen) ATTR_NONNULL();
/**
@@ -722,7 +722,7 @@ extern void ui_but_active_string_clear_and_exit(struct bContext *C, uiBut *but)
extern void ui_but_set_string_interactive(struct bContext *C, uiBut *but, const char *value);
extern uiBut *ui_but_drag_multi_edit_get(uiBut *but);
-void ui_def_but_icon(uiBut *but, const int icon, const int flag);
+void ui_def_but_icon(uiBut *but, int icon, int flag);
/**
* Avoid using this where possible since it's better not to ask for an icon in the first place.
*/
@@ -905,7 +905,7 @@ int ui_searchbox_find_index(struct ARegion *region, const char *name);
/**
* Region is the search box itself.
*/
-void ui_searchbox_update(struct bContext *C, struct ARegion *region, uiBut *but, const bool reset);
+void ui_searchbox_update(struct bContext *C, struct ARegion *region, uiBut *but, bool reset);
int ui_searchbox_autocomplete(struct bContext *C, struct ARegion *region, uiBut *but, char *str);
bool ui_searchbox_event(struct bContext *C,
struct ARegion *region,
@@ -1000,9 +1000,9 @@ extern int ui_handler_panel_region(struct bContext *C,
extern void ui_draw_aligned_panel(const struct uiStyle *style,
const uiBlock *block,
const rcti *rect,
- const bool show_pin,
- const bool show_background,
- const bool region_search_filter_active);
+ bool show_pin,
+ bool show_background,
+ bool region_search_filter_active);
void ui_panel_tag_search_filter_match(struct Panel *panel);
/* interface_draw.c */
@@ -1013,10 +1013,7 @@ extern void ui_draw_dropshadow(
/**
* Draws in resolution of 48x4 colors.
*/
-void ui_draw_gradient(const rcti *rect,
- const float hsv[3],
- const eButGradientType type,
- const float alpha);
+void ui_draw_gradient(const rcti *rect, const float hsv[3], eButGradientType type, float alpha);
/* based on UI_draw_roundbox_gl_mode,
* check on making a version which allows us to skip some sides */
@@ -1040,7 +1037,7 @@ void ui_draw_but_COLORBAND(uiBut *but, const struct uiWidgetColors *wcol, const
void ui_draw_but_UNITVEC(uiBut *but,
const struct uiWidgetColors *wcol,
const rcti *rect,
- const float radius);
+ float radius);
void ui_draw_but_CURVE(struct ARegion *region,
uiBut *but,
const struct uiWidgetColors *wcol,
@@ -1118,7 +1115,7 @@ extern void ui_but_active_free(const struct bContext *C, uiBut *but);
*/
extern void ui_but_update_view_for_active(const struct bContext *C, const uiBlock *block);
extern int ui_but_menu_direction(uiBut *but);
-extern void ui_but_text_password_hide(char password_str[128], uiBut *but, const bool restore);
+extern void ui_but_text_password_hide(char password_str[128], uiBut *but, bool restore);
/**
* Finds the pressed button in an aligned row (typically an expanded enum).
*
@@ -1131,7 +1128,7 @@ float ui_block_calc_pie_segment(struct uiBlock *block, const float event_xy[2]);
/* XXX, this code will shorten any allocated string to 'UI_MAX_NAME_STR'
* since this is really long its unlikely to be an issue,
* but this could be supported */
-void ui_but_add_shortcut(uiBut *but, const char *shortcut_str, const bool do_strip);
+void ui_but_add_shortcut(uiBut *but, const char *shortcut_str, bool do_strip);
void ui_but_clipboard_free(void);
bool ui_but_rna_equals(const uiBut *a, const uiBut *b);
bool ui_but_rna_equals_ex(const uiBut *but,
@@ -1272,8 +1269,8 @@ void uiStyleInit(void);
/* interface_icons.c */
-void ui_icon_ensure_deferred(const struct bContext *C, const int icon_id, const bool big);
-int ui_id_icon_get(const struct bContext *C, struct ID *id, const bool big);
+void ui_icon_ensure_deferred(const struct bContext *C, int icon_id, bool big);
+int ui_id_icon_get(const struct bContext *C, struct ID *id, bool big);
/* interface_icons_event.c */
@@ -1365,7 +1362,7 @@ bool ui_but_is_toggle(const uiBut *but) ATTR_WARN_UNUSED_RESULT;
* \note ctrl is kind of a hack currently,
* so that non-embossed UI_BTYPE_TEXT button behaves as a label when ctrl is not pressed.
*/
-bool ui_but_is_interactive(const uiBut *but, const bool labeledit) ATTR_WARN_UNUSED_RESULT;
+bool ui_but_is_interactive(const uiBut *but, bool labeledit) ATTR_WARN_UNUSED_RESULT;
bool ui_but_is_popover_once_compat(const uiBut *but) ATTR_WARN_UNUSED_RESULT;
bool ui_but_has_array_value(const uiBut *but) ATTR_WARN_UNUSED_RESULT;
int ui_but_icon(const uiBut *but);
@@ -1388,7 +1385,7 @@ uiBut *ui_list_find_from_row(const struct ARegion *region,
uiBut *ui_list_row_find_mouse_over(const struct ARegion *region, const int xy[2])
ATTR_NONNULL(1, 2) ATTR_WARN_UNUSED_RESULT;
uiBut *ui_list_row_find_from_index(const struct ARegion *region,
- const int index,
+ int index,
uiBut *listbox) ATTR_WARN_UNUSED_RESULT;
uiBut *ui_tree_row_find_mouse_over(const struct ARegion *region, const int xy[2])
ATTR_NONNULL(1, 2);
@@ -1400,7 +1397,7 @@ typedef bool (*uiButFindPollFn)(const uiBut *but, const void *customdata);
*/
uiBut *ui_but_find_mouse_over_ex(const struct ARegion *region,
const int xy[2],
- const bool labeledit,
+ bool labeledit,
const uiButFindPollFn find_poll,
const void *find_custom_data)
ATTR_NONNULL(1, 2) ATTR_WARN_UNUSED_RESULT;
@@ -1512,11 +1509,8 @@ typedef struct uiRNACollectionSearch {
/* Block has to be stored for freeing butstore (uiBut.block doesn't work with undo). */
uiBlock *butstore_block;
} uiRNACollectionSearch;
-void ui_rna_collection_search_update_fn(const struct bContext *C,
- void *arg,
- const char *str,
- uiSearchItems *items,
- const bool is_first);
+void ui_rna_collection_search_update_fn(
+ const struct bContext *C, void *arg, const char *str, uiSearchItems *items, bool is_first);
/* interface_ops.c */
diff --git a/source/blender/editors/mask/mask_intern.h b/source/blender/editors/mask/mask_intern.h
index 41ff14dcd5f..19a3b3966a1 100644
--- a/source/blender/editors/mask/mask_intern.h
+++ b/source/blender/editors/mask/mask_intern.h
@@ -95,8 +95,8 @@ bool ED_mask_spline_select_check(const struct MaskSpline *spline);
bool ED_mask_layer_select_check(const struct MaskLayer *mask_layer);
bool ED_mask_select_check(const struct Mask *mask);
-void ED_mask_spline_select_set(struct MaskSpline *spline, const bool do_select);
-void ED_mask_layer_select_set(struct MaskLayer *mask_layer, const bool do_select);
+void ED_mask_spline_select_set(struct MaskSpline *spline, bool do_select);
+void ED_mask_layer_select_set(struct MaskLayer *mask_layer, bool do_select);
void ED_mask_select_toggle_all(struct Mask *mask, int action);
void ED_mask_select_flush_all(struct Mask *mask);
@@ -126,8 +126,8 @@ bool ED_mask_find_nearest_diff_point(const struct bContext *C,
int threshold,
bool feather,
float tangent[2],
- const bool use_deform,
- const bool use_project,
+ bool use_deform,
+ bool use_project,
struct MaskLayer **r_mask_layer,
struct MaskSpline **r_spline,
struct MaskSplinePoint **r_point,
@@ -136,7 +136,7 @@ bool ED_mask_find_nearest_diff_point(const struct bContext *C,
bool ED_mask_feather_find_nearest(const struct bContext *C,
struct Mask *mask,
const float normal_co[2],
- const float threshold,
+ float threshold,
struct MaskLayer **r_mask_layer,
struct MaskSpline **r_spline,
struct MaskSplinePoint **r_point,
@@ -145,7 +145,7 @@ bool ED_mask_feather_find_nearest(const struct bContext *C,
struct MaskSplinePoint *ED_mask_point_find_nearest(const struct bContext *C,
struct Mask *mask,
const float normal_co[2],
- const float threshold,
+ float threshold,
struct MaskLayer **r_mask_layer,
struct MaskSpline **r_spline,
eMaskWhichHandle *r_which_handle,
diff --git a/source/blender/editors/mesh/mesh_intern.h b/source/blender/editors/mesh/mesh_intern.h
index bba142133a6..575e6d66ccd 100644
--- a/source/blender/editors/mesh/mesh_intern.h
+++ b/source/blender/editors/mesh/mesh_intern.h
@@ -48,7 +48,7 @@ bool EDBM_op_callf(struct BMEditMesh *em, struct wmOperator *op, const char *fmt
bool EDBM_op_call_and_selectf(struct BMEditMesh *em,
struct wmOperator *op,
const char *select_slot,
- const bool select_replace,
+ bool select_replace,
const char *fmt,
...);
/**
@@ -74,7 +74,7 @@ bool EDBM_op_init(
bool EDBM_op_finish(struct BMEditMesh *em,
struct BMOperator *bmop,
struct wmOperator *op,
- const bool do_report);
+ bool do_report);
void EDBM_stats_update(struct BMEditMesh *em);
@@ -110,8 +110,8 @@ struct BMElem *EDBM_elem_from_index_any_multi(struct ViewLayer *view_layer,
*/
bool edbm_extrude_edges_indiv(struct BMEditMesh *em,
struct wmOperator *op,
- const char hflag,
- const bool use_normal_flip);
+ char hflag,
+ bool use_normal_flip);
/* *** editmesh_add.c *** */
diff --git a/source/blender/editors/object/object_intern.h b/source/blender/editors/object/object_intern.h
index 9a1b4b48464..d517d68f1fc 100644
--- a/source/blender/editors/object/object_intern.h
+++ b/source/blender/editors/object/object_intern.h
@@ -176,8 +176,8 @@ void COLLECTION_OT_objects_remove_active(struct wmOperatorType *ot);
bool edit_modifier_poll_generic(struct bContext *C,
struct StructRNA *rna_type,
int obtype_flag,
- const bool is_editmode_allowed,
- const bool is_liboverride_allowed);
+ bool is_editmode_allowed,
+ bool is_liboverride_allowed);
void edit_modifier_properties(struct wmOperatorType *ot);
bool edit_modifier_invoke_properties(struct bContext *C, struct wmOperator *op);
diff --git a/source/blender/editors/screen/screen_intern.h b/source/blender/editors/screen/screen_intern.h
index bc06e46ba96..e42c891b0ba 100644
--- a/source/blender/editors/screen/screen_intern.h
+++ b/source/blender/editors/screen/screen_intern.h
@@ -71,10 +71,10 @@ typedef enum eScreenAxis {
/**
* we swap spaces for fullscreen to keep all allocated data area vertices were set
*/
-void ED_area_data_copy(ScrArea *area_dst, ScrArea *area_src, const bool do_free);
+void ED_area_data_copy(ScrArea *area_dst, ScrArea *area_src, bool do_free);
void ED_area_data_swap(ScrArea *area_dst, ScrArea *area_src);
/* for quick toggle, can skip fades */
-void region_toggle_hidden(struct bContext *C, ARegion *region, const bool do_fade);
+void region_toggle_hidden(struct bContext *C, ARegion *region, bool do_fade);
/* screen_draw.c */
@@ -85,7 +85,7 @@ void region_toggle_hidden(struct bContext *C, ARegion *region, const bool do_fad
* \param sa2: Target area that will be replaced.
*/
void screen_draw_join_highlight(struct ScrArea *sa1, struct ScrArea *sa2);
-void screen_draw_split_preview(struct ScrArea *area, const eScreenAxis dir_axis, const float fac);
+void screen_draw_split_preview(struct ScrArea *area, eScreenAxis dir_axis, float fac);
/* screen_edit.c */
@@ -111,9 +111,9 @@ void screen_change_prepare(bScreen *screen_old,
ScrArea *area_split(const wmWindow *win,
bScreen *screen,
ScrArea *area,
- const eScreenAxis dir_axis,
- const float fac,
- const bool merge);
+ eScreenAxis dir_axis,
+ float fac,
+ bool merge);
/**
* Join any two neighboring areas. Might involve complex changes.
*/
@@ -127,8 +127,7 @@ eScreenDir area_getorientation(ScrArea *sa_a, ScrArea *sa_b);
/**
* Get alignment offset of adjacent areas. 'dir' value is like #area_getorientation().
*/
-void area_getoffsets(
- ScrArea *sa_a, ScrArea *sa_b, const eScreenDir dir, int *r_offset1, int *r_offset2);
+void area_getoffsets(ScrArea *sa_a, ScrArea *sa_b, eScreenDir dir, int *r_offset1, int *r_offset2);
/**
* Close a screen area, allowing most-aligned neighbor to take its place.
*/
@@ -150,15 +149,15 @@ bool screen_geom_edge_is_horizontal(ScrEdge *se);
*/
ScrEdge *screen_geom_area_map_find_active_scredge(const struct ScrAreaMap *area_map,
const rcti *bounds_rect,
- const int mx,
- const int my);
+ int mx,
+ int my);
/**
* Need win size to make sure not to include edges along screen edge.
*/
ScrEdge *screen_geom_find_active_scredge(const wmWindow *win,
const bScreen *screen,
- const int mx,
- const int my);
+ int mx,
+ int my);
/**
* \brief Main screen-layout calculation function.
*
@@ -172,7 +171,7 @@ void screen_geom_vertices_scale(const wmWindow *win, bScreen *screen);
*/
short screen_geom_find_area_split_point(const ScrArea *area,
const rcti *window_rect,
- const eScreenAxis dir_axis,
+ eScreenAxis dir_axis,
float fac);
/**
* Select all edges that are directly or indirectly connected to \a edge.
diff --git a/source/blender/editors/sculpt_paint/paint_intern.h b/source/blender/editors/sculpt_paint/paint_intern.h
index 09013ea00f4..d31390bbb42 100644
--- a/source/blender/editors/sculpt_paint/paint_intern.h
+++ b/source/blender/editors/sculpt_paint/paint_intern.h
@@ -152,10 +152,7 @@ unsigned int vpaint_get_current_col(struct Scene *scene, struct VPaint *vp, bool
/**
* \note weight-paint has an equivalent function: #ED_wpaint_blend_tool
*/
-unsigned int ED_vpaint_blend_tool(const int tool,
- const uint col,
- const uint paintcol,
- const int alpha_i);
+unsigned int ED_vpaint_blend_tool(int tool, uint col, uint paintcol, int alpha_i);
/**
* Apply callback to each vertex of the active vertex color layer.
*/
@@ -173,10 +170,7 @@ bool ED_vpaint_color_transform(struct Object *ob,
*
* \note vertex-paint has an equivalent function: #ED_vpaint_blend_tool
*/
-float ED_wpaint_blend_tool(const int tool,
- const float weight,
- const float paintval,
- const float alpha);
+float ED_wpaint_blend_tool(int tool, float weight, float paintval, float alpha);
/* Utility for tools to ensure vertex groups exist before they begin. */
enum eWPaintFlag {
WPAINT_ENSURE_MIRROR = (1 << 0),
@@ -193,7 +187,7 @@ bool ED_wpaint_ensure_data(struct bContext *C,
enum eWPaintFlag flag,
struct WPaintVGroupIndex *vgroup_index);
/** Return -1 when invalid. */
-int ED_wpaint_mirror_vgroup_ensure(struct Object *ob, const int vgroup_active);
+int ED_wpaint_mirror_vgroup_ensure(struct Object *ob, int vgroup_active);
/* paint_vertex_color_ops.c */
@@ -246,7 +240,7 @@ void paint_2d_stroke_done(void *ps);
void paint_2d_stroke(void *ps,
const float prev_mval[2],
const float mval[2],
- const bool eraser,
+ bool eraser,
float pressure,
float distance,
float size);
@@ -269,7 +263,7 @@ void paint_proj_stroke(const struct bContext *C,
void *ps_handle_p,
const float prev_pos[2],
const float pos[2],
- const bool eraser,
+ bool eraser,
float pressure,
float distance,
float size);
@@ -333,8 +327,8 @@ typedef struct CurveMaskCache {
void paint_curve_mask_cache_free_data(CurveMaskCache *curve_mask_cache);
void paint_curve_mask_cache_update(CurveMaskCache *curve_mask_cache,
const struct Brush *brush,
- const int diameter,
- const float radius,
+ int diameter,
+ float radius,
const float cursor_position[2]);
/* sculpt_uv.c */
diff --git a/source/blender/editors/sculpt_paint/sculpt_intern.h b/source/blender/editors/sculpt_paint/sculpt_intern.h
index f239d12b69e..cc6044488af 100644
--- a/source/blender/editors/sculpt_paint/sculpt_intern.h
+++ b/source/blender/editors/sculpt_paint/sculpt_intern.h
@@ -139,7 +139,7 @@ void SCULPT_vertex_limit_surface_get(SculptSession *ss, int index, float r_co[3]
* depending on the given deformation target.
*/
float *SCULPT_brush_deform_target_vertex_co_get(SculptSession *ss,
- const int deform_target,
+ int deform_target,
PBVHVertexIter *iter);
#define SCULPT_VERTEX_NEIGHBOR_FIXED_CAPACITY 256
@@ -160,8 +160,8 @@ typedef struct SculptVertexNeighborIter {
} SculptVertexNeighborIter;
void SCULPT_vertex_neighbors_get(struct SculptSession *ss,
- const int index,
- const bool include_duplicates,
+ int index,
+ bool include_duplicates,
SculptVertexNeighborIter *iter);
/* Iterator over neighboring vertices. */
@@ -200,7 +200,7 @@ struct MVert *SCULPT_mesh_deformed_mverts_get(SculptSession *ss);
#define FAKE_NEIGHBOR_NONE -1
-void SCULPT_fake_neighbors_ensure(struct Sculpt *sd, Object *ob, const float max_dist);
+void SCULPT_fake_neighbors_ensure(struct Sculpt *sd, Object *ob, float max_dist);
void SCULPT_fake_neighbors_enable(Object *ob);
void SCULPT_fake_neighbors_disable(Object *ob);
void SCULPT_fake_neighbors_free(struct Object *ob);
@@ -208,7 +208,7 @@ void SCULPT_fake_neighbors_free(struct Object *ob);
/* Vertex Info. */
void SCULPT_boundary_info_ensure(Object *object);
/* Boundary Info needs to be initialized in order to use this function. */
-bool SCULPT_vertex_is_boundary(const SculptSession *ss, const int index);
+bool SCULPT_vertex_is_boundary(const SculptSession *ss, int index);
void SCULPT_connected_components_ensure(Object *ob);
@@ -327,7 +327,7 @@ void SCULPT_clip(Sculpt *sd, SculptSession *ss, float co[3], const float val[3])
float SCULPT_brush_plane_offset_get(Sculpt *sd, SculptSession *ss);
ePaintSymmetryAreas SCULPT_get_vertex_symm_area(const float co[3]);
-bool SCULPT_check_vertex_pivot_symmetry(const float vco[3], const float pco[3], const char symm);
+bool SCULPT_check_vertex_pivot_symmetry(const float vco[3], const float pco[3], char symm);
/**
* Checks if a vertex is inside the brush radius from any of its mirrored axis.
*/
@@ -337,12 +337,12 @@ bool SCULPT_is_vertex_inside_brush_radius_symm(const float vertex[3],
char symm);
bool SCULPT_is_symmetry_iteration_valid(char i, char symm);
void SCULPT_flip_v3_by_symm_area(float v[3],
- const ePaintSymmetryFlags symm,
- const ePaintSymmetryAreas symmarea,
+ ePaintSymmetryFlags symm,
+ ePaintSymmetryAreas symmarea,
const float pivot[3]);
void SCULPT_flip_quat_by_symm_area(float quat[4],
- const ePaintSymmetryFlags symm,
- const ePaintSymmetryAreas symmarea,
+ ePaintSymmetryFlags symm,
+ ePaintSymmetryAreas symmarea,
const float pivot[3]);
/* Flood Fill. */
@@ -420,9 +420,7 @@ struct AutomaskingCache *SCULPT_automasking_active_cache_get(SculptSession *ss);
struct AutomaskingCache *SCULPT_automasking_cache_init(Sculpt *sd, Brush *brush, Object *ob);
void SCULPT_automasking_cache_free(struct AutomaskingCache *automasking);
-bool SCULPT_is_automasking_mode_enabled(const Sculpt *sd,
- const Brush *br,
- const eAutomasking_flag mode);
+bool SCULPT_is_automasking_mode_enabled(const Sculpt *sd, const Brush *br, eAutomasking_flag mode);
bool SCULPT_is_automasking_enabled(const Sculpt *sd, const SculptSession *ss, const Brush *br);
typedef enum eBoundaryAutomaskMode {
@@ -444,19 +442,19 @@ float *SCULPT_boundary_automasking_init(Object *ob,
*/
float *SCULPT_geodesic_distances_create(struct Object *ob,
struct GSet *initial_vertices,
- const float limit_radius);
+ float limit_radius);
float *SCULPT_geodesic_from_vertex_and_symm(struct Sculpt *sd,
struct Object *ob,
- const int vertex,
- const float limit_radius);
-float *SCULPT_geodesic_from_vertex(Object *ob, const int vertex, const float limit_radius);
+ int vertex,
+ float limit_radius);
+float *SCULPT_geodesic_from_vertex(Object *ob, int vertex, float limit_radius);
/* Filters. */
-void SCULPT_filter_cache_init(struct bContext *C, Object *ob, Sculpt *sd, const int undo_type);
+void SCULPT_filter_cache_init(struct bContext *C, Object *ob, Sculpt *sd, int undo_type);
void SCULPT_filter_cache_free(SculptSession *ss);
void SCULPT_mask_filter_smooth_apply(
- Sculpt *sd, Object *ob, PBVHNode **nodes, const int totnode, const int smooth_iterations);
+ Sculpt *sd, Object *ob, PBVHNode **nodes, int totnode, int smooth_iterations);
/* Brushes. */
@@ -474,13 +472,12 @@ void SCULPT_cloth_simulation_free(struct SculptClothSimulation *cloth_sim);
/* Public functions. */
-struct SculptClothSimulation *SCULPT_cloth_brush_simulation_create(
- struct SculptSession *ss,
- const float cloth_mass,
- const float cloth_damping,
- const float cloth_softbody_strength,
- const bool use_collisions,
- const bool needs_deform_coords);
+struct SculptClothSimulation *SCULPT_cloth_brush_simulation_create(struct SculptSession *ss,
+ float cloth_mass,
+ float cloth_damping,
+ float cloth_softbody_strength,
+ bool use_collisions,
+ bool needs_deform_coords);
void SCULPT_cloth_brush_simulation_init(struct SculptSession *ss,
struct SculptClothSimulation *cloth_sim);
@@ -503,20 +500,20 @@ void SCULPT_cloth_brush_ensure_nodes_constraints(struct Sculpt *sd,
int totnode,
struct SculptClothSimulation *cloth_sim,
float initial_location[3],
- const float radius);
+ float radius);
/**
* Cursor drawing function.
*/
-void SCULPT_cloth_simulation_limits_draw(const uint gpuattr,
+void SCULPT_cloth_simulation_limits_draw(uint gpuattr,
const struct Brush *brush,
const float location[3],
const float normal[3],
- const float rds,
- const float line_width,
+ float rds,
+ float line_width,
const float outline_col[3],
- const float alpha);
-void SCULPT_cloth_plane_falloff_preview_draw(const uint gpuattr,
+ float alpha);
+void SCULPT_cloth_plane_falloff_preview_draw(uint gpuattr,
struct SculptSession *ss,
const float outline_col[3],
float outline_alpha);
@@ -601,7 +598,7 @@ struct SculptPoseIKChain *SCULPT_pose_ik_chain_init(struct Sculpt *sd,
struct SculptSession *ss,
struct Brush *br,
const float initial_location[3],
- const float radius);
+ float radius);
void SCULPT_pose_ik_chain_free(struct SculptPoseIKChain *ik_chain);
/* Boundary Brush. */
@@ -612,8 +609,8 @@ void SCULPT_pose_ik_chain_free(struct SculptPoseIKChain *ik_chain);
*/
struct SculptBoundary *SCULPT_boundary_data_init(Object *object,
Brush *brush,
- const int initial_vertex,
- const float radius);
+ int initial_vertex,
+ float radius);
void SCULPT_boundary_data_free(struct SculptBoundary *boundary);
/* Main Brush Function. */
void SCULPT_do_boundary_brush(struct Sculpt *sd,
@@ -621,20 +618,20 @@ void SCULPT_do_boundary_brush(struct Sculpt *sd,
struct PBVHNode **nodes,
int totnode);
-void SCULPT_boundary_edges_preview_draw(const uint gpuattr,
+void SCULPT_boundary_edges_preview_draw(uint gpuattr,
struct SculptSession *ss,
const float outline_col[3],
- const float outline_alpha);
-void SCULPT_boundary_pivot_line_preview_draw(const uint gpuattr, struct SculptSession *ss);
+ float outline_alpha);
+void SCULPT_boundary_pivot_line_preview_draw(uint gpuattr, struct SculptSession *ss);
/* Multi-plane Scrape Brush. */
/* Main Brush Function. */
void SCULPT_do_multiplane_scrape_brush(Sculpt *sd, Object *ob, PBVHNode **nodes, int totnode);
-void SCULPT_multiplane_scrape_preview_draw(const uint gpuattr,
+void SCULPT_multiplane_scrape_preview_draw(uint gpuattr,
Brush *brush,
SculptSession *ss,
const float outline_col[3],
- const float outline_alpha);
+ float outline_alpha);
/* Draw Face Sets Brush. */
void SCULPT_do_draw_face_sets_brush(Sculpt *sd, Object *ob, PBVHNode **nodes, int totnode);
@@ -661,12 +658,8 @@ void SCULPT_neighbor_color_average(SculptSession *ss, float result[4], int index
*/
void SCULPT_neighbor_coords_average_interior(SculptSession *ss, float result[3], int index);
-void SCULPT_smooth(Sculpt *sd,
- Object *ob,
- PBVHNode **nodes,
- const int totnode,
- float bstrength,
- const bool smooth_mask);
+void SCULPT_smooth(
+ Sculpt *sd, Object *ob, PBVHNode **nodes, int totnode, float bstrength, bool smooth_mask);
void SCULPT_do_smooth_brush(Sculpt *sd, Object *ob, PBVHNode **nodes, int totnode);
/* Surface Smooth Brush. */
@@ -675,15 +668,11 @@ void SCULPT_surface_smooth_laplacian_step(SculptSession *ss,
float *disp,
const float co[3],
float (*laplacian_disp)[3],
- const int v_index,
+ int v_index,
const float origco[3],
- const float alpha);
-void SCULPT_surface_smooth_displace_step(SculptSession *ss,
- float *co,
- float (*laplacian_disp)[3],
- const int v_index,
- const float beta,
- const float fade);
+ float alpha);
+void SCULPT_surface_smooth_displace_step(
+ SculptSession *ss, float *co, float (*laplacian_disp)[3], int v_index, float beta, float fade);
void SCULPT_do_surface_smooth_brush(Sculpt *sd, Object *ob, PBVHNode **nodes, int totnode);
/* Slide/Relax */
@@ -954,7 +943,7 @@ bool SCULPT_brush_test_sphere_fast(const SculptBrushTest *test, const float co[3
bool SCULPT_brush_test_cube(SculptBrushTest *test,
const float co[3],
const float local[4][4],
- const float roundness);
+ float roundness);
bool SCULPT_brush_test_circle_sq(SculptBrushTest *test, const float co[3]);
/**
* Test AABB against sphere.
@@ -977,19 +966,19 @@ const float *SCULPT_brush_frontface_normal_from_falloff_shape(SculptSession *ss,
float SCULPT_brush_strength_factor(struct SculptSession *ss,
const struct Brush *br,
const float point[3],
- const float len,
+ float len,
const short vno[3],
const float fno[3],
- const float mask,
- const int vertex_index,
- const int thread_id);
+ float mask,
+ int vertex_index,
+ int thread_id);
/**
* Tilts a normal by the x and y tilt values using the view axis.
*/
void SCULPT_tilt_apply_to_normal(float r_normal[3],
struct StrokeCache *cache,
- const float tilt_strength);
+ float tilt_strength);
/**
* Get effective surface normal with pen tilt and tilt strength applied to it.
@@ -1423,10 +1412,7 @@ typedef struct FilterCache {
* Flip all the edit-data across the axis/axes specified by \a symm.
* Used to calculate multiple modifications to the mesh when symmetry is enabled.
*/
-void SCULPT_cache_calc_brushdata_symm(StrokeCache *cache,
- const char symm,
- const char axis,
- const float angle);
+void SCULPT_cache_calc_brushdata_symm(StrokeCache *cache, char symm, char axis, float angle);
void SCULPT_cache_free(StrokeCache *cache);
SculptUndoNode *SCULPT_undo_push_node(Object *ob, PBVHNode *node, SculptUndoType type);
@@ -1434,7 +1420,7 @@ SculptUndoNode *SCULPT_undo_get_node(PBVHNode *node);
SculptUndoNode *SCULPT_undo_get_first_node(void);
void SCULPT_undo_push_begin(struct Object *ob, const char *name);
void SCULPT_undo_push_end(void);
-void SCULPT_undo_push_end_ex(const bool use_nested_undo);
+void SCULPT_undo_push_end_ex(bool use_nested_undo);
void SCULPT_vertcos_to_key(Object *ob, KeyBlock *kb, const float (*vertCos)[3]);
@@ -1615,11 +1601,8 @@ void SCULPT_do_mask_brush(struct Sculpt *sd,
struct PBVHNode **nodes,
int totnode);
-void SCULPT_bmesh_topology_rake(struct Sculpt *sd,
- struct Object *ob,
- struct PBVHNode **nodes,
- const int totnode,
- float bstrength);
+void SCULPT_bmesh_topology_rake(
+ struct Sculpt *sd, struct Object *ob, struct PBVHNode **nodes, int totnode, float bstrength);
/* end sculpt_brushes.c */
diff --git a/source/blender/editors/space_clip/clip_intern.h b/source/blender/editors/space_clip/clip_intern.h
index 20cc6e3da15..15f905f3157 100644
--- a/source/blender/editors/space_clip/clip_intern.h
+++ b/source/blender/editors/space_clip/clip_intern.h
@@ -184,7 +184,7 @@ void clip_delete_plane_track(struct bContext *C,
* Calculate space clip offset to be centered at the given point.
*/
void clip_view_offset_for_center_to_point(
- SpaceClip *sc, const float x, const float y, float *r_offset_x, float *r_offset_y);
+ SpaceClip *sc, float x, float y, float *r_offset_x, float *r_offset_y);
void clip_view_center_to_point(SpaceClip *sc, float x, float y);
bool clip_view_calculate_view_selection(
diff --git a/source/blender/editors/space_file/file_intern.h b/source/blender/editors/space_file/file_intern.h
index 3fe48157a09..4334beea196 100644
--- a/source/blender/editors/space_file/file_intern.h
+++ b/source/blender/editors/space_file/file_intern.h
@@ -128,7 +128,7 @@ void fileselect_refresh_params(struct SpaceFile *sfile);
/**
* Sets #FileSelectParams.file (name of selected file)
*/
-void fileselect_file_set(SpaceFile *sfile, const int index);
+void fileselect_file_set(SpaceFile *sfile, int index);
bool file_attribute_column_type_enabled(const FileSelectParams *params,
FileAttributeColumnType column);
/**
@@ -204,7 +204,7 @@ void file_tools_region_panels_register(struct ARegionType *art);
/* file_utils.c */
-void file_tile_boundbox(const ARegion *region, FileLayout *layout, const int file, rcti *r_bounds);
+void file_tile_boundbox(const ARegion *region, FileLayout *layout, int file, rcti *r_bounds);
/**
* If \a path leads to a .blend, remove the trailing slash (if needed).
diff --git a/source/blender/editors/space_file/filelist.h b/source/blender/editors/space_file/filelist.h
index 0119a9b4f52..696986d4660 100644
--- a/source/blender/editors/space_file/filelist.h
+++ b/source/blender/editors/space_file/filelist.h
@@ -62,16 +62,16 @@ void folder_history_list_ensure_for_active_browse_mode(struct SpaceFile *sfile);
void folder_history_list_free(struct SpaceFile *sfile);
struct ListBase folder_history_list_duplicate(struct ListBase *listbase);
-void filelist_setsorting(struct FileList *filelist, const short sort, bool invert_sort);
+void filelist_setsorting(struct FileList *filelist, short sort, bool invert_sort);
void filelist_sort(struct FileList *filelist);
void filelist_setfilter_options(struct FileList *filelist,
- const bool do_filter,
- const bool hide_dot,
- const bool hide_parent,
- const uint64_t filter,
- const uint64_t filter_id,
- const bool filter_assets_only,
+ bool do_filter,
+ bool hide_dot,
+ bool hide_parent,
+ uint64_t filter,
+ uint64_t filter_id,
+ bool filter_assets_only,
const char *filter_glob,
const char *filter_search);
/**
@@ -98,19 +98,19 @@ void filelist_setlibrary(struct FileList *filelist,
void filelist_init_icons(void);
void filelist_free_icons(void);
-struct ImBuf *filelist_getimage(struct FileList *filelist, const int index);
+struct ImBuf *filelist_getimage(struct FileList *filelist, int index);
struct ImBuf *filelist_file_getimage(const FileDirEntry *file);
struct ImBuf *filelist_geticon_image_ex(const FileDirEntry *file);
-struct ImBuf *filelist_geticon_image(struct FileList *filelist, const int index);
-int filelist_geticon(struct FileList *filelist, const int index, const bool is_main);
+struct ImBuf *filelist_geticon_image(struct FileList *filelist, int index);
+int filelist_geticon(struct FileList *filelist, int index, bool is_main);
struct FileList *filelist_new(short type);
void filelist_settype(struct FileList *filelist, short type);
void filelist_clear(struct FileList *filelist);
void filelist_clear_ex(struct FileList *filelist,
- const bool do_asset_library,
- const bool do_cache,
- const bool do_selection);
+ bool do_asset_library,
+ bool do_cache,
+ bool do_selection);
/**
* A "smarter" version of #filelist_clear() that calls partial clearing based on the filelist
* force-reset flags.
@@ -156,7 +156,7 @@ void filelist_file_cache_slidingwindow_set(struct FileList *filelist, size_t win
/**
* Load in cache all entries "around" given index (as much as block cache may hold).
*/
-bool filelist_file_cache_block(struct FileList *filelist, const int index);
+bool filelist_file_cache_block(struct FileList *filelist, int index);
bool filelist_needs_force_reset(struct FileList *filelist);
void filelist_tag_force_reset(struct FileList *filelist);
@@ -171,7 +171,7 @@ unsigned int filelist_entry_select_set(const struct FileList *filelist,
unsigned int flag,
FileCheckType check);
void filelist_entry_select_index_set(struct FileList *filelist,
- const int index,
+ int index,
FileSelType select,
unsigned int flag,
FileCheckType check);
@@ -184,9 +184,9 @@ unsigned int filelist_entry_select_get(struct FileList *filelist,
struct FileDirEntry *entry,
FileCheckType check);
unsigned int filelist_entry_select_index_get(struct FileList *filelist,
- const int index,
+ int index,
FileCheckType check);
-bool filelist_entry_is_selected(struct FileList *filelist, const int index);
+bool filelist_entry_is_selected(struct FileList *filelist, int index);
/**
* Set selection of the '..' parent entry, but only if it's actually visible.
*/
@@ -195,7 +195,7 @@ void filelist_entry_parent_select_set(struct FileList *filelist,
unsigned int flag,
FileCheckType check);
-void filelist_setrecursion(struct FileList *filelist, const int recursion_level);
+void filelist_setrecursion(struct FileList *filelist, int recursion_level);
struct AssetLibrary *filelist_asset_library(struct FileList *filelist);
@@ -213,7 +213,7 @@ void filelist_readjob_stop(struct FileList *filelist, struct wmWindowManager *wm
int filelist_readjob_running(struct FileList *filelist, struct wmWindowManager *wm);
bool filelist_cache_previews_update(struct FileList *filelist);
-void filelist_cache_previews_set(struct FileList *filelist, const bool use_previews);
+void filelist_cache_previews_set(struct FileList *filelist, bool use_previews);
bool filelist_cache_previews_running(struct FileList *filelist);
bool filelist_cache_previews_done(struct FileList *filelist);
diff --git a/source/blender/editors/space_file/fsmenu.h b/source/blender/editors/space_file/fsmenu.h
index 6296314d40a..0915c9a5a2f 100644
--- a/source/blender/editors/space_file/fsmenu.h
+++ b/source/blender/editors/space_file/fsmenu.h
@@ -42,7 +42,7 @@ void fsmenu_insert_entry(struct FSMenu *fsmenu,
const char *path,
const char *name,
int icon,
- const enum FSMenuInsert flag);
+ enum FSMenuInsert flag);
/** Refresh 'valid' status of given menu entry */
void fsmenu_entry_refresh_valid(struct FSMenuEntry *fsentry);
diff --git a/source/blender/editors/space_info/textview.h b/source/blender/editors/space_info/textview.h
index 96f537b4b97..38c073a328a 100644
--- a/source/blender/editors/space_info/textview.h
+++ b/source/blender/editors/space_info/textview.h
@@ -81,7 +81,7 @@ typedef struct TextViewContext {
* Use for selection.
*/
int textview_draw(struct TextViewContext *tvc,
- const bool do_draw,
+ bool do_draw,
const int mval_init[2],
void **r_mval_pick_item,
int *r_mval_pick_offset);
diff --git a/source/blender/editors/space_node/node_intern.hh b/source/blender/editors/space_node/node_intern.hh
index f3183acda50..0f542734f66 100644
--- a/source/blender/editors/space_node/node_intern.hh
+++ b/source/blender/editors/space_node/node_intern.hh
@@ -118,7 +118,7 @@ blender::float2 node_link_calculate_multi_input_position(const blender::float2 &
int total_inputs);
int node_get_resize_cursor(NodeResizeDirection directions);
-NodeResizeDirection node_get_resize_direction(const bNode *node, const int x, const int y);
+NodeResizeDirection node_get_resize_direction(const bNode *node, int x, int y);
/**
* Usual convention here would be #node_socket_get_color(),
* but that's already used (for setting a color property socket).
@@ -143,9 +143,9 @@ void node_keymap(wmKeyConfig *keyconf);
void node_deselect_all(SpaceNode &snode);
void node_socket_select(bNode *node, bNodeSocket &sock);
-void node_socket_deselect(bNode *node, bNodeSocket &sock, const bool deselect_node);
-void node_deselect_all_input_sockets(SpaceNode &snode, const bool deselect_nodes);
-void node_deselect_all_output_sockets(SpaceNode &snode, const bool deselect_nodes);
+void node_socket_deselect(bNode *node, bNodeSocket &sock, bool deselect_node);
+void node_deselect_all_input_sockets(SpaceNode &snode, bool deselect_nodes);
+void node_deselect_all_output_sockets(SpaceNode &snode, bool deselect_nodes);
void node_select_single(bContext &C, bNode &node);
void NODE_OT_select(wmOperatorType *ot);
@@ -196,7 +196,7 @@ bool node_link_bezier_points(const View2D *v2d,
const SpaceNode *snode,
const bNodeLink &link,
float coord_array[][2],
- const int resol);
+ int resol);
/**
* Return quadratic beziers points for a given nodelink and clip if v2d is not nullptr.
*/
diff --git a/source/blender/editors/space_outliner/outliner_intern.h b/source/blender/editors/space_outliner/outliner_intern.h
index 3439e4fa219..e331887319e 100644
--- a/source/blender/editors/space_outliner/outliner_intern.h
+++ b/source/blender/editors/space_outliner/outliner_intern.h
@@ -296,7 +296,7 @@ void outliner_collection_isolate_flag(struct Scene *scene,
struct Collection *collection,
struct PropertyRNA *layer_or_collection_prop,
const char *propname,
- const bool value);
+ bool value);
/**
* Return the index to use based on the TreeElement ID and object type
@@ -314,7 +314,7 @@ void tree_element_type_active_set(struct bContext *C,
const TreeViewContext *tvc,
TreeElement *te,
TreeStoreElem *tselem,
- const eOLSetState set,
+ eOLSetState set,
bool recursive);
/**
* Generic call for non-id data to check the active state in UI.
@@ -329,8 +329,8 @@ eOLDrawState tree_element_type_active_state_get(const struct bContext *C,
void tree_element_activate(struct bContext *C,
const TreeViewContext *tvc,
TreeElement *te,
- const eOLSetState set,
- const bool handle_all_types);
+ eOLSetState set,
+ bool handle_all_types);
eOLDrawState tree_element_active_state_get(const TreeViewContext *tvc,
const TreeElement *te,
const TreeStoreElem *tselem);
@@ -343,7 +343,7 @@ struct bPoseChannel *outliner_find_parent_bone(TreeElement *te, TreeElement **r_
void outliner_item_select(struct bContext *C,
struct SpaceOutliner *space_outliner,
struct TreeElement *te,
- const short select_flag);
+ short select_flag);
/**
* Find if x coordinate is over an icon or name.
@@ -366,7 +366,7 @@ bool outliner_is_co_within_mode_column(SpaceOutliner *space_outliner, const floa
void outliner_item_mode_toggle(struct bContext *C,
TreeViewContext *tvc,
TreeElement *te,
- const bool do_extend);
+ bool do_extend);
/* outliner_edit.c ---------------------------------------------- */
typedef void (*outliner_operation_fn)(struct bContext *C,
@@ -396,7 +396,7 @@ void outliner_do_object_operation(struct bContext *C,
struct ListBase *lb,
outliner_operation_fn operation_fn);
-int outliner_flag_is_any_test(ListBase *lb, short flag, const int curlevel);
+int outliner_flag_is_any_test(ListBase *lb, short flag, int curlevel);
/**
* Set or unset \a flag for all outliner elements in \a lb and sub-trees.
* \return if any flag was modified.
diff --git a/source/blender/editors/space_sequencer/sequencer_intern.h b/source/blender/editors/space_sequencer/sequencer_intern.h
index cb33c648b0a..8f7ab2ea881 100644
--- a/source/blender/editors/space_sequencer/sequencer_intern.h
+++ b/source/blender/editors/space_sequencer/sequencer_intern.h
@@ -57,12 +57,12 @@ void sequencer_draw_preview(const struct bContext *C,
bool draw_backdrop);
void color3ubv_from_seq(const struct Scene *curscene,
const struct Sequence *seq,
- const bool show_strip_color_tag,
+ bool show_strip_color_tag,
uchar r_col[3]);
void sequencer_special_update_set(Sequence *seq);
/* Get handle width in 2d-View space. */
-float sequence_handle_size_get_clamped(struct Sequence *seq, const float pixelx);
+float sequence_handle_size_get_clamped(struct Sequence *seq, float pixelx);
/* UNUSED */
/* void seq_reset_imageofs(struct SpaceSeq *sseq); */
diff --git a/source/blender/editors/space_spreadsheet/spreadsheet_column.hh b/source/blender/editors/space_spreadsheet/spreadsheet_column.hh
index 1a03278acad..7dad505c21b 100644
--- a/source/blender/editors/space_spreadsheet/spreadsheet_column.hh
+++ b/source/blender/editors/space_spreadsheet/spreadsheet_column.hh
@@ -44,7 +44,7 @@ void spreadsheet_column_id_free(SpreadsheetColumnID *column_id);
SpreadsheetColumn *spreadsheet_column_new(SpreadsheetColumnID *column_id);
SpreadsheetColumn *spreadsheet_column_copy(const SpreadsheetColumn *src_column);
void spreadsheet_column_assign_runtime_data(SpreadsheetColumn *column,
- const eSpreadsheetColumnValueType data_type,
+ eSpreadsheetColumnValueType data_type,
const StringRefNull display_name);
void spreadsheet_column_free(SpreadsheetColumn *column);
diff --git a/source/blender/editors/space_text/text_format.h b/source/blender/editors/space_text/text_format.h
index 01c40b4ed22..ebccaa54342 100644
--- a/source/blender/editors/space_text/text_format.h
+++ b/source/blender/editors/space_text/text_format.h
@@ -66,12 +66,12 @@ int text_check_format_len(TextLine *line, unsigned int len);
*
* \param len: length in bytes of \a fmt_p to fill.
*/
-void text_format_fill(const char **str_p, char **fmt_p, const char type, const int len);
+void text_format_fill(const char **str_p, char **fmt_p, char type, int len);
/**
* ASCII version of #text_format_fill,
* use when we no the text being stepped over is ascii (as is the case for most keywords)
*/
-void text_format_fill_ascii(const char **str_p, char **fmt_p, const char type, const int len);
+void text_format_fill_ascii(const char **str_p, char **fmt_p, char type, int len);
/* *** Generalize Formatting *** */
typedef struct TextFormatType {
@@ -88,7 +88,7 @@ typedef struct TextFormatType {
*
* See: FMT_TYPE_ enums below
*/
- void (*format_line)(SpaceText *st, TextLine *line, const bool do_next);
+ void (*format_line)(SpaceText *st, TextLine *line, bool do_next);
const char **ext; /* NULL terminated extensions */
} TextFormatType;
diff --git a/source/blender/editors/space_text/text_intern.h b/source/blender/editors/space_text/text_intern.h
index 3cae4188932..0b81cd74a42 100644
--- a/source/blender/editors/space_text/text_intern.h
+++ b/source/blender/editors/space_text/text_intern.h
@@ -42,7 +42,7 @@ void text_update_character_width(struct SpaceText *st);
/**
* Takes an area instead of a region, use for listeners.
*/
-void text_scroll_to_cursor__area(struct SpaceText *st, struct ScrArea *area, const bool center);
+void text_scroll_to_cursor__area(struct SpaceText *st, struct ScrArea *area, bool center);
void text_update_cursor_moved(struct bContext *C);
/* Padding around line numbers in character widths. */
diff --git a/source/blender/editors/space_view3d/view3d_intern.h b/source/blender/editors/space_view3d/view3d_intern.h
index 7388004125c..6a1a09df316 100644
--- a/source/blender/editors/space_view3d/view3d_intern.h
+++ b/source/blender/editors/space_view3d/view3d_intern.h
@@ -115,8 +115,8 @@ struct wmNDOFMotionData;
void view3d_ndof_fly(const struct wmNDOFMotionData *ndof,
struct View3D *v3d,
struct RegionView3D *rv3d,
- const bool use_precision,
- const short protectflag,
+ bool use_precision,
+ short protectflag,
bool *r_has_translate,
bool *r_has_rotate);
#endif /* WITH_INPUT_NDOF */
@@ -203,13 +203,13 @@ void ED_view3d_smooth_view_ex(const struct Depsgraph *depsgraph,
struct ScrArea *area,
struct View3D *v3d,
struct ARegion *region,
- const int smooth_viewtx,
+ int smooth_viewtx,
const V3D_SmoothParams *sview);
void ED_view3d_smooth_view(struct bContext *C,
struct View3D *v3d,
struct ARegion *region,
- const int smooth_viewtx,
+ int smooth_viewtx,
const V3D_SmoothParams *sview);
/**
@@ -274,17 +274,17 @@ struct View3DCameraControl *ED_view3d_cameracontrol_acquire(struct Depsgraph *de
* Updates cameras from the `rv3d` values, optionally auto-keyframing.
*/
void ED_view3d_cameracontrol_update(struct View3DCameraControl *vctrl,
- const bool use_autokey,
+ bool use_autokey,
struct bContext *C,
- const bool do_rotate,
- const bool do_translate);
+ bool do_rotate,
+ bool do_translate);
/**
* Release view control.
*
* \param restore: Sets the view state to the values that were set
* before #ED_view3d_control_acquire was called.
*/
-void ED_view3d_cameracontrol_release(struct View3DCameraControl *vctrl, const bool restore);
+void ED_view3d_cameracontrol_release(struct View3DCameraControl *vctrl, bool restore);
/**
* Returns the object which is being manipulated or NULL.
*/
diff --git a/source/blender/editors/transform/transform.h b/source/blender/editors/transform/transform.h
index 3035d11d0e3..642de550812 100644
--- a/source/blender/editors/transform/transform.h
+++ b/source/blender/editors/transform/transform.h
@@ -712,9 +712,9 @@ int transformEnd(struct bContext *C, TransInfo *t);
void setTransformViewMatrices(TransInfo *t);
void setTransformViewAspect(TransInfo *t, float r_aspect[3]);
void convertViewVec(TransInfo *t, float r_vec[3], double dx, double dy);
-void projectIntViewEx(TransInfo *t, const float vec[3], int adr[2], const eV3DProjTest flag);
+void projectIntViewEx(TransInfo *t, const float vec[3], int adr[2], eV3DProjTest flag);
void projectIntView(TransInfo *t, const float vec[3], int adr[2]);
-void projectFloatViewEx(TransInfo *t, const float vec[3], float adr[2], const eV3DProjTest flag);
+void projectFloatViewEx(TransInfo *t, const float vec[3], float adr[2], eV3DProjTest flag);
void projectFloatView(TransInfo *t, const float vec[3], float adr[2]);
void applyAspectRatio(TransInfo *t, float vec[2]);
@@ -770,7 +770,7 @@ typedef enum {
} MouseInputMode;
void initMouseInput(
- TransInfo *t, MouseInput *mi, const float center[2], const int mval[2], const bool precision);
+ TransInfo *t, MouseInput *mi, const float center[2], const int mval[2], bool precision);
void initMouseInputMode(TransInfo *t, MouseInput *mi, MouseInputMode mode);
void applyMouseInput(struct TransInfo *t,
struct MouseInput *mi,
diff --git a/source/blender/editors/transform/transform_convert.h b/source/blender/editors/transform/transform_convert.h
index 12f3b39927e..c40f3c28a79 100644
--- a/source/blender/editors/transform/transform_convert.h
+++ b/source/blender/editors/transform/transform_convert.h
@@ -48,9 +48,9 @@ int special_transform_moving(TransInfo *t);
void special_aftertrans_update(struct bContext *C, TransInfo *t);
void sort_trans_data_dist(TransInfo *t);
void createTransData(struct bContext *C, TransInfo *t);
-bool clipUVTransform(TransInfo *t, float vec[2], const bool resize);
+bool clipUVTransform(TransInfo *t, float vec[2], bool resize);
void clipUVData(TransInfo *t);
-void transform_convert_flush_handle2D(TransData *td, TransData2D *td2d, const float y_fac);
+void transform_convert_flush_handle2D(TransData *td, TransData2D *td2d, float y_fac);
/**
* Called for updating while transform acts, once per redraw.
*/
@@ -83,7 +83,7 @@ void transform_around_single_fallback(TransInfo *t);
* but may want to use a different one at times (if caller does not operate on
* selection).
*/
-void posttrans_fcurve_clean(struct FCurve *fcu, const int sel_flag, const bool use_handle);
+void posttrans_fcurve_clean(struct FCurve *fcu, int sel_flag, bool use_handle);
/**
* Little helper function for ObjectToTransData used to give certain
* constraints (ChildOf, FollowPath, and others that may be added)
@@ -125,8 +125,8 @@ void special_aftertrans_update__actedit(bContext *C, TransInfo *t);
* Returns total number of bones with #BONE_TRANSFORM.
*/
int transform_convert_pose_transflags_update(Object *ob,
- const int mode,
- const short around,
+ int mode,
+ short around,
bool has_translate_rotate[2]);
/**
* When objects array is NULL, use 't->data_container' as is.
@@ -208,9 +208,9 @@ struct TransMeshDataCrazySpace {
};
void transform_convert_mesh_islands_calc(struct BMEditMesh *em,
- const bool calc_single_islands,
- const bool calc_island_center,
- const bool calc_island_axismtx,
+ bool calc_single_islands,
+ bool calc_island_center,
+ bool calc_island_axismtx,
struct TransIslandData *r_island_data);
void transform_convert_mesh_islanddata_free(struct TransIslandData *island_data);
/**
@@ -223,8 +223,8 @@ void transform_convert_mesh_connectivity_distance(struct BMesh *bm,
float *dists,
int *index);
void transform_convert_mesh_mirrordata_calc(struct BMEditMesh *em,
- const bool use_select,
- const bool use_topology,
+ bool use_select,
+ bool use_topology,
const bool mirror_axis[3],
struct TransMirrorData *r_mirror_data);
void transform_convert_mesh_mirrordata_free(struct TransMirrorData *mirror_data);
diff --git a/source/blender/editors/transform/transform_mode.h b/source/blender/editors/transform/transform_mode.h
index ec3d5b8d0fe..cdcda5a8648 100644
--- a/source/blender/editors/transform/transform_mode.h
+++ b/source/blender/editors/transform/transform_mode.h
@@ -45,7 +45,7 @@ bool transdata_check_local_center(const TransInfo *t, short around);
/**
* Informs if the mode can be switched during modal.
*/
-bool transform_mode_is_changeable(const int mode);
+bool transform_mode_is_changeable(int mode);
void protectedTransBits(short protectflag, float vec[3]);
void protectedSizeBits(short protectflag, float size[3]);
void constraintTransLim(const TransInfo *t, TransData *td);
@@ -69,13 +69,13 @@ void ElementRotation(const TransInfo *t,
const TransDataContainer *tc,
TransData *td,
const float mat[3][3],
- const short around);
+ short around);
void headerResize(TransInfo *t, const float vec[3], char *str, int str_size);
void ElementResize(const TransInfo *t,
const TransDataContainer *tc,
TransData *td,
const float mat[3][3]);
-void transform_mode_init(TransInfo *t, struct wmOperator *op, const int mode);
+void transform_mode_init(TransInfo *t, struct wmOperator *op, int mode);
/**
* When in modal and not set, initializes a default orientation for the mode.
*/
diff --git a/source/blender/editors/transform/transform_orientations.h b/source/blender/editors/transform/transform_orientations.h
index 6e0e3d9f8c7..dd2d5bc86c5 100644
--- a/source/blender/editors/transform/transform_orientations.h
+++ b/source/blender/editors/transform/transform_orientations.h
@@ -34,8 +34,8 @@ short transform_orientation_matrix_get(struct bContext *C,
short orient_index,
const float custom[3][3],
float r_spacemtx[3][3]);
-const char *transform_orientations_spacename_get(struct TransInfo *t, const short orient_type);
-void transform_orientations_current_set(struct TransInfo *t, const short orient_index);
+const char *transform_orientations_spacename_get(struct TransInfo *t, short orient_type);
+void transform_orientations_current_set(struct TransInfo *t, short orient_index);
/**
* Those two fill in mat and return non-zero on success.
@@ -55,7 +55,7 @@ bool createSpaceNormalTangent(float mat[3][3], const float normal[3], const floa
struct TransformOrientation *addMatrixSpace(struct bContext *C,
float mat[3][3],
const char *name,
- const bool overwrite);
+ bool overwrite);
void applyTransformOrientation(const struct TransformOrientation *ts,
float r_mat[3][3],
char r_name[64]);
@@ -75,5 +75,5 @@ int getTransformOrientation_ex(ViewLayer *view_layer,
struct Object *obedit,
float normal[3],
float plane[3],
- const short around);
+ short around);
int getTransformOrientation(const struct bContext *C, float normal[3], float plane[3]);
diff --git a/source/blender/editors/transform/transform_snap.h b/source/blender/editors/transform/transform_snap.h
index bc89c7a8cda..389c1441db1 100644
--- a/source/blender/editors/transform/transform_snap.h
+++ b/source/blender/editors/transform/transform_snap.h
@@ -27,7 +27,7 @@
bool peelObjectsTransform(struct TransInfo *t,
const float mval[2],
- const bool use_peel_object,
+ bool use_peel_object,
/* return args */
float r_loc[3],
float r_no[3],
@@ -92,9 +92,9 @@ void transform_snap_sequencer_apply_translate(TransInfo *t, float *vec);
*/
short getAnimEdit_SnapMode(TransInfo *t);
void snapFrameTransform(TransInfo *t,
- const eAnimEdit_AutoSnap autosnap,
- const float val_initial,
- const float val_final,
+ eAnimEdit_AutoSnap autosnap,
+ float val_initial,
+ float val_final,
float *r_val_final);
/**
* This function is used by Animation Editor specific transform functions to do
@@ -102,5 +102,5 @@ void snapFrameTransform(TransInfo *t,
*/
void transform_snap_anim_flush_data(TransInfo *t,
TransData *td,
- const eAnimEdit_AutoSnap autosnap,
+ eAnimEdit_AutoSnap autosnap,
float *r_val_final);
diff --git a/source/blender/editors/uvedit/uvedit_intern.h b/source/blender/editors/uvedit/uvedit_intern.h
index 1fa96a932ed..9646444c103 100644
--- a/source/blender/editors/uvedit/uvedit_intern.h
+++ b/source/blender/editors/uvedit/uvedit_intern.h
@@ -74,13 +74,13 @@ typedef struct UvNearestHit {
bool uv_find_nearest_vert(struct Scene *scene,
struct Object *obedit,
const float co[2],
- const float penalty_dist,
+ float penalty_dist,
struct UvNearestHit *hit);
bool uv_find_nearest_vert_multi(struct Scene *scene,
struct Object **objects,
- const uint objects_len,
+ uint objects_len,
const float co[2],
- const float penalty_dist,
+ float penalty_dist,
struct UvNearestHit *hit);
bool uv_find_nearest_edge(struct Scene *scene,
@@ -89,7 +89,7 @@ bool uv_find_nearest_edge(struct Scene *scene,
struct UvNearestHit *hit);
bool uv_find_nearest_edge_multi(struct Scene *scene,
struct Object **objects,
- const uint objects_len,
+ uint objects_len,
const float co[2],
struct UvNearestHit *hit);
@@ -106,20 +106,20 @@ bool uv_find_nearest_face_ex(struct Scene *scene,
struct Object *obedit,
const float co[2],
struct UvNearestHit *hit,
- const bool only_in_face);
+ bool only_in_face);
bool uv_find_nearest_face(struct Scene *scene,
struct Object *obedit,
const float co[2],
struct UvNearestHit *hit);
bool uv_find_nearest_face_multi_ex(struct Scene *scene,
struct Object **objects,
- const uint objects_len,
+ uint objects_len,
const float co[2],
struct UvNearestHit *hit,
- const bool only_in_face);
+ bool only_in_face);
bool uv_find_nearest_face_multi(struct Scene *scene,
struct Object **objects,
- const uint objects_len,
+ uint objects_len,
const float co[2],
struct UvNearestHit *hit);
@@ -162,14 +162,14 @@ void UV_OT_shortest_path_select(struct wmOperatorType *ot);
bool uvedit_select_is_any_selected(struct Scene *scene, struct Object *obedit);
bool uvedit_select_is_any_selected_multi(struct Scene *scene,
struct Object **objects,
- const uint objects_len);
+ uint objects_len);
/**
* \warning This returns first selected UV,
* not ideal in many cases since there could be multiple.
*/
const float *uvedit_first_selected_uv_from_vertex(struct Scene *scene,
struct BMVert *eve,
- const int cd_loop_uv_offset);
+ int cd_loop_uv_offset);
void UV_OT_select_all(struct wmOperatorType *ot);
void UV_OT_select(struct wmOperatorType *ot);