00001 /* 00002 * PROPRIETARY INFORMATION. This software is proprietary to 00003 * Side Effects Software Inc., and is not to be reproduced, 00004 * transmitted, or disclosed in any way without written permission. 00005 * 00006 * Produced by: 00007 * Andrew Clinton 00008 * Side Effects Software Inc 00009 * 123 Front Street West, Suite 1401 00010 * Toronto, Ontario 00011 * Canada M5J 2M2 00012 * 416-504-9876 00013 * 00014 * NAME: UT_QuickHull.h ( UT Library, C++) 00015 * 00016 * COMMENTS: This class is used to compute the convex hull area from a 00017 * list of points. 00018 */ 00019 00020 #ifndef __UT_QuickHull__ 00021 #define __UT_QuickHull__ 00022 00023 #include "UT_API.h" 00024 #include "UT_RefArray.h" 00025 #include "UT_Vector3.h" 00026 00027 class UT_API UT_QuickHull { 00028 public: 00029 UT_QuickHull(); 00030 virtual ~UT_QuickHull(); 00031 00032 // Add a point to the hull 00033 void append(const UT_Vector3 &P); 00034 00035 // Compute the 2D convex hull area relative to the given plane normal. 00036 fpreal area2D(const UT_Vector3 &N) const; 00037 00038 private: 00039 UT_RefArray<UT_Vector3> myPoints; 00040 }; 00041 00042 #endif 00043
1.5.9