Mercurial > hg > orthanc-stone
diff Samples/Sdl/TrackerSampleApp.h @ 698:8b6adfb62a2f refactor-viewport-controller
Code is broken -- stashing ongoing work in a branch
author | Benjamin Golinvaux <bgo@osimis.io> |
---|---|
date | Wed, 15 May 2019 16:56:17 +0200 |
parents | cb3b76d16234 |
children | 059e1fd05fd6 |
line wrap: on
line diff
--- a/Samples/Sdl/TrackerSampleApp.h Tue May 14 19:38:51 2019 +0200 +++ b/Samples/Sdl/TrackerSampleApp.h Wed May 15 16:56:17 2019 +0200 @@ -18,11 +18,15 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. **/ -#include <Framework/Scene2D/OpenGLCompositor.h> +#include <Framework/Scene2DViewport/PointerTypes.h> + #include <Framework/Messages/IObserver.h> -#include "../Common/IFlexiblePointerTracker.h" -#include "../Common/MeasureTools.h" +#include <Framework/Scene2D/OpenGLCompositor.h> + +#include <Framework/Scene2DViewport/ViewportController.h> +#include <Framework/Scene2DViewport/IFlexiblePointerTracker.h> +#include <Framework/Scene2DViewport/MeasureTools.h> #include <SDL.h> @@ -32,9 +36,6 @@ namespace OrthancStone { - class TrackerCommand; - typedef boost::shared_ptr<TrackerCommand> TrackerCommandPtr; - enum GuiTool { GuiTool_Rotate = 0, @@ -65,7 +66,7 @@ void SetInfoDisplayMessage(std::string key, std::string value); void DisableTracker(); - Scene2D& GetScene(); + Scene2DPtr GetScene(); void HandleApplicationEvent(const SDL_Event& event); @@ -108,7 +109,7 @@ WARNING: the measuring tools do store a reference to the scene, and it paramount that the scene gets destroyed AFTER the measurement tools. */ - Scene2D scene_; + ViewportControllerPtr controller_; std::map<std::string, std::string> infoTextMap_; FlexiblePointerTrackerPtr activeTracker_;