opennurbs_pointgeometry.h
Go to the documentation of this file.
00001 /* $NoKeywords: $ */
00002 /*
00003 //
00004 // Copyright (c) 1993-2012 Robert McNeel & Associates. All rights reserved.
00005 // OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert
00006 // McNeel & Associates.
00007 //
00008 // THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY.
00009 // ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF
00010 // MERCHANTABILITY ARE HEREBY DISCLAIMED.
00011 //                              
00012 // For complete openNURBS copyright information see <http://www.opennurbs.org>.
00013 //
00015 */
00016 
00017 #if !defined(OPENNURBS_POINT_GEOMETRY_INC_)
00018 #define OPENNURBS_POINT_GEOMETRY_INC_
00019 
00020 // NOTE:  ON_3dPoint is much more efficient than ON_Point.
00021 //        Use ON_Point when you need a polymorphic 3d point
00022 //        that is derived from ON_Geometry or ON_Object.
00023 
00024 class ON_CLASS ON_Point : public ON_Geometry
00025 {
00026 public:
00027   ON_3dPoint point;
00028 
00029   ON_Point();
00030   ON_Point(const ON_Point&);
00031   ON_Point(const ON_3dPoint&);
00032   ON_Point(double,double,double);
00033   ~ON_Point();
00034   ON_Point& operator=(const ON_Point&);
00035   ON_Point& operator=(const ON_3dPoint&);
00036   
00037   operator double*();
00038   operator const double*() const;
00039   operator ON_3dPoint*();
00040   operator const ON_3dPoint*() const;
00041   operator ON_3dPoint&();
00042   operator const ON_3dPoint&() const;
00043 
00045   //
00046   // ON_Object overrides
00047   //
00048 
00049   /*
00050   Description:
00051     Tests an object to see if its data members are correctly
00052     initialized.
00053   Parameters:
00054     text_log - [in] if the object is not valid and text_log
00055         is not NULL, then a brief englis description of the
00056         reason the object is not valid is appened to the log.
00057         The information appended to text_log is suitable for 
00058         low-level debugging purposes by programmers and is 
00059         not intended to be useful as a high level user 
00060         interface tool.
00061   Returns:
00062     @untitled table
00063     true     object is valid
00064     false    object is invalid, uninitialized, etc.
00065   Remarks:
00066     Overrides virtual ON_Object::IsValid
00067   */
00068   ON_BOOL32 IsValid( ON_TextLog* text_log = NULL ) const;
00069 
00070   void Dump( ON_TextLog& ) const; // for debugging
00071 
00072   ON_BOOL32 Write(
00073          ON_BinaryArchive&  // serialize definition to binary archive
00074        ) const;
00075 
00076   ON_BOOL32 Read(
00077          ON_BinaryArchive&  // restore definition from binary archive
00078        );
00079 
00080   ON::object_type ObjectType() const;
00081 
00083   //
00084   // ON_Geometry overrides
00085   //
00086 
00087   int Dimension() const;
00088 
00089   ON_BOOL32 GetBBox( // returns true if successful
00090          double*,    // boxmin[dim]
00091          double*,    // boxmax[dim]
00092          ON_BOOL32 = false  // true means grow box
00093          ) const;
00094 
00095   ON_BOOL32 Transform( 
00096          const ON_Xform&
00097          );
00098 
00099   // virtual ON_Geometry::IsDeformable() override
00100   bool IsDeformable() const;
00101 
00102   // virtual ON_Geometry::MakeDeformable() override
00103   bool MakeDeformable();
00104 
00105   ON_BOOL32 SwapCoordinates(
00106         int, int        // indices of coords to swap
00107         );
00108 
00109 private:
00110   ON_OBJECT_DECLARE(ON_Point);
00111 };
00112 
00113 #endif


pcl
Author(s): Open Perception
autogenerated on Wed Aug 26 2015 15:27:03