\hypertarget{a00430}{\section{A\+C\+G\+:\+:Color\+Stack Class Reference}
\label{a00430}\index{A\+C\+G\+::\+Color\+Stack@{A\+C\+G\+::\+Color\+Stack}}
}


{\ttfamily \#include $<$A\+C\+G/\+G\+L/\+Color\+Stack.\+hh$>$}

\subsection*{Classes}
\begin{DoxyCompactItemize}
\item 
class \hyperlink{a00879}{Node}
\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{a00430_a3c0b2272c27e354116a708a9e041a141}{\hyperlink{a00430_a3c0b2272c27e354116a708a9e041a141}{Color\+Stack} ()}\label{a00430_a3c0b2272c27e354116a708a9e041a141}

\begin{DoxyCompactList}\small\item\em Default constructor. \end{DoxyCompactList}\item 
\hypertarget{a00430_a2f2681a75ec7a3e7d1495a7e87dbcc9e}{\hyperlink{a00430_a2f2681a75ec7a3e7d1495a7e87dbcc9e}{$\sim$\+Color\+Stack} ()}\label{a00430_a2f2681a75ec7a3e7d1495a7e87dbcc9e}

\begin{DoxyCompactList}\small\item\em Destructor. \end{DoxyCompactList}\item 
\hypertarget{a00430_a36bd82b81e2fa8ec9504a7c82a6c5862}{void \hyperlink{a00430_a36bd82b81e2fa8ec9504a7c82a6c5862}{initialize} ()}\label{a00430_a36bd82b81e2fa8ec9504a7c82a6c5862}

\begin{DoxyCompactList}\small\item\em init (takes current G\+L context/ like gl\+Init\+Names (); gl\+Push\+Name (0)) \end{DoxyCompactList}\item 
\hypertarget{a00430_a4471a0040f1c52358908b72fbd37ffc7}{bool \hyperlink{a00430_a4471a0040f1c52358908b72fbd37ffc7}{initialized} () const }\label{a00430_a4471a0040f1c52358908b72fbd37ffc7}

\begin{DoxyCompactList}\small\item\em has it been initialized? \end{DoxyCompactList}\item 
\hypertarget{a00430_ab91df7af4366fdc375c78c530145e5cd}{bool \hyperlink{a00430_ab91df7af4366fdc375c78c530145e5cd}{set\+Maximum\+Index} (unsigned int \+\_\+idx)}\label{a00430_ab91df7af4366fdc375c78c530145e5cd}

\begin{DoxyCompactList}\small\item\em sets the maximum index number used in current node \end{DoxyCompactList}\item 
\hypertarget{a00430_aefc89d2a005a7bf16409afa8131cb431}{void \hyperlink{a00430_aefc89d2a005a7bf16409afa8131cb431}{set\+Index} (unsigned int \+\_\+idx)}\label{a00430_aefc89d2a005a7bf16409afa8131cb431}

\begin{DoxyCompactList}\small\item\em sets the current color the given index (like gl\+Load\+Name) \end{DoxyCompactList}\item 
\hypertarget{a00430_a1886210b182588abef696a5077d8d150}{\hyperlink{a03336_adb89a8d57b6d179ad535c0880a8b616e}{Vec4uc} \hyperlink{a00430_a1886210b182588abef696a5077d8d150}{get\+Index\+Color} (unsigned int \+\_\+idx)}\label{a00430_a1886210b182588abef696a5077d8d150}

\begin{DoxyCompactList}\small\item\em gets the color instead of setting it directly \end{DoxyCompactList}\item 
\hypertarget{a00430_ae8b820217055dc73ce7cdec3eea9d5b0}{void \hyperlink{a00430_ae8b820217055dc73ce7cdec3eea9d5b0}{push\+Index} (unsigned int \+\_\+idx)}\label{a00430_ae8b820217055dc73ce7cdec3eea9d5b0}

\begin{DoxyCompactList}\small\item\em creates a new node the stack (like gl\+Push\+Name) \end{DoxyCompactList}\item 
\hypertarget{a00430_a4c9339096a4f3d8533f5bd4dec30e4ca}{void \hyperlink{a00430_a4c9339096a4f3d8533f5bd4dec30e4ca}{pop\+Index} ()}\label{a00430_a4c9339096a4f3d8533f5bd4dec30e4ca}

\begin{DoxyCompactList}\small\item\em pops the current node from the stack (like gl\+Pop\+Name) \end{DoxyCompactList}\item 
\hypertarget{a00430_a7cb886d6b24397a7d2798bbd7b48c58f}{std\+::vector$<$ unsigned int $>$ \hyperlink{a00430_a7cb886d6b24397a7d2798bbd7b48c58f}{color\+To\+Stack} (\hyperlink{a03336_adb89a8d57b6d179ad535c0880a8b616e}{Vec4uc} \+\_\+rgba) const }\label{a00430_a7cb886d6b24397a7d2798bbd7b48c58f}

\begin{DoxyCompactList}\small\item\em converts the given color to index values on the stack \end{DoxyCompactList}\item 
\hypertarget{a00430_a24d5ca779a35b8e68b54f006217eafe7}{unsigned int \hyperlink{a00430_a24d5ca779a35b8e68b54f006217eafe7}{free\+Indicies} () const }\label{a00430_a24d5ca779a35b8e68b54f006217eafe7}

\begin{DoxyCompactList}\small\item\em returns maximal available index count \end{DoxyCompactList}\item 
\hypertarget{a00430_abfea3eb1d5edd233a59cf0d6e97ae067}{bool \hyperlink{a00430_abfea3eb1d5edd233a59cf0d6e97ae067}{error} () const }\label{a00430_abfea3eb1d5edd233a59cf0d6e97ae067}

\begin{DoxyCompactList}\small\item\em Did an error occur during picking. \end{DoxyCompactList}\item 
\hypertarget{a00430_a18202c842fcfa622c414453ca0dab32a}{unsigned int \hyperlink{a00430_a18202c842fcfa622c414453ca0dab32a}{current\+Index} () const }\label{a00430_a18202c842fcfa622c414453ca0dab32a}

\begin{DoxyCompactList}\small\item\em returns the current color index \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{a00430_a11617cb5c4e449e437520f78dae1b876}{bool {\bfseries initialized\+\_\+}}\label{a00430_a11617cb5c4e449e437520f78dae1b876}

\item 
\hypertarget{a00430_aca2252e241f11fc3c9cfa89d8d187e4d}{\hyperlink{a00433}{Color\+Translator} {\bfseries translator\+\_\+}}\label{a00430_aca2252e241f11fc3c9cfa89d8d187e4d}

\item 
\hypertarget{a00430_a04b2a6a6779b605df964c6c6646fc18c}{\hyperlink{a00879}{Node} $\ast$ {\bfseries root\+\_\+}}\label{a00430_a04b2a6a6779b605df964c6c6646fc18c}

\item 
\hypertarget{a00430_aa71c3838ed99a1bbd59b94330624ab02}{\hyperlink{a00879}{Node} $\ast$ {\bfseries current\+Node\+\_\+}}\label{a00430_aa71c3838ed99a1bbd59b94330624ab02}

\item 
\hypertarget{a00430_ad0cc21b12e0a7d817a97c0e4ee36b003}{bool {\bfseries error\+\_\+}}\label{a00430_ad0cc21b12e0a7d817a97c0e4ee36b003}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
This class can be used to implement a gl picking stack based on colors 

Definition at line 82 of file Color\+Stack.\+hh.



The documentation for this class was generated from the following files\+:\begin{DoxyCompactItemize}
\item 
A\+C\+G/\+G\+L/Color\+Stack.\+hh\item 
A\+C\+G/\+G\+L/Color\+Stack.\+cc\end{DoxyCompactItemize}
