/*] Copyright (c) 2009-2010, Charles McGarvey [************************** **] All rights reserved. * * vi:ts=4 sw=4 tw=75 * * Distributable under the terms and conditions of the 2-clause BSD license; * see the file COPYING for a complete text of the license. * **************************************************************************/ #ifndef _MAIN_HH_ #define _MAIN_HH_ /** * @file Main.hh * This is where all the fun begins. */ #include #include #include #include #include #include namespace Mf { class Settings; class View; } class Main; typedef boost::shared_ptr
MainP; class Main : public Mf::View { public: Main(Mf::Settings& settings, Mf::Video& video); void update(Mf::Scalar t, Mf::Scalar dt); void draw(Mf::Scalar alpha) const; bool handleEvent(const Mf::Event& event); static std::string getSearchPath(); static std::string getConfigPath(); static void printUsage(); static void printInfo(int argc, char* argv[]); private: /** * Set OpenGL to a state we can know and depend on. */ static void setupGL(); Mf::Dispatch::Handle mNewContextDispatch; }; #endif // _MAIN_HH_