You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
308 B

4 years ago
  1. #pragma once
  2. #include "glew.h"
  3. struct VertexData
  4. {
  5. float position[3];
  6. float texcoord[2];
  7. float normal[3];
  8. };
  9. class ObjModel
  10. {
  11. public:
  12. GLuint mVBO, mIBO;
  13. unsigned int mIndexCount;
  14. public:
  15. void Init(const char*modelFilePath);
  16. void Bind(GLint posLoc,GLint texcoordLoc,GLint normalLoc);
  17. void Draw();
  18. };