Pyrogenesis HEAD
Pyrogenesis, a RTS Engine
|
#include <GameView.h>
Public Member Functions | |
CGameView (Renderer::Backend::IDevice *device, CGame *pGame) | |
~CGameView () override | |
void | SetViewport (const SViewPort &vp) |
void | RegisterInit () |
void | Update (const float deltaRealTime) |
Updates all the view information (i.e. More... | |
void | BeginFrame () |
void | Prepare (Renderer::Backend::IDeviceCommandContext *deviceCommandContext) |
void | Render (Renderer::Backend::IDeviceCommandContext *deviceCommandContext) |
void | RenderOverlays (Renderer::Backend::IDeviceCommandContext *deviceCommandContext) |
InReaction | HandleEvent (const SDL_Event_ *ev) |
CVector3D | GetCameraPivot () const |
CVector3D | GetCameraPosition () const |
CVector3D | GetCameraRotation () const |
float | GetCameraZoom () const |
void | SetCamera (const CVector3D &pos, float rotX, float rotY, float zoom) |
void | MoveCameraTarget (const CVector3D &target) |
void | ResetCameraTarget (const CVector3D &target) |
void | FollowEntity (entity_id_t entity, bool firstPerson) |
entity_id_t | GetFollowedEntity () |
DECLARE_BOOLEAN_SETTING (Culling) | |
DECLARE_BOOLEAN_SETTING (LockCullCamera) | |
DECLARE_BOOLEAN_SETTING (ConstrainCamera) | |
CCamera * | GetCamera () |
CCinemaManager * | GetCinema () |
CObjectManager & | GetObjectManager () |
void | EnumerateObjects (const CFrustum &frustum, SceneCollector *c) override |
Send all objects that can be seen when rendering the given frustum to the scene collector. More... | |
CLOSTexture & | GetLOSTexture () override |
Return the LOS texture to be used for rendering this scene. More... | |
CTerritoryTexture & | GetTerritoryTexture () override |
Return the territory texture to be used for rendering this scene. More... | |
CMiniMapTexture & | GetMiniMapTexture () override |
Return the minimap texture to be used for rendering this scene. More... | |
Private Member Functions | |
NONCOPYABLE (CGameView) | |
void | UnloadResources () |
Private Member Functions inherited from Scene | |
virtual | ~Scene () |
virtual void | EnumerateObjects (const CFrustum &frustum, SceneCollector *c)=0 |
Send all objects that can be seen when rendering the given frustum to the scene collector. More... | |
virtual CLOSTexture & | GetLOSTexture ()=0 |
Return the LOS texture to be used for rendering this scene. More... | |
virtual CTerritoryTexture & | GetTerritoryTexture ()=0 |
Return the territory texture to be used for rendering this scene. More... | |
virtual CMiniMapTexture & | GetMiniMapTexture ()=0 |
Return the minimap texture to be used for rendering this scene. More... | |
Private Attributes | |
CGameViewImpl * | m |
CGameView::CGameView | ( | Renderer::Backend::IDevice * | device, |
CGame * | pGame | ||
) |
|
override |
void CGameView::BeginFrame | ( | ) |
CGameView::DECLARE_BOOLEAN_SETTING | ( | ConstrainCamera | ) |
CGameView::DECLARE_BOOLEAN_SETTING | ( | Culling | ) |
CGameView::DECLARE_BOOLEAN_SETTING | ( | LockCullCamera | ) |
|
overridevirtual |
Send all objects that can be seen when rendering the given frustum to the scene collector.
frustum | The frustum that will be used for rendering. |
c | The scene collector that should receive objects inside the frustum that are visible. |
Implements Scene.
void CGameView::FollowEntity | ( | entity_id_t | entity, |
bool | firstPerson | ||
) |
CCamera * CGameView::GetCamera | ( | ) |
CVector3D CGameView::GetCameraPivot | ( | ) | const |
CVector3D CGameView::GetCameraPosition | ( | ) | const |
CVector3D CGameView::GetCameraRotation | ( | ) | const |
float CGameView::GetCameraZoom | ( | ) | const |
CCinemaManager * CGameView::GetCinema | ( | ) |
entity_id_t CGameView::GetFollowedEntity | ( | ) |
|
overridevirtual |
Return the LOS texture to be used for rendering this scene.
Implements Scene.
|
overridevirtual |
Return the minimap texture to be used for rendering this scene.
Implements Scene.
CObjectManager & CGameView::GetObjectManager | ( | ) |
|
overridevirtual |
Return the territory texture to be used for rendering this scene.
Implements Scene.
InReaction CGameView::HandleEvent | ( | const SDL_Event_ * | ev | ) |
void CGameView::MoveCameraTarget | ( | const CVector3D & | target | ) |
|
private |
void CGameView::Prepare | ( | Renderer::Backend::IDeviceCommandContext * | deviceCommandContext | ) |
void CGameView::RegisterInit | ( | ) |
void CGameView::Render | ( | Renderer::Backend::IDeviceCommandContext * | deviceCommandContext | ) |
void CGameView::RenderOverlays | ( | Renderer::Backend::IDeviceCommandContext * | deviceCommandContext | ) |
void CGameView::ResetCameraTarget | ( | const CVector3D & | target | ) |
void CGameView::SetCamera | ( | const CVector3D & | pos, |
float | rotX, | ||
float | rotY, | ||
float | zoom | ||
) |
void CGameView::SetViewport | ( | const SViewPort & | vp | ) |
|
private |
void CGameView::Update | ( | const float | deltaRealTime | ) |
Updates all the view information (i.e.
rotate camera, scroll, whatever). This will not change any World information - only the presentation.
deltaRealTime | Elapsed real time since the last frame. |
|
private |