replace m_data with m_vertices
This commit is contained in:
parent
594642f489
commit
f46f887472
5
WFObj.cc
5
WFObj.cc
@ -104,8 +104,8 @@ WFObj::~WFObj()
|
||||
|
||||
void WFObj::clear()
|
||||
{
|
||||
m_data = std::vector< std::vector<std::string> >();
|
||||
m_loadedVertex = false;
|
||||
for (int i = 0; i < sizeof(m_vertices)/sizeof(m_vertices[0]); i++)
|
||||
m_vertices[i].clear();
|
||||
}
|
||||
|
||||
bool WFObj::load(const char *fname)
|
||||
@ -193,7 +193,6 @@ GLuint WFObj::render(bool doTextureInfo, bool enableBlending)
|
||||
GLuint list = glGenLists(1);
|
||||
glNewList(list, GL_COMPILE);
|
||||
int len = m_data.size();
|
||||
enum { VERTEX, VERTEX_TEXTURE, VERTEX_NORMAL, VERTEX_TYPES };
|
||||
vector<Vertex> vertices[VERTEX_TYPES];
|
||||
int numVertsLast = 0;
|
||||
bool inFace = false;
|
||||
|
5
WFObj.h
5
WFObj.h
@ -48,6 +48,8 @@ public:
|
||||
WFObj * m_obj;
|
||||
};
|
||||
|
||||
enum { VERTEX, VERTEX_TEXTURE, VERTEX_NORMAL, VERTEX_TYPES };
|
||||
|
||||
/* constructors */
|
||||
WFObj(loadfile_t lf = NULL, loadtexture_t lt = NULL);
|
||||
~WFObj();
|
||||
@ -80,10 +82,9 @@ protected:
|
||||
std::string getLine(const Buff & buff, size_t idx, size_t *update_idx);
|
||||
|
||||
/* variables */
|
||||
std::vector< std::vector<std::string> > m_data;
|
||||
std::vector<Vector> m_vertices[VERTEX_TYPES];
|
||||
FileLoader::Path m_path;
|
||||
float m_aabb[6];
|
||||
bool m_loadedVertex;
|
||||
loadfile_t m_loadfile;
|
||||
loadtexture_t m_loadtexture;
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user