source: GTP/trunk/Lib/Geom/GTGeometry/include/GeoMeshStripifier.h @ 774

Revision 774, 2.5 KB checked in by gumbau, 18 years ago (diff)

GTGeometry and GeoTool? initial imports

Line 
1/*      ==========================================================================
2 *      (C) 2005 Universidad Jaime I de Castellón
3 *      ==========================================================================
4 *      PROYECT:        GAME TOOLS
5 *      ==========================================================================*/
6/**     CONTENT:        Make triangle strips meshes from triangle list meshes.
7        *
8        *
9        *       @file   GeoMeshStripifier.h
10/*===========================================================================*/
11
12#ifndef __GEO_STRIPIFIER__
13#define __GEO_STRIPIFIER__
14
15#include <GeoMesh.h>
16
17namespace Geometry
18{
19
20        /// Stripifier interface class.
21        /** This module implements methods that extract triangle strips from triangle meshes.
22                \n
23
24Inputs:\n
25        - This module receives a pointer to a Geometry::Mesh object containing the model to be stripified.
26        .
27
28Outputs:\n
29        - The stripified mesh, contained also in a Geometry::Mesh object.
30        .
31
32        */
33        class MeshStripifier
34        {
35                public:
36                        /// Class constructor, receives as a parameter a const pointer to the object that describes a mesh.
37                        MeshStripifier ();
38                        MeshStripifier (const Geometry::Mesh *);
39
40                        /// virtual class destructor.
41                        virtual ~MeshStripifier (void);
42
43                        /// Copy constructor
44                        //MeshStripifier(const MeshStripifier&);
45
46                        /// Assignment operator
47                        //MeshStripifier& operator =(const MeshStripifier&);
48
49                        /// Starts the stripification process. This is a pure virtual method and must be overloaded in a derived class that implements a stripification algorithm.
50                        virtual int Stripify()=0;
51
52                        /// Returns the stripified mesh.
53                        Mesh *  GetMesh ();
54
55                protected:
56
57                        //      Progress bar function.
58                        Geometry::TIPOFUNC mUPB;
59
60                        //      Mesh object.
61                        Geometry::Mesh          *mGeoMesh;
62        };
63
64        class CustomStripifier : public MeshStripifier
65        {
66                public:
67                       
68                        /// Class constructor, receives as a parameter a const pointer to the object that describes a mesh.
69                        CustomStripifier();
70
71                        CustomStripifier(       const Geometry::Mesh    *geoMesh);
72
73                        /// Class destructor.
74                        ~CustomStripifier(void);
75
76                        /// Copy constructor
77                        //CustomStripifier(const CustomStripifier&);
78
79                        /// Assignment operator
80                        //CustomStripifier& operator =(const CustomStripifier&);
81
82                        /// Starts the stripification process. This is a custom stripification method.
83                        int Stripify();
84
85                        /// Returns the stripified mesh.
86                        Mesh *  GetMesh();
87                       
88                        //      Set the progress bar function.
89                        void    SetProgressFunc(Geometry::TIPOFUNC upb);
90        };
91
92}
93
94#endif
95
Note: See TracBrowser for help on using the repository browser.