Реорганизация проекта: перенос определения всех типов в один файл, перегруппировка функций в файлах
This commit is contained in:
parent
c7d9263154
commit
053af33444
45 changed files with 1001 additions and 980 deletions
|
|
@ -1,7 +1,8 @@
|
|||
#include <math.h>
|
||||
|
||||
#include "angle.h"
|
||||
#include "turn3.h"
|
||||
#include "./angle.h"
|
||||
#include "./vector3.h"
|
||||
#include "./turn3.h"
|
||||
|
||||
const BGC_FP32_Turn3 BGC_FP32_IDLE_TURN3 = {{ 1.0f, 0.0f, 0.0f, 0.0f }};
|
||||
|
||||
|
|
@ -308,7 +309,7 @@ static inline int _bgc_fp32_turn3_get_orthogonal_pair(BGC_FP32_Vector3* unit_mai
|
|||
return _BGC_ERROR_TURN3_EMPTY_BRANCH;
|
||||
}
|
||||
|
||||
bgc_fp32_vector3_multiply(unit_main, main, sqrtf(1.0f / main_square_modulus));
|
||||
bgc_fp32_vector3_multiply_by_real(unit_main, main, sqrtf(1.0f / main_square_modulus));
|
||||
|
||||
bgc_fp32_vector3_add_scaled(unit_branch, branch, unit_main, -bgc_fp32_vector3_get_dot_product(branch, unit_main));
|
||||
|
||||
|
|
@ -318,7 +319,7 @@ static inline int _bgc_fp32_turn3_get_orthogonal_pair(BGC_FP32_Vector3* unit_mai
|
|||
return _BGC_ERROR_TURN3_PAIR_PARALLEL;
|
||||
}
|
||||
|
||||
bgc_fp32_vector3_multiply(unit_branch, unit_branch, sqrtf(1.0f / orthogonal_square_modulus));
|
||||
bgc_fp32_vector3_multiply_by_real(unit_branch, unit_branch, sqrtf(1.0f / orthogonal_square_modulus));
|
||||
|
||||
return BGC_SUCCESS;
|
||||
}
|
||||
|
|
@ -337,7 +338,7 @@ static inline int _bgc_fp64_turn3_get_orthogonal_pair(BGC_FP64_Vector3* unit_mai
|
|||
return _BGC_ERROR_TURN3_EMPTY_BRANCH;
|
||||
}
|
||||
|
||||
bgc_fp64_vector3_multiply(unit_main, main, sqrt(1.0 / main_square_modulus));
|
||||
bgc_fp64_vector3_multiply_by_real(unit_main, main, sqrt(1.0 / main_square_modulus));
|
||||
|
||||
bgc_fp64_vector3_add_scaled(unit_branch, branch, unit_main, -bgc_fp64_vector3_get_dot_product(branch, unit_main));
|
||||
|
||||
|
|
@ -347,7 +348,7 @@ static inline int _bgc_fp64_turn3_get_orthogonal_pair(BGC_FP64_Vector3* unit_mai
|
|||
return _BGC_ERROR_TURN3_PAIR_PARALLEL;
|
||||
}
|
||||
|
||||
bgc_fp64_vector3_multiply(unit_branch, unit_branch, sqrt(1.0 / orthogonal_square_modulus));
|
||||
bgc_fp64_vector3_multiply_by_real(unit_branch, unit_branch, sqrt(1.0 / orthogonal_square_modulus));
|
||||
|
||||
return BGC_SUCCESS;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue