home *** CD-ROM | disk | FTP | other *** search
/ Photo CD Demo 1 / Demo.bin / graphtal / hull.h < prev    next >
C/C++ Source or Header  |  1992-10-22  |  1KB  |  49 lines

  1. /*
  2.  * Hull.h - class definition for hulls (collection of geometric
  3.  *          objects).
  4.  *
  5.  * Copyright (C) 1992, Christoph Streit (streit@iam.unibe.ch)
  6.  * All rights reserved.
  7.  *
  8.  * This software may be freely copied, modified, and redistributed
  9.  * provided that this copyright notice is preserved on all copies.
  10.  *
  11.  * You may not distribute this software, in whole or in part, as part of
  12.  * any commercial product without the express consent of the authors.
  13.  *
  14.  * There is no warranty or other guarantee of fitness of this software
  15.  * for any purpose.  It is provided solely "as is".
  16.  *
  17.  */
  18.  
  19. #ifndef Hull_H
  20. # define Hull_H
  21.  
  22. #include "GeoObject.h"
  23. #include "BoundingBox.h"
  24. #include "rcString.h"
  25. #include "Polygon.h"
  26. #include "table.h"
  27.  
  28. //___________________________________________________________ Hull
  29.  
  30. class Hull 
  31. {
  32. public:
  33.   Hull();
  34.   ~Hull();
  35.  
  36.   void addPrimitive(GeoObject*);
  37.   long numPrimitives() const;
  38.   int intersect(const Ray&, real&, GeoObject*&) const;
  39.   PolygonList* convertToPolygonList(const BoundingBox&) const;
  40.  
  41. private:
  42.   GeoObjectList* primitives;
  43. };
  44.  
  45. typedef Hull* HullPtr;
  46. declareTable(HullSymtab, rcString, HullPtr);
  47.  
  48. #endif // Hull_H
  49.