Fix: Use ShaderCreateInfo for Cycles fallback display. #104981
|
@ -1511,29 +1511,16 @@ void compatible_eul(float eul[3], const float oldrot[3])
|
|||
}
|
||||
}
|
||||
|
||||
/* is 1 of the axis rotations larger than 180 degrees and the other small? NO ELSE IF!! */
|
||||
if (fabsf(deul[0]) > 3.2f && fabsf(deul[1]) < 1.6f && fabsf(deul[2]) < 1.6f) {
|
||||
if (deul[0] > 0.0f) {
|
||||
eul[0] -= pi_x2;
|
||||
}
|
||||
else {
|
||||
eul[0] += pi_x2;
|
||||
}
|
||||
}
|
||||
if (fabsf(deul[1]) > 3.2f && fabsf(deul[2]) < 1.6f && fabsf(deul[0]) < 1.6f) {
|
||||
if (deul[1] > 0.0f) {
|
||||
eul[1] -= pi_x2;
|
||||
}
|
||||
else {
|
||||
eul[1] += pi_x2;
|
||||
}
|
||||
}
|
||||
if (fabsf(deul[2]) > 3.2f && fabsf(deul[0]) < 1.6f && fabsf(deul[1]) < 1.6f) {
|
||||
if (deul[2] > 0.0f) {
|
||||
eul[2] -= pi_x2;
|
||||
}
|
||||
else {
|
||||
eul[2] += pi_x2;
|
||||
uint j = 1, k = 2;
|
||||
for (i = 0; i < 3; j = k, k = i++) {
|
||||
/* is 1 of the axis rotations larger than 180 degrees and the other small? */
|
||||
if (fabsf(deul[i]) > 3.2f && fabsf(deul[j]) < 1.6f && fabsf(deul[k]) < 1.6f) {
|
||||
if (deul[i] > 0.0f) {
|
||||
eul[i] -= pi_x2;
|
||||
}
|
||||
else {
|
||||
eul[i] += pi_x2;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue