Ovis_2D_Polygon_Scale_Get()
Abstract
Returns the scale of the 2D polygon.
Syntax
Ovis_2D_Polygon_Scale_Get (poly_ptr, x_scale_ptr, y_scale_ptr)
| Argument | Type | Description |
|---|---|---|
poly_ptr |
OvisT_Polygon * |
Polygon |
x_scale_ptr |
double * |
X scale |
y_scale_ptr |
double * |
Y scale |
Return Type
OvisT_Compcode
OvisC_Compcode_Success if the provided object is a valid 2D polygon (circle or square). Otherwise, it returns OvisC_Compcode_Failure.
Header
ovis_decoration.h
Details
This function returns the x_scale and y_scale of the polygon. The 2D polygon can be a square or circle.
Example
OvisT_2D_Circle * circle;
double x_scale, y_scale;
/* … circle created previously */
Ovis_2D_Polygon_Scale_Get (circle, &x_scale, &y_scale);
Errors
- Decoration is not a 2D circle or square.
- Decoration is NIL.
- Return address for X scale value is NIL.
- Return address for Y scale value is NIL.
Reference
- Use the function
Ovis_2D_Polygon_Scale_Set()to modify the radius for circles or squares.