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 <ideasman42@gmail.com>2020-08-02 10:17:31 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-08-02 11:02:20 +0300
commit70d7805fa901d9678db3557f6e81877b6b94128a (patch)
tree327bf818ee5ef37ad9aa36da5f1dfcfe48159f16 /source/blender/editors/include
parentba6ed0105814764f23bb00b98c33a0b76fde31b1 (diff)
Cleanup: pass const matrices
Also order return matrices last.
Diffstat (limited to 'source/blender/editors/include')
-rw-r--r--source/blender/editors/include/ED_armature.h8
-rw-r--r--source/blender/editors/include/ED_view3d.h28
-rw-r--r--source/blender/editors/include/ED_view3d_offscreen.h8
3 files changed, 23 insertions, 21 deletions
diff --git a/source/blender/editors/include/ED_armature.h b/source/blender/editors/include/ED_armature.h
index d82c7126cf2..6749adb2ea0 100644
--- a/source/blender/editors/include/ED_armature.h
+++ b/source/blender/editors/include/ED_armature.h
@@ -225,10 +225,10 @@ void ED_armature_ebone_remove(struct bArmature *arm, EditBone *exBone);
bool ED_armature_ebone_is_child_recursive(EditBone *ebone_parent, EditBone *ebone_child);
EditBone *ED_armature_ebone_find_shared_parent(EditBone *ebone_child[],
const unsigned int ebone_child_tot);
-void ED_armature_ebone_to_mat3(EditBone *ebone, float mat[3][3]);
-void ED_armature_ebone_to_mat4(EditBone *ebone, float mat[4][4]);
-void ED_armature_ebone_from_mat3(EditBone *ebone, float mat[3][3]);
-void ED_armature_ebone_from_mat4(EditBone *ebone, float mat[4][4]);
+void ED_armature_ebone_to_mat3(EditBone *ebone, float r_mat[3][3]);
+void ED_armature_ebone_to_mat4(EditBone *ebone, float r_mat[4][4]);
+void ED_armature_ebone_from_mat3(EditBone *ebone, const float mat[3][3]);
+void ED_armature_ebone_from_mat4(EditBone *ebone, const float mat[4][4]);
EditBone *ED_armature_ebone_find_name(const struct ListBase *edbo, const char *name);
EditBone *ED_armature_ebone_get_mirrored(const struct ListBase *edbo, EditBone *ebo);
void ED_armature_ebone_transform_mirror_update(struct bArmature *arm,
diff --git a/source/blender/editors/include/ED_view3d.h b/source/blender/editors/include/ED_view3d.h
index f44b099f42e..4060efbda92 100644
--- a/source/blender/editors/include/ED_view3d.h
+++ b/source/blender/editors/include/ED_view3d.h
@@ -135,13 +135,13 @@ 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,
- float cursor_co[3]);
+ float r_cursor_co[3]);
void ED_view3d_cursor3d_position_rotation(struct bContext *C,
const int mval[2],
const bool use_depth,
enum eV3DCursorOrient orientation,
- float cursor_co[3],
- float cursor_quat[4]);
+ 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,
@@ -403,10 +403,10 @@ bool ED_view3d_win_to_segment_clipped(struct Depsgraph *depsgraph,
const bool do_clip);
void ED_view3d_ob_project_mat_get(const struct RegionView3D *v3d,
struct Object *ob,
- float pmat[4][4]);
+ float r_pmat[4][4]);
void ED_view3d_ob_project_mat_get_from_obmat(const struct RegionView3D *rv3d,
- float obmat[4][4],
- float pmat[4][4]);
+ const float obmat[4][4],
+ float r_pmat[4][4]);
void ED_view3d_project(const struct ARegion *region, const float world[3], float r_region_co[3]);
bool ED_view3d_unproject(
@@ -460,7 +460,7 @@ void ED_view3d_clipping_calc(struct BoundBox *bb,
const struct ARegion *region,
const struct Object *ob,
const struct rcti *rect);
-void ED_view3d_clipping_local(struct RegionView3D *rv3d, float mat[4][4]);
+void ED_view3d_clipping_local(struct RegionView3D *rv3d, const float mat[4][4]);
bool ED_view3d_clipping_test(const struct RegionView3D *rv3d,
const float co[3],
const bool is_local);
@@ -601,8 +601,8 @@ void ED_view3d_draw_setup_view(const struct wmWindowManager *wm,
struct Scene *scene,
struct ARegion *region,
struct View3D *v3d,
- float viewmat[4][4],
- float winmat[4][4],
+ const float viewmat[4][4],
+ const float winmat[4][4],
const struct rcti *rect);
struct Base *ED_view3d_give_base_under_cursor(struct bContext *C, const int mval[2]);
@@ -613,11 +613,11 @@ void ED_view3d_update_viewmat(struct Depsgraph *depsgraph,
const struct Scene *scene,
struct View3D *v3d,
struct ARegion *region,
- float viewmat[4][4],
- float winmat[4][4],
+ const float viewmat[4][4],
+ 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 quat[4]);
+bool ED_view3d_quat_from_axis_view(const char view, const char view_axis_roll, float r_quat[4]);
bool ED_view3d_quat_to_axis_view(const float viewquat[4],
const float epsilon,
char *r_view,
@@ -676,7 +676,9 @@ void ED_view3d_lock_clear(struct View3D *v3d);
#define VIEW3D_MARGIN 1.4f
#define VIEW3D_DIST_FALLBACK 1.0f
-float ED_view3d_offset_distance(float mat[4][4], const float ofs[3], const float dist_fallback);
+float ED_view3d_offset_distance(const float mat[4][4],
+ const float ofs[3],
+ const float dist_fallback);
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],
diff --git a/source/blender/editors/include/ED_view3d_offscreen.h b/source/blender/editors/include/ED_view3d_offscreen.h
index 11d1aed1e73..846f4d7eabb 100644
--- a/source/blender/editors/include/ED_view3d_offscreen.h
+++ b/source/blender/editors/include/ED_view3d_offscreen.h
@@ -49,8 +49,8 @@ void ED_view3d_draw_offscreen(struct Depsgraph *depsgraph,
struct ARegion *region,
int winx,
int winy,
- float viewmat[4][4],
- float winmat[4][4],
+ const float viewmat[4][4],
+ const float winmat[4][4],
bool is_image_render,
bool do_sky,
bool is_persp,
@@ -65,8 +65,8 @@ void ED_view3d_draw_offscreen_simple(struct Depsgraph *depsgraph,
int winx,
int winy,
unsigned int draw_flags,
- float viewmat[4][4],
- float winmat[4][4],
+ const float viewmat[4][4],
+ const float winmat[4][4],
float clip_start,
float clip_end,
bool is_image_render,