TiGL
2.2.3
|
Functions | |
TIGL_COMMON_EXPORT TiglReturnCode | tiglCheckPointInside (TiglCPACSConfigurationHandle cpacsHandle, double px, double py, double pz, const char *componentUID, TiglBoolean *isInside) |
Checks whether a point lies inside the given geometric object. More... | |
TIGL_COMMON_EXPORT TiglReturnCode | tiglComponentGetHashCode (TiglCPACSConfigurationHandle cpacsHandle, const char *componentUID, int *hashCodePtr) |
Returns a unique HashCode for a geometric component. More... | |
TIGL_COMMON_EXPORT TiglReturnCode | tiglConfigurationGetLength (TiglCPACSConfigurationHandle cpacsHandle, double *pLength) |
Returns the length of the plane. More... | |
TIGL_COMMON_EXPORT const char * | tiglGetErrorString (TiglReturnCode errorCode) |
Translates an error code into a string. More... | |
TIGL_COMMON_EXPORT TiglReturnCode | tiglWingGetMAC (TiglCPACSConfigurationHandle cpacsHandle, const char *wingUID, double *mac_chord, double *mac_x, double *mac_y, double *mac_z) |
This function calculates location of the quarter of mean aerodynamic chord, and gives the chord lenght as well. More... | |
TIGL_COMMON_EXPORT TiglReturnCode | tiglWingGetSpan (TiglCPACSConfigurationHandle cpacsHandle, const char *wingUID, double *pSpan) |
Returns the span of a wing. More... | |
Generic utility functions for geometric components that fits not only to wings or fuselages.
TIGL_COMMON_EXPORT TiglReturnCode tiglCheckPointInside | ( | TiglCPACSConfigurationHandle | cpacsHandle, |
double | px, | ||
double | py, | ||
double | pz, | ||
const char * | componentUID, | ||
TiglBoolean * | isInside | ||
) |
Checks whether a point lies inside the given geometric object.
This function works only for solid objects!
[in] | cpacsHandle | Handle for the CPACS configuration |
[in] | px | X coordinate of point |
[in] | py | Y coordinate of point |
[in] | pz | Z coordinate of point |
[in] | componentUID | UID of the component (e.g. a fuselage UID, wing UID, wing segment UID ...) |
[out] | isInside | Returns, whether the point lies inside the object or not. |
TIGL_COMMON_EXPORT TiglReturnCode tiglComponentGetHashCode | ( | TiglCPACSConfigurationHandle | cpacsHandle, |
const char * | componentUID, | ||
int * | hashCodePtr | ||
) |
Returns a unique HashCode for a geometric component.
The component, for example a wing or a fuselage, could be specified via its UID. The HashCode is the same as long as the geometry of this component has not changed. The HashCode is valid through the current session only! The hash value is computed from the value of the underlying shape reference.
[in] | cpacsHandle | Handle for the CPACS configuration |
[in] | componentUID | The uid of the component for which the hash should be computed |
[out] | hashCodePtr | The pointer to a hash value to represent this shape |
TIGL_COMMON_EXPORT TiglReturnCode tiglConfigurationGetLength | ( | TiglCPACSConfigurationHandle | cpacsHandle, |
double * | pLength | ||
) |
Returns the length of the plane.
The calculation of the airplane lenght is realized as follows:
All part of the configuration (currently all wing and fuselage segments) are put into a bounding box. The length of the plane is returned as the length of the box in x-direction.
[in] | cpacsHandle | Handle for the CPACS configuration |
[out] | pLength | Length of plane |
TIGL_COMMON_EXPORT const char* tiglGetErrorString | ( | TiglReturnCode | errorCode | ) |
Translates an error code into a string.
[in] | errorCode | Return value of a tigl function |
TIGL_COMMON_EXPORT TiglReturnCode tiglWingGetMAC | ( | TiglCPACSConfigurationHandle | cpacsHandle, |
const char * | wingUID, | ||
double * | mac_chord, | ||
double * | mac_x, | ||
double * | mac_y, | ||
double * | mac_z | ||
) |
This function calculates location of the quarter of mean aerodynamic chord, and gives the chord lenght as well.
It uses the classical method that can be applied to trapozaidal wings. This method is used for each segment. The values are found by taking into account of sweep and dihedral. But the effect of insidance angle is neglected. These values should coinside with the values found with tornado tool.
[in] | cpacsHandle | Handle for the CPACS configuration |
[in] | wingUID | UID of the Wing |
[out] | mac_chord | Mean areadynamic chord length |
[out] | mac_x,mac_y,mac_z | - Position of the MAC |
TIGL_COMMON_EXPORT TiglReturnCode tiglWingGetSpan | ( | TiglCPACSConfigurationHandle | cpacsHandle, |
const char * | wingUID, | ||
double * | pSpan | ||
) |
Returns the span of a wing.
The calculation of the wing span is realized as follows:
[in] | cpacsHandle | Handle for the CPACS configuration |
[in] | wingUID | UID of the Wing |
[out] | pSpan | Wing span |