| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- #pragma once
- #include "CmPrerequisites.h"
- #include "CmHighLevelGpuProgram.h"
- namespace CamelotEngine
- {
- class RenderWindow;
- class Viewport;
- class Camera;
- class HighLevelGpuProgramManager;
- }
- namespace CamelotEngine
- {
- class CM_EXPORT Application
- {
- public:
- Application();
- void startUp(const String& renderSystemDll, const String& rendererDll);
- void runMainLoop();
- void shutDown();
- UINT64 getAppWindowId();
- RenderWindowPtr getPrimaryRenderWindow() const { return mPrimaryRenderWindow; }
- // TODO: This is just for debug purposes. Normally I'd want to have one render context per scene view, not one global one
- DeferredRenderContextPtr getPrimaryRenderContext() const { return mPrimaryRenderContext; }
- /**
- * @brief Loads a plugin.
- *
- * @param pluginName Name of the plugin to load, without extension.
- */
- void loadPlugin(const String& pluginName);
- private:
- RenderWindowPtr mPrimaryRenderWindow;
- DeferredRenderContextPtr mPrimaryRenderContext;
- /**
- * @brief Callback called from the render thread in order to initialize resources.
- */
- void updateResourcesCallback();
- /**
- * @brief Runs the OS specific message pump.
- */
- void updateMessagePump();
- };
- CM_EXPORT Application& gApplication();
- }
|