GraphvizFormatting.h
Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
2 
3  * GTSAM Copyright 2010-2021, Georgia Tech Research Corporation,
4  * Atlanta, Georgia 30332-0415
5  * All Rights Reserved
6  * Authors: Frank Dellaert, et al. (see THANKS for the full author list)
7 
8  * See LICENSE for the license information
9 
10  * -------------------------------------------------------------------------- */
11 
19 #pragma once
20 
22 
23 namespace gtsam {
24 
25 class Values;
26 class Value;
27 
32 struct GTSAM_EXPORT GraphvizFormatting : public DotWriter {
34  enum Axis { X, Y, Z, NEGX, NEGY, NEGZ };
35 
37  Axis paperVerticalAxis;
39  double scale;
42 
47  : paperHorizontalAxis(Y),
48  paperVerticalAxis(X),
49  scale(1),
50  mergeSimilarFactors(false) {}
51 
52  // Find bounds
53  Vector2 findBounds(const Values& values, const KeySet& keys) const;
54 
56  std::optional<Vector2> extractPosition(const Value& value) const;
57 
59  std::optional<Vector2> variablePos(const Values& values, const Vector2& min,
60  Key key) const;
61 
63  std::optional<Vector2> factorPos(const Vector2& min, size_t i) const;
64 };
65 
66 } // namespace gtsam
const gtsam::Symbol key('X', 0)
const char Y
Graphviz formatter.
#define min(a, b)
Definition: datatypes.h:19
leaf::MyValues values
Axis
World axes to be assigned to paper axes.
DotWriter is a helper class for writing graphviz .dot files.
Definition: DotWriter.h:36
traits
Definition: chartTesting.h:28
static double scale(double x, double a, double b, double t1, double t2)
Scale x from [a, b] to [t1, t2].
Definition: Chebyshev.cpp:35
const KeyVector keys
#define X
Definition: icosphere.cpp:20
std::uint64_t Key
Integer nonlinear key type.
Definition: types.h:102


gtsam
Author(s):
autogenerated on Tue Jul 4 2023 02:34:19