diff options
author | Mitchell Stokes <mogurijin@gmail.com> | 2012-10-08 07:28:11 +0400 |
---|---|---|
committer | Mitchell Stokes <mogurijin@gmail.com> | 2012-10-08 07:28:11 +0400 |
commit | 244ce92dbd1f32960e0f909933d99cd0e6027dcc (patch) | |
tree | ee71a9619fb257d9d7deffce53051fa1a6214cdf /source/gameengine/GamePlayer/common/GPC_Canvas.h | |
parent | aa1e50be946dfeb17f9bb98b242bdbf6775f1ab6 (diff) |
BGE: Setting up the RAS_ICanvas interface as the primary way to alter the OpenGL
viewport. This helps to eliminate OpenGL calls in weird places like the physics
code and to reduce glGet calls, which are expensive.
There should be no functional changes (except maybe a very slight speed improvement).
Diffstat (limited to 'source/gameengine/GamePlayer/common/GPC_Canvas.h')
-rw-r--r-- | source/gameengine/GamePlayer/common/GPC_Canvas.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/gameengine/GamePlayer/common/GPC_Canvas.h b/source/gameengine/GamePlayer/common/GPC_Canvas.h index 453b9505183..2a597c4c43d 100644 --- a/source/gameengine/GamePlayer/common/GPC_Canvas.h +++ b/source/gameengine/GamePlayer/common/GPC_Canvas.h @@ -90,6 +90,8 @@ protected: * relative to the context */ RAS_Rect m_displayarea; + int *m_viewport; + /** Storage for the banners to display. */ TBannerMap m_banners; /** State of banner display. */ @@ -153,6 +155,7 @@ public: ); void SetViewPort(int x1, int y1, int x2, int y2); + const int *GetViewPort(); void ClearColor(float r, float g, float b, float a); |