Math Lib
* Post-conversion commit, fixing some introduced warnings.
This commit is contained in:
@@ -706,7 +706,7 @@ static void face_duplilist(ListBase *lb, ID *id, Scene *scene, Object *par, floa
|
||||
if(par->transflag & OB_DUPLIFACES_SCALE) {
|
||||
float size= v4? area_quad_v3(v1, v2, v3, v4): area_tri_v3(v1, v2, v3);
|
||||
size= sqrt(size) * par->dupfacesca;
|
||||
mul_m3_fl(mat[0], size);
|
||||
mul_m3_fl(mat, size);
|
||||
}
|
||||
|
||||
copy_m3_m3(mat3, mat);
|
||||
@@ -943,7 +943,7 @@ static void new_particle_duplilist(ListBase *lb, ID *id, Scene *scene, Object *p
|
||||
if(part->ren_as==PART_DRAW_GR && psys->part->draw & PART_DRAW_WHOLE_GR) {
|
||||
for(go= part->dup_group->gobject.first, b=0; go; go= go->next, b++) {
|
||||
mul_m4_m4m4(tmat, oblist[b]->obmat, pamat);
|
||||
mul_mat3_m4_fl((float *)tmat, size*scale);
|
||||
mul_mat3_m4_fl(tmat, size*scale);
|
||||
if(par_space_mat)
|
||||
mul_m4_m4m4(mat, tmat, par_space_mat);
|
||||
else
|
||||
@@ -965,7 +965,7 @@ static void new_particle_duplilist(ListBase *lb, ID *id, Scene *scene, Object *p
|
||||
copy_m4_m4(mat, pamat);
|
||||
|
||||
mul_m4_m4m4(tmat, obmat, mat);
|
||||
mul_mat3_m4_fl((float *)tmat, size*scale);
|
||||
mul_mat3_m4_fl(tmat, size*scale);
|
||||
|
||||
if(part->draw & PART_DRAW_GLOBAL_OB)
|
||||
VECADD(tmat[3], tmat[3], vec);
|
||||
|
||||
@@ -813,7 +813,7 @@ static void pchan_deform_mat_add(bPoseChannel *pchan, float weight, float bbonem
|
||||
else
|
||||
copy_m3_m4(wmat, pchan->chan_mat);
|
||||
|
||||
mul_m3_fl((float*)wmat, weight);
|
||||
mul_m3_fl(wmat, weight);
|
||||
add_m3_m3m3(mat, mat, wmat);
|
||||
}
|
||||
|
||||
@@ -1013,7 +1013,7 @@ void armature_deform_verts(Object *armOb, Object *target, DerivedMesh *dm,
|
||||
vec= sumvec;
|
||||
|
||||
if(defMats) {
|
||||
zero_m3((float*)summat);
|
||||
zero_m3(summat);
|
||||
smat = summat;
|
||||
}
|
||||
}
|
||||
@@ -1123,7 +1123,7 @@ void armature_deform_verts(Object *armOb, Object *target, DerivedMesh *dm,
|
||||
copy_m3_m3(tmpmat, defMats[i]);
|
||||
|
||||
if(!use_quaternion) /* quaternion already is scale corrected */
|
||||
mul_m3_fl((float*)smat, armature_weight/contrib);
|
||||
mul_m3_fl(smat, armature_weight/contrib);
|
||||
|
||||
mul_serie_m3(defMats[i], tmpmat, pre, smat, post,
|
||||
NULL, NULL, NULL, NULL);
|
||||
|
||||
@@ -479,7 +479,7 @@ static void init_fastshade_for_ob(Render *re, Object *ob, int *need_orco_r, floa
|
||||
|
||||
invert_m4_m4(tmat, mat);
|
||||
copy_m3_m4(imat, tmat);
|
||||
if(ob->transflag & OB_NEG_SCALE) mul_m3_fl((float *)imat, -1.0);
|
||||
if(ob->transflag & OB_NEG_SCALE) mul_m3_fl(imat, -1.0);
|
||||
|
||||
if (need_orco_r) *need_orco_r= 0;
|
||||
for(a=0; a<ob->totcol; a++) {
|
||||
|
||||
@@ -3974,7 +3974,7 @@ static DerivedMesh *uvprojectModifier_do(UVProjectModifierData *umd,
|
||||
}
|
||||
|
||||
unit_m4(offsetmat);
|
||||
mul_mat3_m4_fl(offsetmat[0], 0.5);
|
||||
mul_mat3_m4_fl(offsetmat, 0.5);
|
||||
offsetmat[3][0] = offsetmat[3][1] = offsetmat[3][2] = 0.5;
|
||||
|
||||
if (cam) {
|
||||
|
||||
@@ -1356,7 +1356,7 @@ static void project_face_pixel(const MTFace *tf_other, ImBuf *ibuf_other, const
|
||||
uvCo3 = (float *)tf_other->uv[2];
|
||||
}
|
||||
|
||||
interp_v2_v2v2v2(uv_other, uvCo1, uvCo2, uvCo3, w);
|
||||
interp_v2_v2v2v2(uv_other, uvCo1, uvCo2, uvCo3, (float*)w);
|
||||
|
||||
/* use */
|
||||
uvco_to_wrapped_pxco(uv_other, ibuf_other->x, ibuf_other->y, &x, &y);
|
||||
|
||||
@@ -1582,7 +1582,7 @@ static void draw_pose_channels(Scene *scene, View3D *v3d, ARegion *ar, Base *bas
|
||||
if (arm->drawtype==ARM_ENVELOPE) {
|
||||
/* precalc inverse matrix for drawing screen aligned */
|
||||
wmGetMatrix(smat);
|
||||
mul_mat3_m4_fl(smat[0], 1.0f/len_v3(ob->obmat[0]));
|
||||
mul_mat3_m4_fl(smat, 1.0f/len_v3(ob->obmat[0]));
|
||||
invert_m4_m4(imat, smat);
|
||||
|
||||
/* and draw blended distances */
|
||||
@@ -1931,7 +1931,7 @@ static void draw_ebones(View3D *v3d, ARegion *ar, Object *ob, int dt)
|
||||
if(arm->drawtype==ARM_ENVELOPE) {
|
||||
/* precalc inverse matrix for drawing screen aligned */
|
||||
wmGetMatrix(smat);
|
||||
mul_mat3_m4_fl(smat[0], 1.0f/len_v3(ob->obmat[0]));
|
||||
mul_mat3_m4_fl(smat, 1.0f/len_v3(ob->obmat[0]));
|
||||
invert_m4_m4(imat, smat);
|
||||
|
||||
/* and draw blended distances */
|
||||
|
||||
@@ -605,8 +605,8 @@ static void uv_map_rotation_matrix(float result[][4], RegionView3D *rv3d, Object
|
||||
for(k=0; k<4; k++)
|
||||
rotobj[3][k] =0.0f;
|
||||
|
||||
zero_m4(*rotup);
|
||||
zero_m4(*rotside);
|
||||
zero_m4(rotup);
|
||||
zero_m4(rotside);
|
||||
|
||||
/* compensate front/side.. against opengl x,y,z world definition */
|
||||
/* this is "kanonen gegen spatzen", a few plus minus 1 will do here */
|
||||
|
||||
Reference in New Issue
Block a user