topical media & game development

talk show tell print

graphic-directx-game-08-TriGridDemo-Vertex.h / h



  //=============================================================================
  // Vertex.h by Frank Luna (C) 2005 All Rights Reserved.
  //
  // This file contains all of our vertex structures.  We will add to it
  // as needed throughout the book.
  //=============================================================================
  
  ifndef VERTEX_H
  define VERTEX_H
  
  include <d3dx9.h>
  
  // Call in constructor and destructor, respectively, of derived application class.
  void InitAllVertexDeclarations();
  void DestroyAllVertexDeclarations();
  
  //===============================================================
  struct VertexPos
  {
          VertexPos():pos(0.0f, 0.0f, 0.0f){}
          VertexPos(float x, float y, float z):pos(x,y,z){}
          VertexPos(const D3DXVECTOR3& v):pos(v){}
  
          D3DXVECTOR3 pos;
          static IDirect3DVertexDeclaration9* Decl;
  };
  
  endif // VERTEX_H


(C) Æliens 20/2/2008

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.