Open3D (C++ API)
ViewParameters.h
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - Open3D: www.open3d.org -
3 // ----------------------------------------------------------------------------
4 // The MIT License (MIT)
5 //
6 // Copyright (c) 2018 www.open3d.org
7 //
8 // Permission is hereby granted, free of charge, to any person obtaining a copy
9 // of this software and associated documentation files (the "Software"), to deal
10 // in the Software without restriction, including without limitation the rights
11 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
12 // copies of the Software, and to permit persons to whom the Software is
13 // furnished to do so, subject to the following conditions:
14 //
15 // The above copyright notice and this permission notice shall be included in
16 // all copies or substantial portions of the Software.
17 //
18 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
21 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
23 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
24 // IN THE SOFTWARE.
25 // ----------------------------------------------------------------------------
26 
27 #pragma once
28 
29 #include <Eigen/Core>
30 #include <Eigen/StdVector>
31 
33 
34 namespace open3d {
35 namespace visualization {
36 
38 public:
39  typedef Eigen::Matrix<double, 17, 4, Eigen::RowMajor> Matrix17x4d;
40  typedef Eigen::Matrix<double, 17, 1> Vector17d;
41  typedef Eigen::aligned_allocator<Matrix17x4d> Matrix17x4d_allocator;
42 
43 public:
45  ~ViewParameters() override {}
46 
47 public:
48  Vector17d ConvertToVector17d();
49  void ConvertFromVector17d(const Vector17d &v);
50  bool ConvertToJsonValue(Json::Value &value) const override;
51  bool ConvertFromJsonValue(const Json::Value &value) override;
52 
53 public:
55  double zoom_;
56  Eigen::Vector3d lookat_;
57  Eigen::Vector3d up_;
58  Eigen::Vector3d front_;
59  Eigen::Vector3d boundingbox_min_;
60  Eigen::Vector3d boundingbox_max_;
61 };
62 
63 } // namespace visualization
64 } // namespace open3d
double zoom_
Definition: ViewParameters.h:55
ViewParameters()
Definition: ViewParameters.h:44
~ViewParameters() override
Definition: ViewParameters.h:45
Eigen::Matrix< double, 17, 4, Eigen::RowMajor > Matrix17x4d
Definition: ViewParameters.h:39
Vector17d ConvertToVector17d()
Definition: ViewParameters.cpp:37
bool ConvertToJsonValue(Json::Value &value) const override
Definition: ViewParameters.cpp:59
void ConvertFromVector17d(const Vector17d &v)
Definition: ViewParameters.cpp:49
Eigen::aligned_allocator< Matrix17x4d > Matrix17x4d_allocator
Definition: ViewParameters.h:41
Eigen::Vector3d boundingbox_min_
Definition: ViewParameters.h:59
bool ConvertFromJsonValue(const Json::Value &value) override
Definition: ViewParameters.cpp:82
Eigen::Vector3d up_
Definition: ViewParameters.h:57
Eigen::Matrix< double, 17, 1 > Vector17d
Definition: ViewParameters.h:40
Eigen::Vector3d boundingbox_max_
Definition: ViewParameters.h:60
Definition: PinholeCameraIntrinsic.cpp:34
Eigen::Vector3d lookat_
Definition: ViewParameters.h:56
Definition: ViewParameters.h:37
Eigen::Vector3d front_
Definition: ViewParameters.h:58
double field_of_view_
Definition: ViewParameters.h:54
Definition: IJsonConvertible.h:42