home *** CD-ROM | disk | FTP | other *** search
/ PC World 2006 July & August / PCWorld_2006-07-08_cd.bin / temacd / planearcade / planearcade.exe / Tank3.bmp / skydome.h < prev    next >
C/C++ Source or Header  |  2004-01-28  |  950b  |  50 lines

  1.  
  2. #ifndef _SKYDOME_H_
  3. #define _SKYDOME_H_
  4.  
  5. //-----------------------------------
  6. //CUSTOMVERTEX
  7. //------------------------------------
  8. struct CUSTOMVERTEXSKYDOME
  9. {
  10.     float x,y,z;
  11.     float u, v;   
  12. };
  13.  
  14. //CUSTOMVERTEXT
  15. #define D3DFVF_CUSTOMVERTEXSKYDOME (D3DFVF_XYZ|D3DFVF_TEX1)
  16.  
  17. //--------------------------------------------------------------------
  18. // Name: SkyDome Class
  19. // Desc: ************
  20. //--------------------------------------------------------------------
  21. class SKYDOME
  22. {
  23.  
  24. private:
  25.  
  26.     //vertex buffer
  27.     LPDIRECT3DVERTEXBUFFER9 g_pVB ; 
  28.     //textura
  29.     LPDIRECT3DTEXTURE9    g_pTexture; 
  30.  
  31.     //pocet vertexov
  32.     int NumVer;
  33.  
  34. public:
  35.  
  36.     SKYDOME();
  37.     ~SKYDOME();
  38.  
  39.     float Rotation;  //Yaw
  40.     VECTOR3D Pos;    //pozicia
  41.     VECTOR3D Sca;    //scale
  42.  
  43.     void CreateSkyDome(float radius, float dtheta, float dphi, float hTile, float vTile);
  44.     void LoadTexture(char *FileName);
  45.     void Render();
  46.  
  47. };
  48.  
  49.  
  50. #endif _SKYDOME_H_