Public Member Functions
Point Class Reference

Detailed Description

A Point is a generic concept used to describe a Geometry's Vertex or ControlPoint.

Having a generic term for this concept allows the user to write code to traverse an objects geometry in a generic fashion without resorting to special case handling based on a specific geometry type.

See also:
CPointRefArray, Segment, Facet, Geometry
Example:
        using namespace XSI;
        using namespace MATH;

        Application app;
        Model root = app.GetActiveSceneRoot();

        X3DObject myGrid;
        root.AddGeometry( L"Grid", L"MeshSurface", L"", myGrid );

        Geometry geom = myGrid.GetActivePrimitive().GetGeometry(0);

        Point point(geom.GetPoints().GetItem(0) );

        CVector3 pos( point.GetPosition() );

        app.LogMessage( CValue(pos.GetX()).GetAsText() + L"," +
                CValue(pos.GetY()).GetAsText() + L"," +
                CValue(pos.GetZ()).GetAsText() );

#include <xsi_point.h>

Inheritance diagram for Point:
Inheritance graph
[legend]

List of all members.

Public Member Functions

  Point ()
  ~Point ()
  Point (const CRef &in_ref)
  Point (const Point &in_obj)
bool  IsA (siClassID in_ClassID) const
siClassID  GetClassID () const
Point operator= (const Point &in_obj)
Point operator= (const CRef &in_ref)
MATH::CVector3  GetPosition () const
CStatus  PutPosition (const MATH::CVector3 &in_vect)
MATH::CVector3  GetNormal (bool &io_bValid) const
LONG  GetIndex () const
CSampleRefArray  GetSamples () const
SubComponent  GetSubComponent () const
Point  Navigate (siNavigateComponentType in_siNavigate) const

Constructor & Destructor Documentation

Point ( )

Default constructor.

~Point ( )

Default destructor.

Point ( const CRef in_ref )

Constructor.

Parameters:
in_ref constant reference object.
Point ( const Point in_obj )

Copy constructor.

Parameters:
in_obj constant class object.

Member Function Documentation

bool IsA ( siClassID  in_ClassID ) const [virtual]

Returns true if a given class type is compatible with this API class.

Parameters:
in_ClassID class type.
Returns:
true if the class is compatible, false otherwise.

Reimplemented from SIObject.

Reimplemented in ControlPoint, and Vertex.

siClassID GetClassID ( ) const [virtual]

Returns the type of the API class.

Returns:
The class type.

Reimplemented from SIObject.

Reimplemented in ControlPoint, and Vertex.

Point& operator= ( const Point in_obj )

Creates an object from another object. The newly created object is set to empty if the input object is not compatible.

Parameters:
in_obj constant class object.
Returns:
The new Point object.
Point& operator= ( const CRef in_ref )

Creates an object from a reference object. The newly created object is set to empty if the input reference object is not compatible.

Parameters:
in_ref constant class object.
Returns:
The new Point object.

Reimplemented from SIObject.

Reimplemented in ControlPoint, and Vertex.

MATH::CVector3 GetPosition ( ) const

Returns the position of this Point object.

Returns:
The position of this Point object.
CStatus PutPosition ( const MATH::CVector3 in_vect )

Sets the position of this Point object.

Warning:
Not implemented.
Parameters:
in_vect CVector3 object.
Returns:
CStatus::OK success
CStatus::Fail failure
MATH::CVector3 GetNormal ( bool &  io_bValid ) const

Returns the normal of this Point object.

Parameters:
io_bValid Returns true if the normal is valid.
Returns:
The normal expressed as a CVector3 object.
LONG GetIndex ( ) const

Returns the index of the Point in the geometry's Point array.

Returns:
The Point index.
CSampleRefArray GetSamples ( ) const

Returns an array of Sample objects for this Point..

Returns:
Array of Sample objects.
SubComponent GetSubComponent ( ) const

Creates a SubComponent object from this Point object.

Returns:
The SubComponent object.
Point Navigate ( siNavigateComponentType  in_siNavigate ) const

Navigates the Point objects of the underlying geometry as specifed by the navigation component type. Navigation is circular -- for instance, navigating beyond the last component will return the first and vis versa.

Parameters:
in_siNavigate Type of direction for navigating the Facet objects.
Returns:
The Point object being visited.

The documentation for this class was generated from the following file: