\section{lib/neatogen/neatosplines.c File Reference}
\label{neatosplines_8c}\index{lib/neatogen/neatosplines.\-c@{lib/neatogen/neatosplines.\-c}}
{\ttfamily \#include \char`\"{}config.\-h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}neato.\-h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}adjust.\-h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}pathplan.\-h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}vispath.\-h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}multispline.\-h\char`\"{}}\\*
Include dependency graph for neatosplines.\-c\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{neatosplines_8c__incl}
\end{center}
\end{figure}
\subsection*{Data Structures}
\begin{DoxyCompactItemize}
\item 
struct {\bf edgeinfo}
\item 
struct {\bf edgeitem}
\end{DoxyCompactItemize}
\subsection*{Macros}
\begin{DoxyCompactItemize}
\item 
\#define {\bf B\-O\-U\-N\-D\-A\-R\-Y\-\_\-\-P\-O\-R\-T}(e)~(({\bf E\-D\-\_\-tail\-\_\-port}(e).side)$|$$|$({\bf E\-D\-\_\-head\-\_\-port}(e).side))
\end{DoxyCompactItemize}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
double {\bf drand48} (void)
\item 
void {\bf printvis} ({\bf vconfig\-\_\-t} $\ast$cp)
\item 
{\bf int} {\bf in\-\_\-poly} ({\bf Ppoly\-\_\-t} argpoly, {\bf Ppoint\-\_\-t} q)
\item 
void {\bf make\-Self\-Arcs} ({\bf path} $\ast$P, {\bf edge\-\_\-t} $\ast$e, {\bf int} stepx)
\item 
{\bf Ppoly\-\_\-t} $\ast$ {\bf make\-Obstacle} ({\bf node\-\_\-t} $\ast$n, {\bf expand\-\_\-t} $\ast$pmargin, {\bf boolean} is\-Ortho)
\item 
{\bf Ppolyline\-\_\-t} {\bf get\-Path} ({\bf edge\-\_\-t} $\ast$e, {\bf vconfig\-\_\-t} $\ast$vconfig, {\bf int} chk\-Pts, {\bf Ppoly\-\_\-t} $\ast$$\ast$obs, {\bf int} npoly)
\item 
void {\bf make\-Spline} ({\bf graph\-\_\-t} $\ast$g, {\bf edge\-\_\-t} $\ast$e, {\bf Ppoly\-\_\-t} $\ast$$\ast$obs, {\bf int} npoly, {\bf boolean} chk\-Pts)
\item 
{\bf int} {\bf spline\-Edges} ({\bf graph\-\_\-t} $\ast$g, {\bf int}($\ast$edgefn)({\bf graph\-\_\-t} $\ast$, {\bf expand\-\_\-t} $\ast$, {\bf int}), {\bf int} edgetype)
\item 
{\bf int} {\bf spline\-\_\-edges1} ({\bf graph\-\_\-t} $\ast$g, {\bf int} edgetype)
\item 
void {\bf spline\-\_\-edges0} ({\bf graph\-\_\-t} $\ast$g, {\bf boolean} set\-\_\-aspect)
\item 
void {\bf spline\-\_\-edges} ({\bf graph\-\_\-t} $\ast$g)
\item 
void {\bf neato\-\_\-translate} ({\bf Agraph\-\_\-t} $\ast$g)
\item 
{\bf boolean} {\bf neato\-\_\-set\-\_\-aspect} ({\bf graph\-\_\-t} $\ast$g)
\end{DoxyCompactItemize}
\subsection*{Variables}
\begin{DoxyCompactItemize}
\item 
{\bf Dtdisc\-\_\-t} {\bf edge\-Item\-Disc}
\end{DoxyCompactItemize}


\subsection{Macro Definition Documentation}
\index{neatosplines.\-c@{neatosplines.\-c}!B\-O\-U\-N\-D\-A\-R\-Y\-\_\-\-P\-O\-R\-T@{B\-O\-U\-N\-D\-A\-R\-Y\-\_\-\-P\-O\-R\-T}}
\index{B\-O\-U\-N\-D\-A\-R\-Y\-\_\-\-P\-O\-R\-T@{B\-O\-U\-N\-D\-A\-R\-Y\-\_\-\-P\-O\-R\-T}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{B\-O\-U\-N\-D\-A\-R\-Y\-\_\-\-P\-O\-R\-T}]{\setlength{\rightskip}{0pt plus 5cm}\#define B\-O\-U\-N\-D\-A\-R\-Y\-\_\-\-P\-O\-R\-T(
\begin{DoxyParamCaption}
\item[{}]{e}
\end{DoxyParamCaption}
)~(({\bf E\-D\-\_\-tail\-\_\-port}(e).side)$|$$|$({\bf E\-D\-\_\-head\-\_\-port}(e).side))}\label{neatosplines_8c_afc5cee46efdb42117380b562d346e743}


Definition at line 536 of file neatosplines.\-c.



\subsection{Function Documentation}
\index{neatosplines.\-c@{neatosplines.\-c}!drand48@{drand48}}
\index{drand48@{drand48}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{drand48}]{\setlength{\rightskip}{0pt plus 5cm}double drand48 (
\begin{DoxyParamCaption}
\item[{void}]{}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_af9329f9acef07ca14ea2256191c3ce74}


Definition at line 2005 of file utils.\-c.

\index{neatosplines.\-c@{neatosplines.\-c}!get\-Path@{get\-Path}}
\index{get\-Path@{get\-Path}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{get\-Path}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Ppolyline\-\_\-t} get\-Path (
\begin{DoxyParamCaption}
\item[{{\bf edge\-\_\-t} $\ast$}]{e, }
\item[{{\bf vconfig\-\_\-t} $\ast$}]{vconfig, }
\item[{{\bf int}}]{chk\-Pts, }
\item[{{\bf Ppoly\-\_\-t} $\ast$$\ast$}]{obs, }
\item[{{\bf int}}]{npoly}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_ab29c0ae28b6683af38b1295b1b94082e}


Definition at line 442 of file neatosplines.\-c.



References aghead(), agtail(), E\-D\-\_\-head\-\_\-port, E\-D\-\_\-tail\-\_\-port, N\-D\-\_\-coord, N\-D\-\_\-lim, Pobspath(), and P\-O\-L\-Y\-I\-D\-\_\-\-N\-O\-N\-E.



Referenced by compound\-Edges().

\index{neatosplines.\-c@{neatosplines.\-c}!in\-\_\-poly@{in\-\_\-poly}}
\index{in\-\_\-poly@{in\-\_\-poly}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{in\-\_\-poly}]{\setlength{\rightskip}{0pt plus 5cm}{\bf int} in\-\_\-poly (
\begin{DoxyParamCaption}
\item[{{\bf Ppoly\-\_\-t}}]{argpoly, }
\item[{{\bf Ppoint\-\_\-t}}]{q}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_a48e4df7e77dcb49432b1877353129511}


Definition at line 29 of file inpoly.\-c.



Referenced by make\-Spline().

\index{neatosplines.\-c@{neatosplines.\-c}!make\-Obstacle@{make\-Obstacle}}
\index{make\-Obstacle@{make\-Obstacle}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{make\-Obstacle}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Ppoly\-\_\-t}$\ast$ make\-Obstacle (
\begin{DoxyParamCaption}
\item[{{\bf node\-\_\-t} $\ast$}]{n, }
\item[{{\bf expand\-\_\-t} $\ast$}]{pmargin, }
\item[{{\bf boolean}}]{is\-Ortho}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_a655d2e9022612f3f255fb2e857df0728}


Definition at line 267 of file neatosplines.\-c.



References field\-\_\-t\-::b, expand\-\_\-t\-::do\-Add, drand48(), F\-I\-X\-E\-D\-S\-H\-A\-P\-E, L\-E\-N, boxf\-::\-L\-L, M\-\_\-\-P\-I, N\-\_\-\-N\-E\-W, N\-D\-\_\-coord, N\-D\-\_\-ht, N\-D\-\_\-lw, N\-D\-\_\-rw, N\-D\-\_\-shape\-\_\-info, N\-E\-W, N\-U\-L\-L, polygon\-\_\-t\-::option, Ppoly\-\_\-t\-::pn, poly\-B\-B(), Ppoly\-\_\-t\-::ps, S\-H\-\_\-\-E\-P\-S\-F, S\-H\-\_\-\-P\-O\-I\-N\-T, S\-H\-\_\-\-P\-O\-L\-Y, S\-H\-\_\-\-R\-E\-C\-O\-R\-D, shape\-Of(), polygon\-\_\-t\-::sides, boxf\-::\-U\-R, polygon\-\_\-t\-::vertices, Pxy\-\_\-t\-::x, pointf\-\_\-s\-::x, expand\-\_\-t\-::x, Pxy\-\_\-t\-::y, pointf\-\_\-s\-::y, and expand\-\_\-t\-::y.

\index{neatosplines.\-c@{neatosplines.\-c}!make\-Self\-Arcs@{make\-Self\-Arcs}}
\index{make\-Self\-Arcs@{make\-Self\-Arcs}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{make\-Self\-Arcs}]{\setlength{\rightskip}{0pt plus 5cm}void make\-Self\-Arcs (
\begin{DoxyParamCaption}
\item[{{\bf path} $\ast$}]{P, }
\item[{{\bf edge\-\_\-t} $\ast$}]{e, }
\item[{{\bf int}}]{stepx}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_ac409fea3d0650f17ec4d5902a37c1334}


Definition at line 226 of file neatosplines.\-c.



References agraphof(), agtail(), Concentrate, E\-D\-\_\-count, E\-D\-\_\-label, E\-D\-\_\-to\-\_\-virt, make\-Port\-Labels(), make\-Self\-Edge(), N\-\_\-\-G\-N\-E\-W, and update\-B\-B().



Referenced by compound\-Edges().

\index{neatosplines.\-c@{neatosplines.\-c}!make\-Spline@{make\-Spline}}
\index{make\-Spline@{make\-Spline}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{make\-Spline}]{\setlength{\rightskip}{0pt plus 5cm}void make\-Spline (
\begin{DoxyParamCaption}
\item[{{\bf graph\-\_\-t} $\ast$}]{g, }
\item[{{\bf edge\-\_\-t} $\ast$}]{e, }
\item[{{\bf Ppoly\-\_\-t} $\ast$$\ast$}]{obs, }
\item[{{\bf int}}]{npoly, }
\item[{{\bf boolean}}]{chk\-Pts}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_aa90a21374beb12b76aa5df28e8a33f45}


Definition at line 497 of file neatosplines.\-c.



References add\-Edge\-Labels(), agerr(), A\-G\-E\-R\-R, aghead(), agnameof(), agtail(), clip\-\_\-and\-\_\-install(), E\-D\-\_\-path, in\-\_\-poly(), Ppoly\-\_\-t\-::pn, P\-O\-L\-Y\-I\-D\-\_\-\-N\-O\-N\-E, Proutespline(), Ppoly\-\_\-t\-::ps, Verbose, Pxy\-\_\-t\-::x, and Pxy\-\_\-t\-::y.



Referenced by compound\-Edges().

\index{neatosplines.\-c@{neatosplines.\-c}!neato\-\_\-set\-\_\-aspect@{neato\-\_\-set\-\_\-aspect}}
\index{neato\-\_\-set\-\_\-aspect@{neato\-\_\-set\-\_\-aspect}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{neato\-\_\-set\-\_\-aspect}]{\setlength{\rightskip}{0pt plus 5cm}{\bf boolean} neato\-\_\-set\-\_\-aspect (
\begin{DoxyParamCaption}
\item[{{\bf graph\-\_\-t} $\ast$}]{g}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_a17de809e0abdb057f1745cc469d601e8}


Definition at line 1096 of file neatosplines.\-c.



References agfstnode(), agnxtnode(), F\-A\-L\-S\-E, N\-D\-\_\-coord, N\-D\-\_\-pos, and P\-O\-I\-N\-T\-S\-\_\-\-P\-E\-R\-\_\-\-I\-N\-C\-H.



Referenced by fdp\-\_\-layout(), init\-\_\-nop(), and spline\-\_\-edges0().

\index{neatosplines.\-c@{neatosplines.\-c}!neato\-\_\-translate@{neato\-\_\-translate}}
\index{neato\-\_\-translate@{neato\-\_\-translate}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{neato\-\_\-translate}]{\setlength{\rightskip}{0pt plus 5cm}void neato\-\_\-translate (
\begin{DoxyParamCaption}
\item[{{\bf Agraph\-\_\-t} $\ast$}]{g}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_ae3b2e6fb27d1b16da671fae4d9698f93}


Definition at line 970 of file neatosplines.\-c.



References agfstnode(), agfstout(), agnxtnode(), agnxtout(), E\-D\-\_\-spl, G\-D\-\_\-bb, N\-D\-\_\-pos, N\-D\-\_\-xlabel, P\-S2\-I\-N\-C\-H, pointf\-\_\-s\-::x, and pointf\-\_\-s\-::y.



Referenced by init\-\_\-nop().

\index{neatosplines.\-c@{neatosplines.\-c}!printvis@{printvis}}
\index{printvis@{printvis}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{printvis}]{\setlength{\rightskip}{0pt plus 5cm}void printvis (
\begin{DoxyParamCaption}
\item[{{\bf vconfig\-\_\-t} $\ast$}]{cp}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_afd8758e4dd9d2a8489972ff7dd5a857c}


Definition at line 19 of file printvis.\-c.



References vconfig\-\_\-s\-::\-N, vconfig\-\_\-s\-::next, vconfig\-\_\-s\-::\-P, vconfig\-\_\-s\-::prev, and vconfig\-\_\-s\-::vis.

\index{neatosplines.\-c@{neatosplines.\-c}!spline\-\_\-edges@{spline\-\_\-edges}}
\index{spline\-\_\-edges@{spline\-\_\-edges}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{spline\-\_\-edges}]{\setlength{\rightskip}{0pt plus 5cm}void spline\-\_\-edges (
\begin{DoxyParamCaption}
\item[{{\bf graph\-\_\-t} $\ast$}]{g}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_afb808cca7069bd0d539bfb48b9127c8d}


Definition at line 804 of file neatosplines.\-c.



References agfstnode(), agnxtnode(), compute\-\_\-bb(), G\-D\-\_\-bb, N\-D\-\_\-pos, P\-S2\-I\-N\-C\-H, spline\-\_\-edges0(), T\-R\-U\-E, pointf\-\_\-s\-::x, and pointf\-\_\-s\-::y.



Referenced by circo\-\_\-layout(), neato\-\_\-layout(), sfdp\-\_\-layout(), and twopi\-\_\-layout().

\index{neatosplines.\-c@{neatosplines.\-c}!spline\-\_\-edges0@{spline\-\_\-edges0}}
\index{spline\-\_\-edges0@{spline\-\_\-edges0}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{spline\-\_\-edges0}]{\setlength{\rightskip}{0pt plus 5cm}void spline\-\_\-edges0 (
\begin{DoxyParamCaption}
\item[{{\bf graph\-\_\-t} $\ast$}]{g, }
\item[{{\bf boolean}}]{set\-\_\-aspect}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_a876fb6cb0d6f2ae671df1f96a91856e4}


Definition at line 767 of file neatosplines.\-c.



References agerr(), A\-G\-W\-A\-R\-N, E\-D\-G\-E\-\_\-\-T\-Y\-P\-E, E\-T\-\_\-\-N\-O\-N\-E, E\-T\-\_\-\-O\-R\-T\-H\-O, E\-T\-\_\-\-P\-L\-I\-N\-E, G\-D\-\_\-flags, neato\-\_\-set\-\_\-aspect(), Agraph\-\_\-s\-::root, and spline\-\_\-edges1().



Referenced by init\-\_\-nop(), osage\-\_\-layout(), and spline\-\_\-edges().

\index{neatosplines.\-c@{neatosplines.\-c}!spline\-\_\-edges1@{spline\-\_\-edges1}}
\index{spline\-\_\-edges1@{spline\-\_\-edges1}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{spline\-\_\-edges1}]{\setlength{\rightskip}{0pt plus 5cm}{\bf int} spline\-\_\-edges1 (
\begin{DoxyParamCaption}
\item[{{\bf graph\-\_\-t} $\ast$}]{g, }
\item[{{\bf int}}]{edgetype}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_a5ddaec06b8c29e70c7d8d2c492dab3ff}


Definition at line 748 of file neatosplines.\-c.



References spline\-Edges().



Referenced by osage\-\_\-layout(), and spline\-\_\-edges0().

\index{neatosplines.\-c@{neatosplines.\-c}!spline\-Edges@{spline\-Edges}}
\index{spline\-Edges@{spline\-Edges}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{spline\-Edges}]{\setlength{\rightskip}{0pt plus 5cm}{\bf int} spline\-Edges (
\begin{DoxyParamCaption}
\item[{{\bf graph\-\_\-t} $\ast$}]{g, }
\item[{{\bf int}($\ast$)({\bf graph\-\_\-t} $\ast$, {\bf expand\-\_\-t} $\ast$, {\bf int})}]{edgefn, }
\item[{{\bf int}}]{edgetype}
\end{DoxyParamCaption}
)}\label{neatosplines_8c_ace0c11e8fd1011a1ed53c07c93f39bfe}


Definition at line 700 of file neatosplines.\-c.



References agfstnode(), agfstout(), agnxtnode(), agnxtout(), dtclose(), dtopen(), Dtoset, E\-D\-\_\-count, E\-D\-\_\-spl, E\-D\-\_\-to\-\_\-virt, esep\-Factor(), G\-V\-S\-P\-L\-I\-N\-E\-S, Nop, resolve\-Ports(), and State.



Referenced by spline\-\_\-edges1().



\subsection{Variable Documentation}
\index{neatosplines.\-c@{neatosplines.\-c}!edge\-Item\-Disc@{edge\-Item\-Disc}}
\index{edge\-Item\-Disc@{edge\-Item\-Disc}!neatosplines.c@{neatosplines.\-c}}
\subsubsection[{edge\-Item\-Disc}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Dtdisc\-\_\-t} edge\-Item\-Disc}\label{neatosplines_8c_a6ba3e752de8284ae4a8bfc8460b0f695}
{\bfseries Initial value\-:}
\begin{DoxyCode}
= \{
    offsetof(edgeitem, \textcolor{keywordtype}{id}),
    \textcolor{keyword}{sizeof}(edgeinfo),
    offsetof(edgeitem, link),
    (Dtmake_f) newitem,
    (Dtfree_f) freeitem,
    (Dtcompar_f) cmpitems,
    0,
    0,
    0
\}
\end{DoxyCode}


Definition at line 158 of file neatosplines.\-c.

