Loading...
Searching...
No Matches
GraphvizFormatting.h
Go to the documentation of this file.
/* ----------------------------------------------------------------------------
* GTSAM Copyright 2010-2021, Georgia Tech Research Corporation,
* Atlanta, Georgia 30332-0415
* All Rights Reserved
* Authors: Frank Dellaert, et al. (see THANKS for the full author list)
* See LICENSE for the license information
* -------------------------------------------------------------------------- */
#pragma once
#include <gtsam/inference/DotWriter.h>
namespace gtsam {
class Values;
class Value;
struct GTSAM_EXPORT GraphvizFormatting : public DotWriter {
enum Axis { X, Y, Z, NEGX, NEGY, NEGZ };
Axis paperHorizontalAxis;
Axis paperVerticalAxis;
double scale;
bool mergeSimilarFactors;
GraphvizFormatting()
: paperHorizontalAxis(Y),
paperVerticalAxis(X),
scale(1),
mergeSimilarFactors(false) {}
// Find bounds
Vector2 findBounds(const Values& values, const KeySet& keys) const;
boost::optional<Vector2> extractPosition(const Value& value) const;
boost::optional<Vector2> variablePos(const Values& values, const Vector2& min,
Key key) const;
boost::optional<Vector2> factorPos(const Vector2& min, size_t i) const;
};
} // namespace gtsam
DotWriter.h
Graphviz formatter.
gtsam
Global functions in a separate testing namespace.
Definition chartTesting.h:28
gtsam::Key
std::uint64_t Key
Integer nonlinear key type.
Definition types.h:100
gtsam::Value
This is the base class for any type to be stored in Values.
Definition Value.h:37
gtsam::GraphvizFormatting::Axis
Axis
World axes to be assigned to paper axes.
Definition GraphvizFormatting.h:34
gtsam::GraphvizFormatting::paperVerticalAxis
Axis paperVerticalAxis
The world axis assigned to the vertical paper axis.
Definition GraphvizFormatting.h:38
gtsam::GraphvizFormatting::GraphvizFormatting
GraphvizFormatting()
Default constructor sets up robot coordinates.
Definition GraphvizFormatting.h:46
gtsam::GraphvizFormatting::mergeSimilarFactors
bool mergeSimilarFactors
Merge multiple factors that have the same connectivity.
Definition GraphvizFormatting.h:41
gtsam::GraphvizFormatting::scale
double scale
Scale all positions to reduce / increase density.
Definition GraphvizFormatting.h:40
gtsam::GraphvizFormatting::paperHorizontalAxis
Axis paperHorizontalAxis
The world axis assigned to the horizontal paper axis.
Definition GraphvizFormatting.h:36
gtsam::Values
A non-templated config holding any types of Manifold-group elements.
Definition Values.h:65