OpenVSPAPI  3.19.0
Functions
General API Utility Functions

This group of functions is provided for general API utilities, such as printing to stdout, performing basic math functions, and identifying basic OpenVSP information.

Click here to return to the main page. More...

Functions

void Print (const string &in data, bool new_line=true)
 
void Print (const vec3d &in data, bool new_line=true)
 
void Print (double data, bool new_line=true)
 
void Print (int data, bool new_line=true)
 
double Min (double x, double y)
 
double Max (double x, double y)
 
double Rad2Deg (double r)
 
double Deg2Rad (double d)
 
string GetVSPVersion ()
 
string GetVSPExePath ()
 
void VSPCheckSetup ()
 
void VSPRenew ()
 

Detailed Description

Function Documentation

◆ Deg2Rad()

double Deg2Rad ( double  d)

Convert degrees to radians

Parameters
[in]dValue in degrees
Returns
Value in radians

◆ GetVSPExePath()

string GetVSPExePath ( )

Get the path to the OpenVSP executable. OpenVSP will assume that the VSPAERO, VSPSLICER, and VSPVIEWER are in the same directory unless instructed otherwise.

Returns
Path to the OpenVSP executable

◆ GetVSPVersion()

string GetVSPVersion ( )

Get the version of the OpenVSP instance currently running

Returns
OpenVSP version string (i.e. "OpenVSP 3.17.1")

◆ Max()

double Max ( double  x,
double  y 
)

Get the maximum of two values -> (x > y ) ? x : y

Parameters
[in]xFirst value
[in]ySecond value
Returns
Largest of x and y

◆ Min()

double Min ( double  x,
double  y 
)

Get the minimum of two values -> (x < y ) ? x : y

Parameters
[in]xFirst value
[in]ySecond value
Returns
Smallest of x and y

◆ Print() [1/4]

void Print ( const string &in  data,
bool  new_line = true 
)

Print a string to stdout

Parameters
[in]dataValue of string type
[in]new_lineFlag to append a new line escape sequence to data

◆ Print() [2/4]

void Print ( const vec3d &in  data,
bool  new_line = true 
)

Print a vec3d to stdout

Parameters
[in]dataValue of vec3d type
[in]new_lineFlag to append a new line escape sequence to data

◆ Print() [3/4]

void Print ( double  data,
bool  new_line = true 
)

Print a double to stdout

Parameters
[in]dataValue of double type
[in]new_lineFlag to append a new line escape sequence to data

◆ Print() [4/4]

void Print ( int  data,
bool  new_line = true 
)

Print an integer to stdout

Parameters
[in]datainteger value
[in]new_lineflag to append a new line escape sequence to data

◆ Rad2Deg()

double Rad2Deg ( double  r)

Convert radians to degrees

Parameters
[in]rValue in radians
Returns
Value in degrees

◆ VSPCheckSetup()

void VSPCheckSetup ( )

Check if OpenVSP has been initialized successfully. If not, the OpenVSP instance will be exited. This call should be placed at the begining of all API scripts.

◆ VSPRenew()

void VSPRenew ( )

Clear and reinitialize OpenVSP to all default settings