Добавление базисов как вспомогательной структуры
This commit is contained in:
parent
9d7011e81e
commit
e6a94ab8d9
9 changed files with 345 additions and 14 deletions
|
|
@ -176,7 +176,49 @@ inline void bgc_vector3_reverse_fp64(const BgcVector3FP64* vector, BgcVector3FP6
|
|||
|
||||
// ================= Normalize ================== //
|
||||
|
||||
inline int bgc_vector3_normalize_fp32(const BgcVector3FP32* vector, BgcVector3FP32* normalized)
|
||||
inline int bgc_vector3_normalize_fp32(BgcVector3FP32* vector)
|
||||
{
|
||||
const float square_modulus = bgc_vector3_get_square_modulus_fp32(vector);
|
||||
|
||||
if (bgc_is_sqare_unit_fp32(square_modulus)) {
|
||||
return 1;
|
||||
}
|
||||
|
||||