mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-26 22:31:05 +00:00
[util] Make a minor improvement to QuatMultVec
Switch from using addition to multiplication for doubling the value. Also, fix lib/util/test Makemodule to actually work (too much c&p coding).
This commit is contained in:
parent
4a8818f0b6
commit
e991c44232
2 changed files with 4 additions and 3 deletions
|
@ -268,7 +268,7 @@ QuatMultVec (const quat_t q, const vec3_t v, vec3_t out)
|
|||
dqq = DotProduct (q, q);
|
||||
VectorScale (tv, s, tv);
|
||||
VectorMultAdd (tv, dqv, q, tv);
|
||||
VectorAdd (tv, tv, tv);
|
||||
VectorScale (tv, 2, tv);
|
||||
VectorMultAdd (tv, s * s - dqq, v, out);
|
||||
}
|
||||
|
||||
|
|
|
@ -14,9 +14,10 @@ libs_util_tests = \
|
|||
libs/util/test/test-set \
|
||||
libs/util/test/test-txtbuffer \
|
||||
libs/util/test/test-vrect
|
||||
check_PROGRAMS += $(libs_util_tests)
|
||||
|
||||
TESTS += $(libs_model_tests)
|
||||
TESTS += $(libs_util_tests)
|
||||
|
||||
check_PROGRAMS += $(libs_util_tests)
|
||||
|
||||
libs_util_test_test_bary_SOURCES=libs/util/test/test-bary.c
|
||||
libs_util_test_test_bary_LDADD=libs/util/libQFutil.la
|
||||
|
|
Loading…
Reference in a new issue