Исправление названий в документации
This commit is contained in:
parent
c8f5a3f077
commit
847c022533
13 changed files with 104 additions and 104 deletions
|
@ -36,5 +36,5 @@ functions of **float** type and another one is for date of th **double** type.
|
||||||
And there are several bridges connect both of the halves. Those bridges are
|
And there are several bridges connect both of the halves. Those bridges are
|
||||||
the functions of the type conversion.
|
the functions of the type conversion.
|
||||||
|
|
||||||
But there are no functions which use data of different types (**float** and
|
But there are just few functions which use data of different types (**float**
|
||||||
**double** at the same time) for the computations.
|
and **double** at the same time) for the computations.
|
||||||
|
|
|
@ -11,14 +11,14 @@ There are three units of measurement for angles in the library:
|
||||||
The units of measurement of angles are defined with an enumerated type:
|
The units of measurement of angles are defined with an enumerated type:
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
BG_ANGLE_UNIT_RADIANS = 1,
|
BGC_ANGLE_UNIT_RADIANS = 1,
|
||||||
BG_ANGLE_UNIT_DEGREES = 2,
|
BGC_ANGLE_UNIT_DEGREES = 2,
|
||||||
BG_ANGLE_UNIT_TURNS = 3
|
BGC_ANGLE_UNIT_TURNS = 3
|
||||||
} angle_unit_t;
|
} BgcAngleUnitEnum;
|
||||||
|
|
||||||
* BG_ANGLE_UNIT_RADIANS is for measurement of angles in radians
|
* BGC_ANGLE_UNIT_RADIANS is for measurement of angles in radians
|
||||||
* BG_ANGLE_UNIT_DEGREES is for measurement of angles in degrees
|
* BGC_ANGLE_UNIT_DEGREES is for measurement of angles in degrees
|
||||||
* BG_ANGLE_UNIT_TURNS is for measurement of angles in turns
|
* BGC_ANGLE_UNIT_TURNS is for measurement of angles in turns
|
||||||
|
|
||||||
The functions of the library do not require angle values to be limited by any
|
The functions of the library do not require angle values to be limited by any
|
||||||
range. But there are functions which can normalize angles to specific ranges.
|
range. But there are functions which can normalize angles to specific ranges.
|
||||||
|
@ -40,9 +40,9 @@ corresponds:
|
||||||
The ranges of angles are defined with an enumerated type:
|
The ranges of angles are defined with an enumerated type:
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
BG_ANGLE_RANGE_UNSIGNED = 1,
|
BGC_ANGLE_RANGE_UNSIGNED = 1,
|
||||||
BG_ANGLE_RANGE_SIGNED = 2
|
BGC_ANGLE_RANGE_SIGNED = 2
|
||||||
} angle_range_t;
|
} BgcAngleRangeEnum;
|
||||||
|
|
||||||
* BG_ANGLE_RANGE_UNSIGNED is for the unsigned range of values;
|
* BGC_ANGLE_RANGE_UNSIGNED is for the unsigned range of values;
|
||||||
* BG_ANGLE_RANGE_SIGNED is for the signed range of values.
|
* BGC_ANGLE_RANGE_SIGNED is for the signed range of values.
|
||||||
|
|
|
@ -12,14 +12,14 @@
|
||||||
Единицы измерения углов определены в перечилении:
|
Единицы измерения углов определены в перечилении:
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
BG_ANGLE_UNIT_RADIANS = 1,
|
BGC_ANGLE_UNIT_RADIANS = 1,
|
||||||
BG_ANGLE_UNIT_DEGREES = 2,
|
BGC_ANGLE_UNIT_DEGREES = 2,
|
||||||
BG_ANGLE_UNIT_TURNS = 3
|
BGC_ANGLE_UNIT_TURNS = 3
|
||||||
} angle_unit_t;
|
} BgcAngleUnitEnum;
|
||||||
|
|
||||||
* BG_ANGLE_UNIT_RADIANS для уголов, измеряемых в радианах
|
* BGC_ANGLE_UNIT_RADIANS для уголов, измеряемых в радианах
|
||||||
* BG_ANGLE_UNIT_DEGREES для уголов, измеряемых в градусах
|
* BGC_ANGLE_UNIT_DEGREES для уголов, измеряемых в градусах
|
||||||
* BG_ANGLE_UNIT_TURNS для уголов, измеряемых в оборотах
|
* BGC_ANGLE_UNIT_TURNS для уголов, измеряемых в оборотах
|
||||||
|
|
||||||
Функции, которые принимают угол в качестве параметра, не требуют, чтобы
|
Функции, которые принимают угол в качестве параметра, не требуют, чтобы
|
||||||
угол принадлежал какому-либо промежутку значений. Но в библиотеке есть
|
угол принадлежал какому-либо промежутку значений. Но в библиотеке есть
|
||||||
|
@ -43,9 +43,9 @@
|
||||||
Диапазоны значений определены перечиляемым типом:
|
Диапазоны значений определены перечиляемым типом:
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
BG_ANGLE_RANGE_UNSIGNED = 1,
|
BGC_ANGLE_RANGE_UNSIGNED = 1,
|
||||||
BG_ANGLE_RANGE_SIGNED = 2
|
BGC_ANGLE_RANGE_SIGNED = 2
|
||||||
} angle_range_t;
|
} BgcAngleRangeEnum;
|
||||||
|
|
||||||
* BG_ANGLE_RANGE_UNSIGNED для беззнакового диапазона значений;
|
* BGC_ANGLE_RANGE_UNSIGNED для беззнакового диапазона значений;
|
||||||
* BG_ANGLE_RANGE_SIGNED для знакового диапазона значений.
|
* BGC_ANGLE_RANGE_SIGNED для знакового диапазона значений.
|
||||||
|
|
|
@ -1,23 +1,23 @@
|
||||||
# Prefixes
|
# Prefixes and Suffixes
|
||||||
|
|
||||||
The library uses prefixes in names of types, constants and functions.
|
The library uses prefixes in names of types, constants and functions.
|
||||||
|
|
||||||
The main prefix is **BG** which means **B**asic **G**eometry.
|
The main prefix is **BGC** which means **B**asic **G**eometric **C**omputations.
|
||||||
|
|
||||||
The structure types have prefix in the form **Bg**. For example: BgFP64Vector3,
|
The structure types have prefix in the form **Bgc**. For example: BgcVector3FP64,
|
||||||
BgFP32Versor, BgFP32Matrix2x2.
|
BgcVersorFP32, BgcMatrix2x2FP32.
|
||||||
|
|
||||||
The constants have prefix in the form **BG_**. For example: BG_FP32_EPSYLON,
|
The constants have prefix in the form **BGC_**. For example: BGC_EPSYLON_FP32,
|
||||||
BG_FP64_TWO_PI.
|
BGC_TWO_PI_FP64.
|
||||||
|
|
||||||
The functions have prefix in the form **bg_**. For example:
|
The functions have prefix in the form **bgc_**. For example:
|
||||||
bg_fp32_versor_combine, bg_fp64_matrix3x3_subtract.
|
bgc_versor_combine_fp32, bgc_matrix3x3_subtract_fp32.
|
||||||
|
|
||||||
A prefix of type follows right after the prefix of the library. The library uses
|
Suffixs of type ends the names of constats, types and functions of the library.
|
||||||
two types of floating point numbers: **float** and **double** (**binary32**
|
The library uses two types of floating point numbers: **float** and **double**
|
||||||
and **binary64** types of the **IEEE 754** standard).
|
(**binary32** and **binary64** types of the **IEEE 754** standard).
|
||||||
|
|
||||||
Thus there are two prefixes of types:
|
Thus there are two suffixes of types:
|
||||||
|
|
||||||
* **FP32** - means **F**loating **P**oint, **32** bit, which corresponds to the
|
* **FP32** - means **F**loating **P**oint, **32** bit, which corresponds to the
|
||||||
**float** type of the C language.
|
**float** type of the C language.
|
||||||
|
@ -26,19 +26,19 @@ Thus there are two prefixes of types:
|
||||||
**double** type of the C language.
|
**double** type of the C language.
|
||||||
|
|
||||||
The types of structures which are based in the **float** type have **FP32** as
|
The types of structures which are based in the **float** type have **FP32** as
|
||||||
the type prefix: BgFP32Vector3, BgFP32Matrix3x2, BgFP32Quaternion
|
the type prefix: BgcVector3FP32, BgcMatrix3x2FP32, BgcQuaternionFP32.
|
||||||
|
|
||||||
The types of structures which are based in the **double** type have **FP64** as
|
The types of structures which are based in the **double** type have **FP64** as
|
||||||
the type prefix: BgFP64Vector2, BgFP64Matrix2x3, BgFP64Versor
|
the type prefix: BgcVector2FP64, BgcMatrix2x3FP64, BgcVersorFP64.
|
||||||
|
|
||||||
The constants of the **float** type have **FP32_** as the type prefix:
|
The constants of the **float** type have **_FP32** as the type suffix:
|
||||||
BG_FP32_PI, BG_FP32_EPSYLON.
|
BGC_PI_FP32, BGC_EPSYLON_FP32.
|
||||||
|
|
||||||
The constants of the **double** type have **FP64_** as the type prefix:
|
The constants of the **double** type have **_FP64** as the type suffix:
|
||||||
BG_FP64_HALF_PI, BG_FP64_ONE_THIRD.
|
BGC_HALF_PI_FP64, BGC_ONE_THIRD_FP64.
|
||||||
|
|
||||||
The functions which works with data of the **float** type have **fp32_** as
|
The functions which works with data of the **float** type have **_fp32** as
|
||||||
the type prefix: bg_fp32_vector2_get_module, bg_fp32_radians_to_degrees.
|
the type suffix: bgc_vector2_get_modulus_fp64, bgc_radians_to_degrees_fp32.
|
||||||
|
|
||||||
The functions which works with data of the **double** type have **fp64_** as
|
The functions which works with data of the **double** type have **_fp64** as
|
||||||
the type prefix: bg_fp64_vector3_reset, bg_fp64_radians_normalize.
|
the type suffix: bgc_vector3_reset_fp64, bgc_radians_normalize_fp64.
|
||||||
|
|
|
@ -2,21 +2,22 @@
|
||||||
|
|
||||||
Библиотека использует префиксы в названиях типов, констант и функций.
|
Библиотека использует префиксы в названиях типов, констант и функций.
|
||||||
|
|
||||||
Основным префиксом является **BG** (сокращение от **B**asic **G**eometry / Базовая
|
Основным префиксом является **BGC** (сокращение от **B**asic **G**eometric
|
||||||
Геометрия).
|
**C**omputations / Базовые Геометрие Вычисления).
|
||||||
|
|
||||||
Для структур данных префикс имеет вид **Bg**, например: BgFP64Vector3,
|
Для структур данных префикс имеет вид **Bgc**, например: BgcVector3FP64,
|
||||||
BgFP32Versor, BgFP32Matrix2x2.
|
BgcVersorFP32, BgcMatrix2x2FP32.
|
||||||
|
|
||||||
Константы имеют префикс в виде **BG_**, например: BG_FP32_EPSYLON,
|
Константы имеют префикс в виде **BGC_**, например: BGC_EPSYLON_FP32,
|
||||||
BG_FP64_TWO_PI.
|
BGC_TWO_PI_FP64.
|
||||||
|
|
||||||
Функции имеют префикс в виде **bg_**, например: bg_fp32_versor_combine,
|
Функции имеют префикс в виде **bgc_**, например: bgc_versor_combine_fp32,
|
||||||
bg_fp64_matrix3x3_subtract.
|
bgc_matrix3x3_subtract_fp64.
|
||||||
|
|
||||||
Сразу после префикса библиотеки идёт префикс типа. Библиотека использует
|
Названия констант, типов и функций оканчиваются суффиксом, указывающим на
|
||||||
два типа чисел с плавающей запятой: **float** и **double** (типы **binary32**
|
базовый тип. Библиотека использует два типа чисел с плавающей запятой:
|
||||||
и **binary64** стандарта **IEEE 754**).
|
**float** и **double** (типы **binary32** и **binary64** стандарта
|
||||||
|
**IEEE 754**).
|
||||||
|
|
||||||
Поэтому в библиотеке есть два префикса типа:
|
Поэтому в библиотеке есть два префикса типа:
|
||||||
|
|
||||||
|
@ -26,20 +27,19 @@ bg_fp64_matrix3x3_subtract.
|
||||||
* **FP64** - означает **F**loating **P**oint **64** bit, то есть, число с
|
* **FP64** - означает **F**loating **P**oint **64** bit, то есть, число с
|
||||||
плавающей запятой, 64 бита, что соответствует типу **double** языка Си.
|
плавающей запятой, 64 бита, что соответствует типу **double** языка Си.
|
||||||
|
|
||||||
Типы структур, использующие тип **float** имеют префикс типа в виде **FP32**:
|
Типы структур, использующие тип **float** имеют суффикс **FP32**:
|
||||||
BgFP32Vector3, BgFP32Matrix3x2, BgFP32Quaternion
|
BgcVector3FP32, BgcMatrix3x2FP32, BgcQuaternionFP32
|
||||||
|
|
||||||
Типы структур, использующие тип **double** имеют префикс типа в виде **FP64**:
|
Типы структур, использующие тип **double** имеют суффикс **FP64**:
|
||||||
BgFP64Vector2, BgFP64Matrix2x3, BgFP64Versor
|
BgcVector2FP64, BgcMatrix2x3FP64, BgcVersorFP64
|
||||||
|
|
||||||
Константы типа **float** имеют префикс типа в виде **FP32_**: BG_FP32_PI,
|
Константы типа **float** имеют суффикс **FP32_**: BGC_PI_FP32, BGC_EPSYLON_FP32.
|
||||||
BG_FP32_EPSYLON.
|
|
||||||
|
|
||||||
Константы типа **double** имеют префикс типа в виде **FP64_**: BG_FP64_HALF_PI,
|
Константы типа **double** имеют суффикс **FP64_**: BGC_HALF_PI_FP64,
|
||||||
BG_FP64_ONE_THIRD.
|
BGC_ONE_THIRD_FP64.
|
||||||
|
|
||||||
Функции, которые работают с данными типа **float** имеют префикс **fp32_**:
|
Функции, которые работают с данными типа **float** имеют суффикс **_fp32**:
|
||||||
bg_fp32_vector2_get_module, bg_fp32_radians_to_degrees.
|
bcg_vector2_get_modulus_fp32, bgc_radians_to_degrees_fp32.
|
||||||
|
|
||||||
Функции, которые работают с данными типа **double** имеют префикс **fp64_**:
|
Функции, которые работают с данными типа **double** имеют суффикс **_fp64**:
|
||||||
bg_fp64_vector3_reset, bg_fp64_radians_normalize.
|
bgc_vector3_reset_fp64, bgc_radians_normalize_fp64.
|
||||||
|
|
|
@ -67,22 +67,22 @@ There two structural types for quaternions:
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
float s0, x1, x2, x3;
|
float s0, x1, x2, x3;
|
||||||
} BgFP32Quaternion;
|
} BgcQuaternionFP32;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
double s0, x1, x2, x3;
|
double s0, x1, x2, x3;
|
||||||
} BgFP64Quaternion;
|
} BgcQuaternionFP64;
|
||||||
|
|
||||||
|
|
||||||
And there are two strucutral types for versors:
|
And there are two strucutral types for versors:
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
const float s0, x1, x2, x3;
|
const float s0, x1, x2, x3;
|
||||||
} BgFP32Versor;
|
} BgcVersorFP32;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
const double s0, x1, x2, x3;
|
const double s0, x1, x2, x3;
|
||||||
} BgFP64Versor;
|
} BgcVersorFP64;
|
||||||
|
|
||||||
As you can see there is a difference in the definision of quaternions and
|
As you can see there is a difference in the definision of quaternions and
|
||||||
versors: the fields of versors are const while the fields of quaternions
|
versors: the fields of versors are const while the fields of quaternions
|
||||||
|
|
|
@ -67,22 +67,22 @@
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
float s0, x1, x2, x3;
|
float s0, x1, x2, x3;
|
||||||
} BgFP32Quaternion;
|
} BgcQuaternionFP32;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
double s0, x1, x2, x3;
|
double s0, x1, x2, x3;
|
||||||
} BgFP64Quaternion;
|
} BgcQuaternionFP64;
|
||||||
|
|
||||||
|
|
||||||
Для описания версоров также имеется две структуры:
|
Для описания версоров также имеется две структуры:
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
const float s0, x1, x2, x3;
|
const float s0, x1, x2, x3;
|
||||||
} BgFP32Versor;
|
} BgcVersorFP32;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
const double s0, x1, x2, x3;
|
const double s0, x1, x2, x3;
|
||||||
} BgFP64Versor;
|
} BgcVersorFP64;
|
||||||
|
|
||||||
Уже в определении структур можно заметить разницу между в реализации
|
Уже в определении структур можно заметить разницу между в реализации
|
||||||
кватернионов и версоров: поля версоров объявлены как константы, в то время как
|
кватернионов и версоров: поля версоров объявлены как константы, в то время как
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
# Two dimensional vectors
|
# Two dimensional vectors
|
||||||
|
|
||||||
There are two types for two dimensional vectors:
|
There are two types for two dimensional vectors:
|
||||||
- BgFP32Vector2 for single precision vectors
|
- BgcVector2FP32 for single precision vectors
|
||||||
- BgFP64Vector2 for double precision vectors
|
- BgcVector2FP64 for double precision vectors
|
||||||
|
|
||||||
Vectors of BgFP32Vecto2 type use **float** (binary32 of IEEE 754) type to store
|
Vectors of BgFP32Vecto2 type use **float** (binary32 of IEEE 754) type to store
|
||||||
coordinate values.
|
coordinate values.
|
||||||
|
@ -17,10 +17,10 @@ The definition of the types:
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
float x1, x2;
|
float x1, x2;
|
||||||
} BgFP32Vector2;
|
} BgcVector2FP32;
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
double x1, x2;
|
double x1, x2;
|
||||||
} BgFP64Vector2;
|
} BgcVector2FP64;
|
||||||
|
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
# Двумерные векторы
|
# Двумерные векторы
|
||||||
|
|
||||||
В библиотеке есть две версии вектора:
|
В библиотеке есть две версии вектора:
|
||||||
- BgFP32Vector2 - вектор одинарной точности
|
- BgcVector2FP32 - вектор одинарной точности
|
||||||
- BgFP64Vector2 - вектор двойной точности
|
- BgcVector2FP64 - вектор двойной точности
|
||||||
|
|
||||||
Векторы типа BgFP32Vector2 для хранения координат использует тип **float** (тип
|
Векторы типа BgcVector2FP32 для хранения координат использует тип **float** (тип
|
||||||
binary32 стандарта IEEE 754).
|
binary32 стандарта IEEE 754).
|
||||||
|
|
||||||
Векторы BgFP64Vector2 используют тип **double** (тип binary64 стандарта IEEE 754).
|
Векторы BgcVector2FP64 используют тип **double** (тип binary64 стандарта IEEE 754).
|
||||||
|
|
||||||
Оба типа представляют собой структуры с двумя полями: **x1** и **x2**.
|
Оба типа представляют собой структуры с двумя полями: **x1** и **x2**.
|
||||||
|
|
||||||
|
@ -16,10 +16,10 @@ binary32 стандарта IEEE 754).
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
float x1, x2;
|
float x1, x2;
|
||||||
} BgFP32Vector2;
|
} BgcVector2FP32;
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
double x1, x2;
|
double x1, x2;
|
||||||
} BgFP64Vector2;
|
} BgcVector2FP64;
|
||||||
|
|
||||||
|
|
|
@ -37,19 +37,19 @@ Versors are quaternions of unit length.
|
||||||
The library has a separate implementation for versors in the form of special
|
The library has a separate implementation for versors in the form of special
|
||||||
structures and a set of functions that keep the modulus of a versorclose to one.
|
structures and a set of functions that keep the modulus of a versorclose to one.
|
||||||
|
|
||||||
There are two structures for versors: **BgFP32Versor** and **BgFP64Versor**:
|
There are two structures for versors: **BgcVersorFP32** and **BgcVersorFP64**:
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
const float s0, x1, x2, x3;
|
const float s0, x1, x2, x3;
|
||||||
} BgFP32Versor;
|
} BgcVersorFP32;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
const double s0, x1, x2, x3;
|
const double s0, x1, x2, x3;
|
||||||
} BgFP64Versor;
|
} BgcVersorFP64;
|
||||||
|
|
||||||
The fields are deliberately declared const so that a developer using these
|
The fields are deliberately declared const so that a developer using these
|
||||||
structures is not tempted to change the values of the fields directly.
|
structures is not tempted to change the values of the fields directly.
|
||||||
|
|
||||||
With these structures, it is better to use special functions that allow you
|
With these structures, it is better to use special functions that allow you
|
||||||
to save new values in the structure fields of **BgFP32Versor** and
|
to save new values in the structure fields of **BgcVersorFP32** and
|
||||||
**BgFP64Versor**.
|
**BgcVersorFP64**.
|
||||||
|
|
|
@ -32,11 +32,11 @@
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
const float s0, x1, x2, x3;
|
const float s0, x1, x2, x3;
|
||||||
} BgFP32Versor;
|
} BgcVersorFP32;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
const double s0, x1, x2, x3;
|
const double s0, x1, x2, x3;
|
||||||
} BgFP64Versor;
|
} BgcVersorFP64;
|
||||||
|
|
||||||
Поля структур намеренно объявлены констрантными (const), чтобы побудить
|
Поля структур намеренно объявлены констрантными (const), чтобы побудить
|
||||||
разработчика использовать функции работы с версорами, вместо того, чтобы
|
разработчика использовать функции работы с версорами, вместо того, чтобы
|
||||||
|
@ -44,6 +44,6 @@
|
||||||
модуль версора равным единицы.
|
модуль версора равным единицы.
|
||||||
|
|
||||||
С данными структурами лучше использовать специальные функции, которые позволяют
|
С данными структурами лучше использовать специальные функции, которые позволяют
|
||||||
устанавливать новые значения в поля структур **BgFP32Versor** и
|
устанавливать новые значения в поля структур **BgcVersorFP32** и
|
||||||
**BgFP64Versor**.
|
**BgcVersorFP64**.
|
||||||
|
|
||||||
|
|
|
@ -6,11 +6,11 @@ The functions reset the state of versors to the state of no turn:
|
||||||
|
|
||||||
For the **BgFP32Versor** type the function is:
|
For the **BgFP32Versor** type the function is:
|
||||||
|
|
||||||
void bg_fp32_versor_reset(BgFP32Versor* versor);
|
void bgc_versor_reset_fp32(BgFP32Versor* versor);
|
||||||
|
|
||||||
For the **BgFP64Versor** type the function is:
|
For the **BgFP64Versor** type the function is:
|
||||||
|
|
||||||
void bg_fp64_versor_reset(BgFP64Versor* versor);
|
void bgc_versor_reset_fp64(BgFP64Versor* versor);
|
||||||
|
|
||||||
These functions are good for setting the initial state of variables and fields
|
These functions are good for setting the initial state of variables and fields
|
||||||
of **BgFP32Versor** and **BgFP64Versor** types.
|
of **BgFP32Versor** and **BgFP64Versor** types.
|
||||||
|
@ -23,7 +23,7 @@ Example of usage:
|
||||||
int main() {
|
int main() {
|
||||||
BgFP32Versor versor;
|
BgFP32Versor versor;
|
||||||
|
|
||||||
bg_fp32_versor_reset(&versor);
|
bgc_versor_reset_fp32(&versor);
|
||||||
|
|
||||||
printf("Versor: (%f, %f, %f, %f)\n", versor.s0, versor.x1, versor.x2, versor.x3);
|
printf("Versor: (%f, %f, %f, %f)\n", versor.s0, versor.x1, versor.x2, versor.x3);
|
||||||
|
|
||||||
|
|
|
@ -7,11 +7,11 @@
|
||||||
|
|
||||||
Для типа **BgFP32Versor** функция имеет вид:
|
Для типа **BgFP32Versor** функция имеет вид:
|
||||||
|
|
||||||
void bg_fp32_versor_reset(BgFP32Versor* versor);
|
void bgc_versor_reset_fp32(BgFP32Versor* versor);
|
||||||
|
|
||||||
Для типа **BgFP64Versor** функция имеет вид:
|
Для типа **BgFP64Versor** функция имеет вид:
|
||||||
|
|
||||||
void bg_fp64_versor_reset(BgFP64Versor* versor);
|
void bgc_versor_reset_fp64(BgFP64Versor* versor);
|
||||||
|
|
||||||
Данные функции хорошо подходят для инициализации состояния переменной типов
|
Данные функции хорошо подходят для инициализации состояния переменной типов
|
||||||
**BgFP32Versor** и **BgFP64Versor**.
|
**BgFP32Versor** и **BgFP64Versor**.
|
||||||
|
@ -24,7 +24,7 @@
|
||||||
int main() {
|
int main() {
|
||||||
BgFP32Versor versor;
|
BgFP32Versor versor;
|
||||||
|
|
||||||
bg_fp32_versor_reset(&versor);
|
bgc_versor_reset_fp32(&versor);
|
||||||
|
|
||||||
printf("Versor: (%f, %f, %f, %f)\n", versor.s0, versor.x1, versor.x2, versor.x3);
|
printf("Versor: (%f, %f, %f, %f)\n", versor.s0, versor.x1, versor.x2, versor.x3);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue