Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
TRawArray
Inherited By:
None.
Purpose:
TGRPointArray is a low-level class that provides access to linear arrays of TGRPoints (2-D homogeneous points). Derived from MCollectible, TGRPointArray does not perform any computation. TGRPointArray is used by TGCurve and TGLoop. TGRPointArray is directly analogous to TGPointArray, which handles arrays of TGPoints (non-homogeneous points).
Instantiation:
Allocate on the heap or the stack.
Deriving Classes:
Do not create derived classes.
Concurrency:
Not multithread safe.
Resource Use:
No special requirements.
- TGRPointArray (unsigned long size =0)
- TGRPointArray (const TGPointArray & source)
- TGRPointArray (const TGRPointArray & source)
Interface Category:
API.
Purpose:
- Creates an array of TGRPoints of the specified size. The points are left uninitialized. Initialization is the responsibility of the class using the points.
- Copy constructor.
Note: A TGRPointArray can be created from a TGPointArray with the fW fields set to 1.0; however, the reverse is not true because an explicit projection is needed.
- Copy constructor.
Calling Context:
- Call this function directly.
- Called to copy an object. You can also call this function directly.
- Called to copy an object. You can also call this function directly.
Parameters:
- unsigned long size =0 -The size of the point array.
- const TGPointArray & source -The point array to be copied.
- const TGRPointArray & source -The point array to be copied.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
~ TGRPointArray ()
Interface Category:
API.
Purpose:
Destructor.
Calling Context:
Called to destroy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TGRPointArray::GetPoint
TGRPoint GetPoint (unsigned long i) const
Interface Category:
API.
Purpose:
Get the TGRPoint at the specified index.
Calling Context:
Call this function directly.
Parameters:
- unsigned long i -The index (whose value must be less than the number of points in the array).
Return Value:
The point at the specified index.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TGRPointArray::SetPoint
void SetPoint (unsigned long i, const TGRPoint & p)
Interface Category:
API.
Purpose:
Sets the TGRPoint at the specified index, to the specified point.
Calling Context:
Call this function directly.
Parameters:
- unsigned long i -The index (whose value must be less than the number of points in the array).
- const TGRPoint & p -The new point.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TGRPointArray::GetNumberOfPoints
unsigned long GetNumberOfPoints () const
Interface Category:
API.
Purpose:
Returns the number of points in the TGRPointArray.
Calling Context:
Call this function directly.
Parameters:
Return Value:
The number of points in the array.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TGRPointArray::GetBounds
TGRect GetBounds () const
Interface Category:
API.
Purpose:
Creates a TGRect that bounds the points in the TGPointArray.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.