Cumulia Illustrator Rendering Engine v1.0.0
A Rendering engine for industrial CAD/CAE model and optimized for greatest performance
 
Loading...
Searching...
No Matches
navigation.h
1//##################################################################################################
2//
3// Copyright (c) 2024 Beijing Qiongqi Tech Co.,Ltd. All rights reserved.
4
5// This source code is confidential and proprietary to Beijing Qiongqi Tech Co.,Ltd(The Holder).
6// Any unauthorized use, copying, modification, or distribution of the code is strictly prohibited.
7// Any user shall obtain authorizaition from the Holder before modifying the source code. And the user shall not
8// sublicense, sell, distribute, or transfer the source code, whether in original or modified form, to any third party
9// without the prior written consent of the Holder.
10
11// This copyright notice and permission grant shall be included in all copies or substantial portions of the source code.
12
13// Author Cumulia Illustrator
14// Date 2024-05-01
15// Version V1.0.0
16//##################################################################################################
17
18#pragma once
19
20#include "manipulator.h"
21
22#include <map>
23#include <string>
24
25namespace cil
26{
28 {
29 public:
30 static std::map<int, std::string> actions;
31 std::function<void()> onUpdate;
32
33 private:
34 std::shared_ptr<Camera> m_camera;
35 std::shared_ptr<Vector2i> m_windowSize;
36 std::shared_ptr<BoundingBox> m_boundingBox;
37
38 public:
39 NavigationManipulator(std::shared_ptr<Camera>& camera, const std::shared_ptr<Vector2i>& windowSize, const std::shared_ptr<BoundingBox>& boundingBox = nullptr);
40
41 virtual void mouseMove(const ivec2& position, Button button, Modifier modifier);
42 virtual void mouseWheel(const ivec2& position, Modifier modifier, bool up);
43 };
44
45 std::shared_ptr<NavigationManipulator> _manipulator_navigation(std::shared_ptr<Camera>& camera, const std::shared_ptr<Vector2i>& windowSize, const std::shared_ptr<BoundingBox>& boundingBox = nullptr);
46}
Definition manipulator.h:38
Button
Definition manipulator.h:51
Modifier
Definition manipulator.h:60
Definition navigation.h:28
static std::map< int, std::string > actions
Definition navigation.h:30
virtual void mouseWheel(const ivec2 &position, Modifier modifier, bool up)
std::function< void()> onUpdate
Definition navigation.h:31
virtual void mouseMove(const ivec2 &position, Button button, Modifier modifier)
NavigationManipulator(std::shared_ptr< Camera > &camera, const std::shared_ptr< Vector2i > &windowSize, const std::shared_ptr< BoundingBox > &boundingBox=nullptr)
The class Vector2i inherits from the templated class of Vector2, and the template parameters are spec...
Definition vector.h:255
Definition decal.h:23
std::shared_ptr< NavigationManipulator > _manipulator_navigation(std::shared_ptr< Camera > &camera, const std::shared_ptr< Vector2i > &windowSize, const std::shared_ptr< BoundingBox > &boundingBox=nullptr)