mirror of
https://github.com/nzp-team/dquakeplus.git
synced 2024-12-02 00:22:05 +00:00
10 lines
391 B
C
10 lines
391 B
C
#include "pspmath.h"
|
|
|
|
void vfpu_quaternion_multiply(ScePspQuatMatrix *qout, ScePspQuatMatrix *a, ScePspQuatMatrix *b) {
|
|
__asm__ volatile (
|
|
"lv.q C000, %1\n" // load quaternion a
|
|
"lv.q C010, %2\n" // load quaternion b
|
|
"vqmul.q C020, C000, C010\n" // C000 = quat a * quat b (quaternion multiply)
|
|
"sv.q C020, %0\n" // store result
|
|
: "+m"(*qout) : "m"(*a), "m"(*b));
|
|
}
|