|
Core library
A simple library for handling 3D scenes
|
00001 #ifndef FACE_H 00002 #define FACE_H 00003 00004 #include <vector> 00005 #include "vertex.h" 00006 00007 using namespace std; 00008 00017 class CORE_EXPORT Face 00018 { 00019 public: 00023 Face(); 00024 00028 Face(int i0, int i1, int i2, int i3=-1); 00029 00033 void addVertexIndex(int i); 00034 00038 int numVertices() const; 00039 00043 int vertexIndex(int i) const; 00044 00049 Vector normal() const; 00050 00056 void computeNormal(const vector<Vertex> &verts); 00057 00058 private: 00059 // atributs 00060 Vector pnormal; // normal de la cara 00061 vector<int> pvertices; // vector amb els indexs dels vertexs de la cara 00062 }; 00063 00064 #endif
1.7.6.1