QhullSet.cpp
Go to the documentation of this file.
00001 /****************************************************************************
00002 **
00003 ** Copyright (c) 2008-2011 C.B. Barber. All rights reserved.
00004 ** $Id: //main/2011/qhull/src/libqhullcpp/QhullSet.cpp#2 $$Change: 1342 $
00005 ** $DateTime: 2011/03/07 21:55:47 $$Author: bbarber $
00006 **
00007 ****************************************************************************/
00008 
00009 #//! QhullSet -- Qhull's facet structure, facetT, as a C++ class
00010 
00011 #include "QhullError.h"
00012 #include "QhullSet.h"
00013 
00014 #ifdef _MSC_VER  // Microsoft Visual C++ -- warning level 4
00015 #endif
00016 
00017 namespace orgQhull {
00018 
00019 #//static members
00020 
00021 setT QhullSetBase::
00022 s_empty_set;
00023 
00024 // Same code for qh_setsize [qset.c] and QhullSetBase::count
00025 int QhullSetBase::count(const setT *set)
00026 {
00027     int size;
00028     const int *sizep;
00029 
00030     if (!set)
00031         return(0);
00032     sizep= SETsizeaddr_(set);
00033     if ((size= *sizep)) {
00034         size--;
00035         if (size > set->maxsize) {
00036             // FIXUP QH11022 How to add additional output to a error? -- qh_setprint(qhmem.ferr, "set: ", set);
00037             throw QhullError(10032, "QhullSet internal error: current set size %d is greater than maximum size %d\n",
00038                 size, set->maxsize);
00039         }
00040     }else
00041         size= set->maxsize;
00042     return size;
00043 }
00044 
00045 
00046 }//namespace orgQhull
00047 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


libqhull
Author(s): Robert Krug
autogenerated on Tue Jun 18 2013 12:38:50