\hypertarget{a08932}{}\section{Open\+Mesh\+:\+:Decimater\+:\+:DecimaterT$<$ MeshT $>$ Class Template Reference}
\label{a08932}\index{Open\+Mesh\+::\+Decimater\+::\+Decimater\+T$<$ Mesh\+T $>$@{Open\+Mesh\+::\+Decimater\+::\+Decimater\+T$<$ Mesh\+T $>$}}


{\ttfamily \#include $<$Open\+Flipper/libs\+\_\+required/\+Open\+Mesh/src/\+Open\+Mesh/\+Tools/\+Decimater/\+Decimater\+T.\+hh$>$}

Inheritance diagram for Open\+Mesh\+:\+:Decimater\+:\+:DecimaterT$<$ MeshT $>$\+:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=4.000000cm]{a08932}
\end{center}
\end{figure}
\subsection*{Classes}
\begin{DoxyCompactItemize}
\item 
class \hyperlink{a08936}{Heap\+Interface}
\begin{DoxyCompactList}\small\item\em Heap interface. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Public Types}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{a08932_a56387852bafbda2cd245b08ea2d0008e}\label{a08932_a56387852bafbda2cd245b08ea2d0008e}} 
typedef \hyperlink{a08932}{DecimaterT}$<$ MeshT $>$ {\bfseries Self}
\item 
\mbox{\Hypertarget{a08932_a3c5207a20bd2e5adfd2bb35f82719694}\label{a08932_a3c5207a20bd2e5adfd2bb35f82719694}} 
typedef MeshT {\bfseries Mesh}
\item 
\mbox{\Hypertarget{a08932_ac4bc78e9bb2a26693eda5ad817dd8308}\label{a08932_ac4bc78e9bb2a26693eda5ad817dd8308}} 
typedef \hyperlink{a08928}{Collapse\+InfoT}$<$ MeshT $>$ {\bfseries Collapse\+Info}
\item 
\mbox{\Hypertarget{a08932_a2c16ba0c94ecaa849bfdfa31148ac5ff}\label{a08932_a2c16ba0c94ecaa849bfdfa31148ac5ff}} 
typedef \hyperlink{a08956}{Mod\+BaseT}$<$ MeshT $>$ {\bfseries Module}
\item 
\mbox{\Hypertarget{a08932_a0846b1d3f4ac5dc6a1aa32a9e7efc7b6}\label{a08932_a0846b1d3f4ac5dc6a1aa32a9e7efc7b6}} 
typedef std\+::vector$<$ \hyperlink{a08956}{Module} $\ast$$>$ {\bfseries Module\+List}
\item 
\mbox{\Hypertarget{a08932_a7d925514a38016c7bd90b4047655f0cc}\label{a08932_a7d925514a38016c7bd90b4047655f0cc}} 
typedef Module\+List\+::iterator {\bfseries Module\+List\+Iterator}
\item 
\mbox{\Hypertarget{a08932_a45a4df1d970e4d3ed619029ea80fe30f}\label{a08932_a45a4df1d970e4d3ed619029ea80fe30f}} 
typedef \hyperlink{a08776_a0fc18e13d70825938274e3faf7b55e01}{Mesh\+::\+Vertex\+Handle} {\bfseries Vertex\+Handle}
\item 
\mbox{\Hypertarget{a08932_a6214e337d0b42e74ef2f8ec93b67319d}\label{a08932_a6214e337d0b42e74ef2f8ec93b67319d}} 
typedef Mesh\+::\+Halfedge\+Handle {\bfseries Halfedge\+Handle}
\item 
\mbox{\Hypertarget{a08932_a22d1340e2ee838d396a6aba82135e4c9}\label{a08932_a22d1340e2ee838d396a6aba82135e4c9}} 
typedef \hyperlink{a09264}{Utils\+::\+HeapT}$<$ Vertex\+Handle, \hyperlink{a08936}{Heap\+Interface} $>$ {\bfseries Deci\+Heap}
\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{a08932_acf185e9dd3958b8634d26ff322f80685}\label{a08932_acf185e9dd3958b8634d26ff322f80685}} 
\hyperlink{a08932_acf185e9dd3958b8634d26ff322f80685}{DecimaterT} (Mesh \&\+\_\+mesh)
\begin{DoxyCompactList}\small\item\em Constructor. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{a08932_a6d1b1b6855f42b5501860ae79cf6be64}\label{a08932_a6d1b1b6855f42b5501860ae79cf6be64}} 
\hyperlink{a08932_a6d1b1b6855f42b5501860ae79cf6be64}{$\sim$\+DecimaterT} ()
\begin{DoxyCompactList}\small\item\em Destructor. \end{DoxyCompactList}\item 
size\+\_\+t \hyperlink{a08932_ae68360f349a3aeb6b8a01a7ea4af7ea3}{decimate} (size\+\_\+t \+\_\+n\+\_\+collapses=0)
\begin{DoxyCompactList}\small\item\em Perform a number of collapses on the mesh. \end{DoxyCompactList}\item 
size\+\_\+t \hyperlink{a08932_a314edcd690ba54b6b77dde411e04262a}{decimate\+\_\+to} (size\+\_\+t \+\_\+n\+\_\+vertices)
\begin{DoxyCompactList}\small\item\em Decimate the mesh to a desired target vertex complexity. \end{DoxyCompactList}\item 
size\+\_\+t \hyperlink{a08932_a3f9e5d0abce8d73b67cf2bbf17700241}{decimate\+\_\+to\+\_\+faces} (size\+\_\+t \+\_\+n\+\_\+vertices=0, size\+\_\+t \+\_\+n\+\_\+faces=0)
\begin{DoxyCompactList}\small\item\em Attempts to decimate the mesh until a desired vertex or face complexity is achieved. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Member Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{a08932_acd2b69b6a3b88dbf0101fbfeae159d56}\label{a08932_acd2b69b6a3b88dbf0101fbfeae159d56}} 
void \hyperlink{a08932_acd2b69b6a3b88dbf0101fbfeae159d56}{heap\+\_\+vertex} (Vertex\+Handle \+\_\+vh)
\begin{DoxyCompactList}\small\item\em Insert vertex in heap. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{a08932_aaab160b1cbac28224c0dabad3e9e4a86}\label{a08932_aaab160b1cbac28224c0dabad3e9e4a86}} 
Mesh \& {\bfseries mesh\+\_\+}
\item 
\mbox{\Hypertarget{a08932_abf2ae2393079252a91fb92e97c000d8e}\label{a08932_abf2ae2393079252a91fb92e97c000d8e}} 
std\+::auto\+\_\+ptr$<$ \hyperlink{a09264}{Deci\+Heap} $>$ {\bfseries heap\+\_\+}
\item 
\mbox{\Hypertarget{a08932_afc4ac5d19eee29486d978bedabb7aa90}\label{a08932_afc4ac5d19eee29486d978bedabb7aa90}} 
\hyperlink{a08876}{V\+Prop\+HandleT}$<$ Halfedge\+Handle $>$ {\bfseries collapse\+\_\+target\+\_\+}
\item 
\mbox{\Hypertarget{a08932_adba6cfc18a298bf79d2beec75baab5f8}\label{a08932_adba6cfc18a298bf79d2beec75baab5f8}} 
\hyperlink{a08876}{V\+Prop\+HandleT}$<$ float $>$ {\bfseries priority\+\_\+}
\item 
\mbox{\Hypertarget{a08932_a9a42a852c0916e848b596b5a84f30992}\label{a08932_a9a42a852c0916e848b596b5a84f30992}} 
\hyperlink{a08876}{V\+Prop\+HandleT}$<$ int $>$ {\bfseries heap\+\_\+position\+\_\+}
\end{DoxyCompactItemize}
\subsection*{Additional Inherited Members}


\subsection{Detailed Description}
\subsubsection*{template$<$typename MeshT$>$\newline
class Open\+Mesh\+::\+Decimater\+::\+Decimater\+T$<$ Mesh\+T $>$}

\hyperlink{a06217}{Decimater} framework. \begin{DoxySeeAlso}{See also}
Base\+ModT, \hyperlink{decimater_docu}{Mesh Decimation Framework} 
\end{DoxySeeAlso}


Definition at line 78 of file Decimater\+T.\+hh.



\subsection{Member Function Documentation}
\mbox{\Hypertarget{a08932_ae68360f349a3aeb6b8a01a7ea4af7ea3}\label{a08932_ae68360f349a3aeb6b8a01a7ea4af7ea3}} 
\index{Open\+Mesh\+::\+Decimater\+::\+DecimaterT@{Open\+Mesh\+::\+Decimater\+::\+DecimaterT}!decimate@{decimate}}
\index{decimate@{decimate}!Open\+Mesh\+::\+Decimater\+::\+DecimaterT@{Open\+Mesh\+::\+Decimater\+::\+DecimaterT}}
\subsubsection{\texorpdfstring{decimate()}{decimate()}}
{\footnotesize\ttfamily template$<$class Mesh $>$ \\
size\+\_\+t \hyperlink{a08932}{Open\+Mesh\+::\+Decimater\+::\+DecimaterT}$<$ Mesh $>$\+::decimate (\begin{DoxyParamCaption}\item[{size\+\_\+t}]{\+\_\+n\+\_\+collapses = {\ttfamily 0} }\end{DoxyParamCaption})}



Perform a number of collapses on the mesh. 


\begin{DoxyParams}{Parameters}
{\em \+\_\+n\+\_\+collapses} & Desired number of collapses. If zero (default), attempt to do as many collapses as possible. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
Number of collapses that were actually performed. 
\end{DoxyReturn}
\begin{DoxyNote}{Note}
This operation only marks the removed mesh elements for deletion. In order to actually remove the decimated elements from the mesh, a subsequent call to \hyperlink{a08576_aba7fd4df59227f974b44111ac45e835f}{Array\+Kernel\+::garbage\+\_\+collection()} is required. 
\end{DoxyNote}


Definition at line 150 of file Decimater\+T\+\_\+impl.\+hh.

\mbox{\Hypertarget{a08932_a314edcd690ba54b6b77dde411e04262a}\label{a08932_a314edcd690ba54b6b77dde411e04262a}} 
\index{Open\+Mesh\+::\+Decimater\+::\+DecimaterT@{Open\+Mesh\+::\+Decimater\+::\+DecimaterT}!decimate\+\_\+to@{decimate\+\_\+to}}
\index{decimate\+\_\+to@{decimate\+\_\+to}!Open\+Mesh\+::\+Decimater\+::\+DecimaterT@{Open\+Mesh\+::\+Decimater\+::\+DecimaterT}}
\subsubsection{\texorpdfstring{decimate\+\_\+to()}{decimate\_to()}}
{\footnotesize\ttfamily template$<$typename MeshT $>$ \\
size\+\_\+t \hyperlink{a08932}{Open\+Mesh\+::\+Decimater\+::\+DecimaterT}$<$ MeshT $>$\+::decimate\+\_\+to (\begin{DoxyParamCaption}\item[{size\+\_\+t}]{\+\_\+n\+\_\+vertices }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}



Decimate the mesh to a desired target vertex complexity. 


\begin{DoxyParams}{Parameters}
{\em \+\_\+n\+\_\+vertices} & Target complexity, i.\+e. desired number of remaining vertices after decimation. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
Number of collapses that were actually performed. 
\end{DoxyReturn}
\begin{DoxyNote}{Note}
This operation only marks the removed mesh elements for deletion. In order to actually remove the decimated elements from the mesh, a subsequent call to \hyperlink{a08576_aba7fd4df59227f974b44111ac45e835f}{Array\+Kernel\+::garbage\+\_\+collection()} is required. 
\end{DoxyNote}


Definition at line 119 of file Decimater\+T.\+hh.

\mbox{\Hypertarget{a08932_a3f9e5d0abce8d73b67cf2bbf17700241}\label{a08932_a3f9e5d0abce8d73b67cf2bbf17700241}} 
\index{Open\+Mesh\+::\+Decimater\+::\+DecimaterT@{Open\+Mesh\+::\+Decimater\+::\+DecimaterT}!decimate\+\_\+to\+\_\+faces@{decimate\+\_\+to\+\_\+faces}}
\index{decimate\+\_\+to\+\_\+faces@{decimate\+\_\+to\+\_\+faces}!Open\+Mesh\+::\+Decimater\+::\+DecimaterT@{Open\+Mesh\+::\+Decimater\+::\+DecimaterT}}
\subsubsection{\texorpdfstring{decimate\+\_\+to\+\_\+faces()}{decimate\_to\_faces()}}
{\footnotesize\ttfamily template$<$class Mesh $>$ \\
size\+\_\+t \hyperlink{a08932}{Open\+Mesh\+::\+Decimater\+::\+DecimaterT}$<$ Mesh $>$\+::decimate\+\_\+to\+\_\+faces (\begin{DoxyParamCaption}\item[{size\+\_\+t}]{\+\_\+n\+\_\+vertices = {\ttfamily 0},  }\item[{size\+\_\+t}]{\+\_\+n\+\_\+faces = {\ttfamily 0} }\end{DoxyParamCaption})}



Attempts to decimate the mesh until a desired vertex or face complexity is achieved. 


\begin{DoxyParams}{Parameters}
{\em \+\_\+n\+\_\+vertices} & Target vertex complexity. \\
\hline
{\em \+\_\+n\+\_\+faces} & Target face complexity. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
Number of collapses that were actually performed. 
\end{DoxyReturn}
\begin{DoxyNote}{Note}
Decimation stops as soon as either one of the two complexity bounds is satisfied. 

This operation only marks the removed mesh elements for deletion. In order to actually remove the decimated elements from the mesh, a subsequent call to \hyperlink{a08576_aba7fd4df59227f974b44111ac45e835f}{Array\+Kernel\+::garbage\+\_\+collection()} is required. 
\end{DoxyNote}


Definition at line 254 of file Decimater\+T\+\_\+impl.\+hh.



The documentation for this class was generated from the following files\+:\begin{DoxyCompactItemize}
\item 
Open\+Flipper/libs\+\_\+required/\+Open\+Mesh/src/\+Open\+Mesh/\+Tools/\+Decimater/\hyperlink{a02183}{Decimater\+T.\+hh}\item 
Open\+Flipper/libs\+\_\+required/\+Open\+Mesh/src/\+Open\+Mesh/\+Tools/\+Decimater/\hyperlink{a02186}{Decimater\+T\+\_\+impl.\+hh}\end{DoxyCompactItemize}
