Небольшие исправления
This commit is contained in:
parent
89dfd7644b
commit
857d79e572
4 changed files with 8 additions and 8 deletions
|
|
@ -492,7 +492,7 @@ int main()
|
||||||
|
|
||||||
uni_number number;
|
uni_number number;
|
||||||
|
|
||||||
number.fp32 = 2.0f;
|
number.fp32 = 1.0f;
|
||||||
|
|
||||||
printf("%x\n", number.si32);
|
printf("%x\n", number.si32);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -67,10 +67,10 @@ extern inline void bgc_complex_subtract_fp32(const BgcComplexFP32* minuend, cons
|
||||||
extern inline void bgc_complex_subtract_fp64(const BgcComplexFP64* minuend, const BgcComplexFP64* subtrahend, BgcComplexFP64* difference);
|
extern inline void bgc_complex_subtract_fp64(const BgcComplexFP64* minuend, const BgcComplexFP64* subtrahend, BgcComplexFP64* difference);
|
||||||
|
|
||||||
extern inline void bgc_complex_multiply_by_number_fp32(const BgcComplexFP32* multiplicand, const float multiplier, BgcComplexFP32* product);
|
extern inline void bgc_complex_multiply_by_number_fp32(const BgcComplexFP32* multiplicand, const float multiplier, BgcComplexFP32* product);
|
||||||
extern inline void bgc_complex_multiply_fp64(const BgcComplexFP64* multiplicand, const double multiplier, BgcComplexFP64* product);
|
extern inline void bgc_complex_multiply_by_number_fp64(const BgcComplexFP64* multiplicand, const double multiplier, BgcComplexFP64* product);
|
||||||
|
|
||||||
extern inline void bgc_complex_divide_by_number_fp32(const BgcComplexFP32* dividend, const float divisor, BgcComplexFP32* quotient);
|
extern inline void bgc_complex_divide_by_number_fp32(const BgcComplexFP32* dividend, const float divisor, BgcComplexFP32* quotient);
|
||||||
extern inline void bgc_complex_divide_fp64(const BgcComplexFP64* dividend, const double divisor, BgcComplexFP64* quotient);
|
extern inline void bgc_complex_divide_by_number_fp64(const BgcComplexFP64* dividend, const double divisor, BgcComplexFP64* quotient);
|
||||||
|
|
||||||
extern inline void bgc_complex_get_mean_of_two_fp32(const BgcComplexFP32* number1, const BgcComplexFP32* number2, BgcComplexFP32* mean);
|
extern inline void bgc_complex_get_mean_of_two_fp32(const BgcComplexFP32* number1, const BgcComplexFP32* number2, BgcComplexFP32* mean);
|
||||||
extern inline void bgc_complex_get_mean_of_two_fp64(const BgcComplexFP64* number1, const BgcComplexFP64* number2, BgcComplexFP64* mean);
|
extern inline void bgc_complex_get_mean_of_two_fp64(const BgcComplexFP64* number1, const BgcComplexFP64* number2, BgcComplexFP64* mean);
|
||||||
|
|
|
||||||
|
|
@ -274,7 +274,7 @@ inline int bgc_matrix3x3_is_singular_fp64(const BgcMatrix3x3FP64* matrix)
|
||||||
|
|
||||||
// ================ Is Rotation ================= //
|
// ================ Is Rotation ================= //
|
||||||
|
|
||||||
inline int bgc_matrix3x3_is_rotation_fp32a(const BgcMatrix3x3FP32* matrix)
|
inline int bgc_matrix3x3_is_rotation_fp32(const BgcMatrix3x3FP32* matrix)
|
||||||
{
|
{
|
||||||
if (!bgc_is_unit_fp32(bgc_matrix3x3_get_determinant_fp32(matrix))) {
|
if (!bgc_is_unit_fp32(bgc_matrix3x3_get_determinant_fp32(matrix))) {
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
||||||
|
|
@ -165,7 +165,7 @@ void bgc_versor_set_turn_fp64(const double x1, const double x2, const double x3,
|
||||||
|
|
||||||
// ========= Make Direction Difference ========== //
|
// ========= Make Direction Difference ========== //
|
||||||
|
|
||||||
inline int _bgc_versor_make_direction_turn_fp32(const BgcVector3FP32* start, const BgcVector3FP32* end, const float square_modulus_product, BgcVersorFP32* result)
|
static int _bgc_versor_make_direction_turn_fp32(const BgcVector3FP32* start, const BgcVector3FP32* end, const float square_modulus_product, BgcVersorFP32* result)
|
||||||
{
|
{
|
||||||
BgcVector3FP32 orthogonal_axis;
|
BgcVector3FP32 orthogonal_axis;
|
||||||
|
|
||||||
|
|
@ -193,7 +193,7 @@ inline int _bgc_versor_make_direction_turn_fp32(const BgcVector3FP32* start, con
|
||||||
return BGC_ZERO_TURN;
|
return BGC_ZERO_TURN;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline int _bgc_versor_make_direction_turn_fp64(const BgcVector3FP64* start, const BgcVector3FP64* end, const double square_modulus_product, BgcVersorFP64* result)
|
static int _bgc_versor_make_direction_turn_fp64(const BgcVector3FP64* start, const BgcVector3FP64* end, const double square_modulus_product, BgcVersorFP64* result)
|
||||||
{
|
{
|
||||||
BgcVector3FP64 orthogonal_axis;
|
BgcVector3FP64 orthogonal_axis;
|
||||||
|
|
||||||
|
|
@ -249,7 +249,7 @@ int bgc_versor_make_direction_difference_fp64(const BgcVector3FP64* start, const
|
||||||
|
|
||||||
// =============== Set Directions =============== //
|
// =============== Set Directions =============== //
|
||||||
|
|
||||||
inline int _bgc_versor_validate_basis_fp32(const float primary_square_modulus, const float auxiliary_square_modulus, const float orthogonal_square_modulus)
|
static int _bgc_versor_validate_basis_fp32(const float primary_square_modulus, const float auxiliary_square_modulus, const float orthogonal_square_modulus)
|
||||||
{
|
{
|
||||||
if (primary_square_modulus <= BGC_SQUARE_EPSYLON_FP32) {
|
if (primary_square_modulus <= BGC_SQUARE_EPSYLON_FP32) {
|
||||||
//TODO: add error code for: primary_vector is zero
|
//TODO: add error code for: primary_vector is zero
|
||||||
|
|
@ -269,7 +269,7 @@ inline int _bgc_versor_validate_basis_fp32(const float primary_square_modulus, c
|
||||||
return BGC_SUCCESS;
|
return BGC_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline int _bgc_versor_validate_basis_fp64(const double primary_square_modulus, const double auxiliary_square_modulus, const double orthogonal_square_modulus)
|
static int _bgc_versor_validate_basis_fp64(const double primary_square_modulus, const double auxiliary_square_modulus, const double orthogonal_square_modulus)
|
||||||
{
|
{
|
||||||
if (primary_square_modulus <= BGC_SQUARE_EPSYLON_FP64) {
|
if (primary_square_modulus <= BGC_SQUARE_EPSYLON_FP64) {
|
||||||
//TODO: add error code for: primary_vector is zero
|
//TODO: add error code for: primary_vector is zero
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue