Fix T50148: Header: Wrong rounding when moving frames

Deduplicate the code and use the same logic used to
calculate individual elements in `t->values_final[0]`.

Differential revision: https://developer.blender.org/D6135
This commit is contained in:
2019-10-28 09:51:53 -03:00
parent a83bbefec6
commit ce0db668ec
3 changed files with 57 additions and 54 deletions

View File

@@ -206,6 +206,12 @@ bool snapNodesTransform(struct TransInfo *t,
float r_loc[2],
float *r_dist_px,
char *r_node_border);
void snapFrameTransform(struct TransInfo *t,
const short autosnap,
const bool is_frame_value,
const float delta,
/* return args */
float *r_val);
void ED_transform_calc_orientation_from_type(const struct bContext *C, float r_mat[3][3]);
void ED_transform_calc_orientation_from_type_ex(const struct bContext *C,