#include "libnltrack.h"
#include <math.h>
Functions | |
int | addBezier (float posX, float posY, float posZ, float cp1X, float cp1Y, float cp1Z, float cp2X, float cp2Y, float cp2Z, float roll, int continuesRoll, int equalDistanceCP, int relativeRoll, NlTrack *Track) |
Add a bezier. | |
void | modifyBezier (int bezierindex, float posX, float posY, float posZ, float cp1X, float cp1Y, float cp1Z, float cp2X, float cp2Y, float cp2Z, float roll, int continuesRoll, int equalDistanceCP, int relativeRoll, NlTrack *Track) |
Modify a bezier. | |
void | deleteBezier (int bezierindex, NlTrack *Track) |
Delete a bezier. | |
Bezier | getBezier (int bezierindex, NlTrack *Track) |
Get a bezier. | |
int | getNumBeziers (NlTrack *Track) |
Get the number of the beziers. |
int addBezier | ( | float | posX, | |
float | posY, | |||
float | posZ, | |||
float | cp1X, | |||
float | cp1Y, | |||
float | cp1Z, | |||
float | cp2X, | |||
float | cp2Y, | |||
float | cp2Z, | |||
float | roll, | |||
int | continuesRoll, | |||
int | equalDistanceCP, | |||
int | relativeRoll, | |||
NlTrack * | Track | |||
) |
Add a bezier.
posX | is the x-axis position of the bezier | |
posY | is the y-axis position of the bezier | |
posZ | is the z-axis position of the bezier | |
cp1X | is the x-axis position of the first controll point | |
cp1Y | is the y-axis position of the first controll point | |
cp1Z | is the z-axis position of the first controll point | |
cp2X | is the x-axis position of the second controll point | |
cp2Y | is the y-axis position of the second controll point | |
cp2Z | is the z-axis position of the second controll point | |
roll | is the banking in radian. To convert from degree to radian, please use toRad(). | |
continuesRoll | is the controll roll attribute of the bezier. 1 for true and 0 for false. | |
equalDistanceCP | Will determine that the controll points are equal. 1 for true and 0 for false. | |
relativeRoll | is the relative roll attribute of the bezier. 1 for true and 0 for false. | |
Track | a pointer to the NlTrack |
References NlTrack::beziers, NlTrack::bezrsize, Bezier::continuesRoll, Bezier::cp1X, Bezier::cp1Y, Bezier::cp1Z, Bezier::cp2X, Bezier::cp2Y, Bezier::cp2Z, Bezier::equalDistanceCP, NlTrack::numBeziers, Bezier::posX, Bezier::posY, Bezier::posZ, Bezier::relativeRoll, and Bezier::roll.
void deleteBezier | ( | int | bezierindex, | |
NlTrack * | Track | |||
) |
Delete a bezier.
bezierindex | is the index value of the deleted bezier | |
Track | a pointer to the NlTrack |
References NlTrack::beziers, NlTrack::bezrsize, and NlTrack::numBeziers.
Get a bezier.
bezierindex | is the index value of the deleted bezier | |
Track | a pointer to the NlTrack |
References NlTrack::beziers.
int getNumBeziers | ( | NlTrack * | Track | ) |
Get the number of the beziers.
Track | a pointer to the NlTrack |
References NlTrack::numBeziers.
void modifyBezier | ( | int | bezierindex, | |
float | posX, | |||
float | posY, | |||
float | posZ, | |||
float | cp1X, | |||
float | cp1Y, | |||
float | cp1Z, | |||
float | cp2X, | |||
float | cp2Y, | |||
float | cp2Z, | |||
float | roll, | |||
int | continuesRoll, | |||
int | equalDistanceCP, | |||
int | relativeRoll, | |||
NlTrack * | Track | |||
) |
Modify a bezier.
bezierindex | is the index value of the modified bezier | |
posX | is the x-axis position of the bezier | |
posY | is the y-axis position of the bezier | |
posZ | is the z-axis position of the bezier | |
cp1X | is the x-axis position of the first controll point | |
cp1Y | is the y-axis position of the first controll point | |
cp1Z | is the z-axis position of the first controll point | |
cp2X | is the x-axis position of the second controll point | |
cp2Y | is the y-axis position of the second controll point | |
cp2Z | is the z-axis position of the second controll point | |
roll | is the banking in radian. To convert from degree to radian, please use toRad(). | |
continuesRoll | is the controll roll attribute of the bezier. 1 for true and 0 for false. | |
equalDistanceCP | Will determine that the controll points are equal. 1 for true and 0 for false. | |
relativeRoll | is the relative roll attribute of the bezier. 1 for true and 0 for false. | |
Track | a pointer to the NlTrack |
References NlTrack::beziers, Bezier::continuesRoll, Bezier::cp1X, Bezier::cp1Y, Bezier::cp1Z, Bezier::cp2X, Bezier::cp2Y, Bezier::cp2Z, Bezier::equalDistanceCP, Bezier::posX, Bezier::posY, Bezier::posZ, Bezier::relativeRoll, and Bezier::roll.