Main Page   Namespace List   Class Hierarchy   Alphabetical List   Data Structures   File List   Data Fields   Globals  

ExManagerOutput Class Reference

#include <ExManagerOutput.h>


Public Methods

 ExManagerOutput (void)
 ~ExManagerOutput (void)
void Reset (void)
void SetManagerMap (ExManagerMap *Map)
void SetManagerPVS (ExManagerPVS *PVS)
void SetManagerCollision (ExManagerCollision *Collision)
void SetManagerFog (ExManagerFog *Fog)
void SetManagerAnim (ExManagerAnimation *Anim)
void SetManagerWindow (ExManagerWindow *Window)
void SetManagerCam (ExManagerCam *Cam)
void SetManagerCommand (ExManagerCommand *Command)
void SetManagerInterface (ExManagerInterface *Interface)
void SetManagerConsole (ExManagerConsole *Console)
void SetManagerMenu (ExManagerMenu *Menu)
void DrawScene (void)
void Reshape (int w, int h)
void Init (void)

Data Fields

std::ostrstream * Consol
void(* WriteToConsol )(const char *Label)

Private Attributes

ExManagerPVSManagerPVS
ExManagerCollisionManagerCollision
ExManagerFogManagerFog
ExManagerAnimationManagerAnim
ExManagerWindowManagerWindow
ExManagerCamManagerCam
ExManagerCommandManagerCommand
ExManagerInterfaceManagerInterface
ExManagerMenuManagerMenu
ExManagerConsoleManagerConsole
ExManagerMapManagerMap


Constructor & Destructor Documentation

ExManagerOutput void   
 

Definition at line 26 of file ExManagerOutput.cpp.

References ExManagerOutput(), Guard, and UnGuard.

Referenced by ExManagerOutput(), and ~ExManagerOutput().

00027 {
00028 Guard(ExManagerOutput::ExManagerOutput(void))
00029 
00030 UnGuard
00031 }

~ExManagerOutput void   
 

Definition at line 33 of file ExManagerOutput.cpp.

References ExManagerOutput(), Guard, and UnGuard.

00034 {
00035 Guard(ExManagerOutput::~ExManagerOutput(void))
00036 UnGuard
00037 }


Member Function Documentation

void DrawScene void   
 

Definition at line 81 of file ExManagerOutput.cpp.

References ExManagerCommand::ApplyAction(), ExManagerMap::Draw(), ExManagerCam::Draw(), ExManagerPVS::DrawAllObject(), ExManagerConsole::DrawConsole(), ExManagerInterface::DrawInterface(), DrawScene(), ExManagerWindow::GetConsoleState(), ExManagerWindow::GetFpsState(), ExManagerWindow::GetGrilleState(), ExManagerWindow::GetInterfaceState(), ExManagerWindow::GetMotionBlurState(), ExManagerWindow::GetNetstatState(), ExManagerWindow::GetResolutionX(), ExManagerWindow::GetResolutionY(), Guard, ManagerCam, ManagerCommand, ManagerConsole, ManagerInterface, ManagerMap, ManagerPVS, ManagerWindow, ExManagerWindow::MotionBlur(), ExManagerWindow::ShowFps(), ExManagerWindow::ShowNetStat(), ExManagerWindow::Specialeffect(), and UnGuard.

Referenced by display(), and DrawScene().

00082 {
00083 Guard(ExManagerOutput::DrawScene(void))
00084 int plok=0;
00085         plok++;
00086         glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT);
00087     //0 Command
00088         ManagerCommand->ApplyAction();
00089         //1 Animation
00090         //2 Collision detection
00091         //3 Camera Postion and vue
00092     ManagerCam->Draw(ManagerWindow->GetResolutionX(),ManagerWindow->GetResolutionY());
00093 
00094         if(ManagerWindow->GetMotionBlurState()){ManagerWindow->MotionBlur();}
00095 
00096         //4 Draw Map
00097         ManagerMap->Draw();
00098         //5 Call Pvs to draw object
00099         ManagerPVS->DrawAllObject();
00100         
00101         //6 Draw interface 
00102         if(ManagerWindow->GetInterfaceState()){ManagerInterface->DrawInterface();}
00103         if(ManagerWindow->GetFpsState ()) { ManagerWindow->ShowFps(); }
00104         if(ManagerWindow->GetGrilleState()){glCallList(GRILLE);}
00105         if(ManagerWindow->GetNetstatState()){ManagerWindow->ShowNetStat();}
00106         
00107         
00108         
00109         //7 Draw Spirit
00110         ManagerWindow->Specialeffect();
00111         //8 Draw Menu
00112         //if(ManagerWindow->GetMenuState()){ManagerMenu->DrawMenu();}
00113         //9 Draw console
00114         if(ManagerWindow->GetConsoleState()){ManagerConsole->DrawConsole();}    
00115         glutSwapBuffers();
00116 UnGuard
00117 }

void Init void   
 

Definition at line 44 of file ExManagerOutput.cpp.

References Guard, Init(), and UnGuard.

Referenced by Init(), InitManager(), Reset(), and SetGlutCallBack().

00045 {
00046 Guard(ExManagerOutput::Init(void))
00047         glShadeModel(GL_SMOOTH);                                                        // Enable Smooth Shading
00048         glClearColor(0.0f, 0.0f, 0.0f, 0.5f);                           // Black Background
00049         glClearDepth(1.0f);                                                                     // Depth Buffer Setup
00050         glDepthFunc(GL_LEQUAL);                                                         // The Type Of Depth Testing To Do
00051         glCullFace(GL_BACK);
00052         glEnable(GL_CULL_FACE);
00053         //glEnable(GL_LIGHTING);
00054         glEnable(GL_COLOR_MATERIAL );
00055         glEnable(GL_DEPTH_TEST);
00056         glEnable(GL_AUTO_NORMAL);
00057         glEnable(GL_NORMALIZE);
00058         glEnable(GL_ALPHA_TEST);
00059         glLightModelf(GL_LIGHT_MODEL_TWO_SIDE,GL_FALSE);
00060         glLineWidth(1.5);
00061 UnGuard
00062 }

void Reset void   
 

Definition at line 39 of file ExManagerOutput.cpp.

References Init().

00040 {
00041         Init();
00042 }

void Reshape int    w,
int    h
 

Definition at line 64 of file ExManagerOutput.cpp.

References ExCCamera::Draw(), ExCCamera::GetClipFar(), ExCCamera::GetClipNear(), ExManagerCam::GetCurrentCam(), ExManagerWindow::GetResolutionX(), ExManagerWindow::GetResolutionY(), ExCCamera::GetZoom(), Guard, ManagerCam, ManagerWindow, Reshape(), ExManagerWindow::SetResolution(), and UnGuard.

Referenced by reshape(), and Reshape().

00065 {
00066 Guard(ExManagerOutput::Reshape(int w,int h))
00067         ManagerWindow->SetResolution(w,h);
00068         glMatrixMode(GL_PROJECTION);
00069         glLoadIdentity();
00070         glViewport(0,0,ManagerWindow->GetResolutionX(),ManagerWindow->GetResolutionY());
00071         gluPerspective(ManagerCam->GetCurrentCam()->GetZoom(),
00072                 (1.0f *ManagerWindow->GetResolutionX() / ManagerWindow->GetResolutionY()),
00073                 ManagerCam->GetCurrentCam()->GetClipNear(),
00074                 ManagerCam->GetCurrentCam()->GetClipFar());
00075         glMatrixMode(GL_MODELVIEW);
00076         glLoadIdentity();
00077         ManagerCam->GetCurrentCam()->Draw();
00078 UnGuard
00079 }

void SetManagerAnim ExManagerAnimation   Anim [inline]
 

Definition at line 80 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00080 {ManagerAnim = Anim;}

void SetManagerCam ExManagerCam   Cam [inline]
 

Definition at line 82 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00082 {ManagerCam = Cam;}

void SetManagerCollision ExManagerCollision   Collision [inline]
 

Definition at line 78 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00078 {ManagerCollision = Collision;}

void SetManagerCommand ExManagerCommand   Command [inline]
 

Definition at line 83 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00083 {ManagerCommand = Command;}

void SetManagerConsole ExManagerConsole   Console [inline]
 

Definition at line 85 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00085 {ManagerConsole=Console;}

void SetManagerFog ExManagerFog   Fog [inline]
 

Definition at line 79 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00079 {ManagerFog = Fog;}

void SetManagerInterface ExManagerInterface   Interface [inline]
 

Definition at line 84 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00084 {ManagerInterface=Interface;}

void SetManagerMap ExManagerMap   Map [inline]
 

Definition at line 76 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00076 {ManagerMap = Map;}

void SetManagerMenu ExManagerMenu   Menu [inline]
 

Definition at line 86 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00086 {ManagerMenu=Menu;}

void SetManagerPVS ExManagerPVS   PVS [inline]
 

Definition at line 77 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00077 {ManagerPVS = PVS;}

void SetManagerWindow ExManagerWindow   Window [inline]
 

Definition at line 81 of file ExManagerOutput.h.

Referenced by SetManagerLink().

00081 {ManagerWindow = Window;}


Field Documentation

std::ostrstream* Consol
 

Definition at line 73 of file ExManagerOutput.h.

Referenced by SetManagerLink().

ExManagerAnimation* ManagerAnim [private]
 

Definition at line 53 of file ExManagerOutput.h.

ExManagerCam* ManagerCam [private]
 

Definition at line 55 of file ExManagerOutput.h.

Referenced by DrawScene(), and Reshape().

ExManagerCollision* ManagerCollision [private]
 

Definition at line 51 of file ExManagerOutput.h.

ExManagerCommand* ManagerCommand [private]
 

Definition at line 56 of file ExManagerOutput.h.

Referenced by DrawScene().

ExManagerConsole* ManagerConsole [private]
 

Definition at line 59 of file ExManagerOutput.h.

Referenced by DrawScene().

ExManagerFog* ManagerFog [private]
 

Definition at line 52 of file ExManagerOutput.h.

ExManagerInterface* ManagerInterface [private]
 

Definition at line 57 of file ExManagerOutput.h.

Referenced by DrawScene().

ExManagerMap* ManagerMap [private]
 

Definition at line 60 of file ExManagerOutput.h.

Referenced by DrawScene().

ExManagerMenu* ManagerMenu [private]
 

Definition at line 58 of file ExManagerOutput.h.

ExManagerPVS* ManagerPVS [private]
 

Definition at line 50 of file ExManagerOutput.h.

Referenced by DrawScene().

ExManagerWindow* ManagerWindow [private]
 

Definition at line 54 of file ExManagerOutput.h.

Referenced by DrawScene(), and Reshape().

void(* WriteToConsol)(const char *Label)
 

Referenced by SetManagerLink().


The documentation for this class was generated from the following files:
Generated on Tue Aug 6 20:27:27 2002 for ExNihilo by doxygen1.2.17