The DejaVU Framework -- hush 3.1

include: hush-src-multi-GamePlayer-Hall.h /home/ae/media


- [up] [top] - index make include source logic grammar scripts html configure mx slides talks scenes reports projects
<body bgcolor="#FFFFFF" text="#000000">

//------------------------------------------------------------------------------
// File: Hall.h
//
// Desc: DirectShow sample code - MultiVMR9 GamePlayer
//
// Copyright (c) Microsoft Corporation.  All rights reserved.
//------------------------------------------------------------------------------

#pragma once

static const DWORD  g_FVFHall = D3DFVF_XYZ | D3DFVF_DIFFUSE | D3DFVF_TEX1;

<h4>
/////////////////////////// CHall
/////////////////////////////////</h4>


<blockquote> *******************************************************************************\ class CHall representation of the "hall" environment, a wall and a floor \********************************************************************************</blockquote>


<h4 align=right text=red> CHall</h4><hr>
  class CHall
{
public:
    CHall();
    virtual ~CHall();

    HRESULT Initialize( IDirect3DDevice9* pDevice);
    HRESULT RestoreDeviceObjects( IDirect3DDevice9* pDevice);
    HRESULT Render( IDirect3DDevice9* pDevice);
    HRESULT Compose( DWORD t );
    HRESULT SetSpeed( float fSpeed );

// subclasses
public:
    struct Vertex
    {
        D3DVECTOR Pos;
        D3DCOLOR  color;
        float     tu;
        float     tv;
    } Vertex;

private:
    // some textured 3D plane ( a wall or a floor)
<hr>

CPlane</h4>
      class CPlane
      {
      public:
          CPlane( IDirect3DDevice9* pDevice, 
                  TCHAR *achName, 
                  LPCTSTR lpResourceName,
                  float fTilesU, 
                  float fTilesV, 
                  D3DXMATRIX& M, 
                  float a,
                  HRESULT *phr);
  
          ~CPlane();
  
          HRESULT Render( IDirect3DDevice9 *pDevice );
          HRESULT SetSpeed( float S);
          HRESULT Compose( DWORD t );
  
          // data
          IDirect3DTexture9*      m_pTexture;
          struct Vertex           m_V[4];
          D3DXMATRIXA16           m_M;
          TCHAR                   m_achTextureName[MAX_PATH];
          float                   m_fU;
          float                   m_fV;
          float                   m_du;
          float                   m_fSpeed;
      };

// class CPlane
  
  // data
  public:
  
  private:
      float           m_fSpeed;
      CPlane*         m_pFloor;
      CPlane*         m_pWall;
      D3DLIGHT9       m_light;
  };


  
  


(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. <script src="http://www.google-analytics.com/urchin.js" type="text/javascript"> </script> <script type="text/javascript"> _uacct = "UA-2780434-1"; urchinTracker(); </script>

Hush Online Technology
hush@cs.vu.nl
03/12/09