Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Mar 15, 2011, 9:47:11 PM (14 years ago)
Author:
landauf
Message:

merged usability branch back to trunk

incomplete summary of the changes in this branch:

  • enhanced keyboard navigation in GUIs
  • implemented new graphics menu and changeable window size at runtime
  • added developer mode
  • HUD shows if game is paused, game pauses if ingame menu is opened
  • removed a few obsolete commands and hid some that are more for internal use
  • numpad works in console and gui
  • faster loading of level info
  • enhanced usage of compositors (Shader class)
  • improved camera handling, configurable FOV and aspect ratio
Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/libraries/core/GraphicsManager.h

    r7401 r8079  
    5454#include "OrxonoxClass.h"
    5555
     56// tolua_begin
    5657namespace orxonox
    5758{
     
    6061        Graphics engine manager class
    6162    */
    62     class _CoreExport GraphicsManager : public Singleton<GraphicsManager>, public OrxonoxClass, public Ogre::LogListener
    63     {
     63    class _CoreExport GraphicsManager
     64// tolua_end
     65        : public Singleton<GraphicsManager>, public OrxonoxClass, public Ogre::LogListener
     66    { // tolua_export
    6467        friend class Singleton<GraphicsManager>;
    6568    public:
     
    7477        Ogre::RenderWindow* getRenderWindow() { return this->renderWindow_; }
    7578        size_t getRenderWindowHandle();
     79
     80// tolua_begin
     81        static GraphicsManager& getInstance() { return Singleton<GraphicsManager>::getInstance(); } // tolua_export
     82
    7683        bool isFullScreen() const;
     84        unsigned int getWindowWidth() const;
     85        unsigned int getWindowHeight() const;
     86
     87        bool hasVSyncEnabled() const;
     88        std::string getFSAAMode() const;
     89// tolua_end
    7790
    7891        void upgradeToGraphics();
     
    96109        // console commands
    97110        void printScreen();
     111        std::string setScreenResolution(unsigned int width, unsigned int height, bool fullscreen);
     112        std::string setFSAA(const std::string& mode);
     113        std::string setVSync(bool vsync);
    98114
    99115        scoped_ptr<OgreWindowEventListener> ogreWindowEventListener_; //!< Pimpl to hide OgreWindowUtilities.h
     
    105121        Ogre::RenderWindow* renderWindow_;             //!< the one and only render window
    106122        Ogre::Viewport*     viewport_;                 //!< default full size viewport
     123        float               lastFrameStartTime_;       //!< Time stamp of the beginning of the last frame
     124        float               lastFrameEndTime_;         //!< Time stamp of the end of the last frame
    107125
    108126        // XML files for the resources and the debug overlay
     
    121139
    122140        static GraphicsManager* singletonPtr_s;        //!< Pointer to the Singleton
     141// tolua_begin
    123142    };
    124143}
     144// tolua_end
    125145
    126146#endif /* _GraphicsManager_H__ */
Note: See TracChangeset for help on using the changeset viewer.