#include "lvkrn.h"
L_LVKRN_API L_INT L_VecSetOrigin(pVector, pOrigin)
pVECTORHANDLE pVector; |
pointer to a vector handle |
const pVECTORPOINT pOrigin; |
pointer to a vector point |
Sets new origin for a vector handle.
Parameter |
Description |
pVector |
Pointer to a vector handle. |
pOrigin |
Pointer to a VECTORPOINT structure that contains the new origin. If this parameter is NULL, the new origin will be calculated based on the objects currently in the vector handle. |
SUCCESS |
The function was successful. |
< 1 |
An error occurred. Refer to Return Codes. |
The origin of a vector drawing may change whenever new objects are added. To insure that the drawing is centered around its origin, call L_VecSetOrigin(pVector, NULL) after adding objects.
The origin may be retrieved using L_VecGetOrigin.
L_VecApplyTransformation must be called to make the new origin take effect. If you do not, your changes will not be saved.
Required DLLs and Libraries
LVKRN For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application. |
Functions: |
|
Topics: |
This example will recalculate the origin of a vector image.
L_INT VecSetOriginExample(pVECTORHANDLE pVector)
{
/* re-calculate origin */
return L_VecSetOrigin( pVector, NULL );
}