AST3D.CPP
Upload User: nthssl
Upload Date: 2022-04-05
Package Size: 25357k
Code Size: 1k
Category:

OpenCV

Development Platform:

Visual C++

  1. // Ast3D.cpp: implementation of the CAst3D class.
  2. //
  3. //////////////////////////////////////////////////////////////////////
  4. #include "stdafx.h"
  5. #include "MyGame.h"
  6. #include "Ast3D.h"
  7. #ifdef _DEBUG
  8. #undef THIS_FILE
  9. static char THIS_FILE[]=__FILE__;
  10. #define new DEBUG_NEW
  11. #endif
  12. //////////////////////////////////////////////////////////////////////
  13. // Construction/Destruction
  14. //////////////////////////////////////////////////////////////////////
  15. CAst3D::~CAst3D()
  16. {
  17. }
  18. int CAst3D::Draw()
  19. {
  20. glPushMatrix();
  21. glTranslate(p);
  22. glRotatef(angle,0,0,1);
  23. glScalef(size*3,size*3,size*3);
  24. glColor3f((GLfloat).8,(GLfloat).8,(GLfloat).7);
  25. int nt=M.Draw();
  26. glPopMatrix();
  27. return nt;
  28. }