\hypertarget{classOpenMesh_1_1IO_1_1__OFFReader__}{}\section{Open\+Mesh\+:\+:IO\+:\+:\+\_\+\+O\+F\+F\+Reader\+\_\+ Class Reference}
\label{classOpenMesh_1_1IO_1_1__OFFReader__}\index{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+@{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+}}


{\ttfamily \#include $<$Open\+Flipper/libs\+\_\+required/\+Open\+Mesh/src/\+Open\+Mesh/\+Core/\+I\+O/reader/\+O\+F\+F\+Reader.\+hh$>$}

Inheritance diagram for Open\+Mesh\+:\+:IO\+:\+:\+\_\+\+O\+F\+F\+Reader\+\_\+\+:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=2.000000cm]{classOpenMesh_1_1IO_1_1__OFFReader__}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a03ed5cb451f35941a024c3933a3abd0b}\label{classOpenMesh_1_1IO_1_1__OFFReader___a03ed5cb451f35941a024c3933a3abd0b}} 
virtual \hyperlink{classOpenMesh_1_1IO_1_1__OFFReader___a03ed5cb451f35941a024c3933a3abd0b}{$\sim$\+\_\+\+O\+F\+F\+Reader\+\_\+} ()
\begin{DoxyCompactList}\small\item\em Destructor. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a3e6980ef7828abfdf39a9c6e6fe4746f}\label{classOpenMesh_1_1IO_1_1__OFFReader___a3e6980ef7828abfdf39a9c6e6fe4746f}} 
std\+::string \hyperlink{classOpenMesh_1_1IO_1_1__OFFReader___a3e6980ef7828abfdf39a9c6e6fe4746f}{get\+\_\+description} () const override
\begin{DoxyCompactList}\small\item\em Returns a brief description of the file type that can be parsed. \end{DoxyCompactList}\item 
std\+::string \hyperlink{classOpenMesh_1_1IO_1_1__OFFReader___ad7527069b7ce7f90e5cbbf3102178299}{get\+\_\+extensions} () const override
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___aedf3c09b198039fd080c83e9bc106fcf}\label{classOpenMesh_1_1IO_1_1__OFFReader___aedf3c09b198039fd080c83e9bc106fcf}} 
std\+::string \hyperlink{classOpenMesh_1_1IO_1_1__OFFReader___aedf3c09b198039fd080c83e9bc106fcf}{get\+\_\+magic} () const override
\begin{DoxyCompactList}\small\item\em Return magic bits used to determine file format. \end{DoxyCompactList}\item 
bool \hyperlink{classOpenMesh_1_1IO_1_1__OFFReader___a88e2011ca42baa579175f01c6e63121e}{read} (const std\+::string \&\+\_\+filename, \hyperlink{classOpenMesh_1_1IO_1_1BaseImporter}{Base\+Importer} \&\+\_\+bi, \hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} \&\+\_\+opt) override
\item 
bool \hyperlink{classOpenMesh_1_1IO_1_1__OFFReader___a0204e3fe1867bd1086e6e962f381e0b6}{can\+\_\+u\+\_\+read} (const std\+::string \&\+\_\+filename) const override
\begin{DoxyCompactList}\small\item\em Returns true if writer can parse \+\_\+filename (checks extension). \+\_\+filename can also provide an extension without a name for a file e.\+g. \+\_\+filename == \char`\"{}om\char`\"{} checks, if the reader can read the \char`\"{}om\char`\"{} extension. \end{DoxyCompactList}\item 
bool \hyperlink{classOpenMesh_1_1IO_1_1__OFFReader___a44641981102decac8882009401469af5}{read} (std\+::istream \&\+\_\+in, \hyperlink{classOpenMesh_1_1IO_1_1BaseImporter}{Base\+Importer} \&\+\_\+bi, \hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} \&\+\_\+opt) override
\end{DoxyCompactItemize}
\subsection*{Private Member Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___ac89a2efea21b338f57992e5034adafcf}\label{classOpenMesh_1_1IO_1_1__OFFReader___ac89a2efea21b338f57992e5034adafcf}} 
bool {\bfseries can\+\_\+u\+\_\+read} (std\+::istream \&\+\_\+is) const
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___ad0b1f46bcd03800ba532a7d601d82422}\label{classOpenMesh_1_1IO_1_1__OFFReader___ad0b1f46bcd03800ba532a7d601d82422}} 
bool {\bfseries read\+\_\+ascii} (std\+::istream \&\+\_\+in, \hyperlink{classOpenMesh_1_1IO_1_1BaseImporter}{Base\+Importer} \&\+\_\+bi, \hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} \&\+\_\+opt) const
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___adbdb7ff9b549fa1a79ec565dbe1c1345}\label{classOpenMesh_1_1IO_1_1__OFFReader___adbdb7ff9b549fa1a79ec565dbe1c1345}} 
bool {\bfseries read\+\_\+binary} (std\+::istream \&\+\_\+in, \hyperlink{classOpenMesh_1_1IO_1_1BaseImporter}{Base\+Importer} \&\+\_\+bi, \hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} \&\+\_\+opt, bool swap) const
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a14199a3919afedfbb0b9d14c6ae79945}\label{classOpenMesh_1_1IO_1_1__OFFReader___a14199a3919afedfbb0b9d14c6ae79945}} 
void {\bfseries read\+Value} (std\+::istream \&\+\_\+in, float \&\+\_\+value) const
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a6874f0546fa23a16a00c37cf6468a35c}\label{classOpenMesh_1_1IO_1_1__OFFReader___a6874f0546fa23a16a00c37cf6468a35c}} 
void {\bfseries read\+Value} (std\+::istream \&\+\_\+in, int \&\+\_\+value) const
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a99e7a077d711bf8d7ee45ae0da2d316a}\label{classOpenMesh_1_1IO_1_1__OFFReader___a99e7a077d711bf8d7ee45ae0da2d316a}} 
void {\bfseries read\+Value} (std\+::istream \&\+\_\+in, unsigned int \&\+\_\+value) const
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a23e4fd7d0686346657b83810e01d66fa}\label{classOpenMesh_1_1IO_1_1__OFFReader___a23e4fd7d0686346657b83810e01d66fa}} 
int {\bfseries get\+Color\+Type} (std\+::string \&\+\_\+line, bool \+\_\+tex\+Coords\+Available) const
\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a3c01b93bf3f3a077d8dd2a069c839224}\label{classOpenMesh_1_1IO_1_1__OFFReader___a3c01b93bf3f3a077d8dd2a069c839224}} 
\hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} {\bfseries options\+\_\+}
\item 
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a3e230068dc4ccc4f7fcf6ca483cfffc6}\label{classOpenMesh_1_1IO_1_1__OFFReader___a3e230068dc4ccc4f7fcf6ca483cfffc6}} 
\hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} {\bfseries user\+Options\+\_\+}
\end{DoxyCompactItemize}
\subsection*{Additional Inherited Members}


\subsection{Detailed Description}
Implementation of the O\+FF format reader. This class is singleton\textquotesingle{}ed by \hyperlink{classOpenMesh_1_1SingletonT}{SingletonT} to O\+F\+F\+Reader.

By passing \hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} to the read function you can manipulate the reading behavoir. The following options can be set\+:

Vertex\+Normal Vertex\+Color Vertex\+Tex\+Coord Face\+Color Color\+Alpha \mbox{[}only when reading binary\mbox{]}

These options define if the corresponding data should be read (if available) or if it should be omitted.

After execution of the read function. The options object contains information about what was actually read.

e.\+g. if Vertex\+Normal was true when the read function was called, but the file did not contain vertex normals then it is false afterwards.

When reading a binary off with Color Flag in the header it is assumed that all vertices and faces have colors in the format \char`\"{}int int int\char`\"{}. If Color\+Alpha is set the format \char`\"{}int int int int\char`\"{} is assumed. 

Definition at line 109 of file O\+F\+F\+Reader.\+hh.



\subsection{Member Function Documentation}
\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a0204e3fe1867bd1086e6e962f381e0b6}\label{classOpenMesh_1_1IO_1_1__OFFReader___a0204e3fe1867bd1086e6e962f381e0b6}} 
\index{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+@{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+}!can\+\_\+u\+\_\+read@{can\+\_\+u\+\_\+read}}
\index{can\+\_\+u\+\_\+read@{can\+\_\+u\+\_\+read}!Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+@{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+}}
\subsubsection{\texorpdfstring{can\+\_\+u\+\_\+read()}{can\_u\_read()}}
{\footnotesize\ttfamily bool Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+\+::can\+\_\+u\+\_\+read (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{\+\_\+filename }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}}



Returns true if writer can parse \+\_\+filename (checks extension). \+\_\+filename can also provide an extension without a name for a file e.\+g. \+\_\+filename == \char`\"{}om\char`\"{} checks, if the reader can read the \char`\"{}om\char`\"{} extension. 


\begin{DoxyParams}{Parameters}
{\em \+\_\+filename} & complete name of a file or just the extension \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
true, if reader can read data with the given extension 
\end{DoxyReturn}


Reimplemented from \hyperlink{classOpenMesh_1_1IO_1_1BaseReader_accf5c3edc6b4f628d0a696c7d10fc475}{Open\+Mesh\+::\+I\+O\+::\+Base\+Reader}.



Definition at line 608 of file O\+F\+F\+Reader.\+cc.

\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___ad7527069b7ce7f90e5cbbf3102178299}\label{classOpenMesh_1_1IO_1_1__OFFReader___ad7527069b7ce7f90e5cbbf3102178299}} 
\index{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+@{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+}!get\+\_\+extensions@{get\+\_\+extensions}}
\index{get\+\_\+extensions@{get\+\_\+extensions}!Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+@{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+}}
\subsubsection{\texorpdfstring{get\+\_\+extensions()}{get\_extensions()}}
{\footnotesize\ttfamily std\+::string Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+\+::get\+\_\+extensions (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [override]}, {\ttfamily [virtual]}}

Returns a string with the accepted file extensions separated by a whitespace and in small caps. 

Implements \hyperlink{classOpenMesh_1_1IO_1_1BaseReader_a9e76bc7b1b46b7a8b4922d8ca5934419}{Open\+Mesh\+::\+I\+O\+::\+Base\+Reader}.



Definition at line 119 of file O\+F\+F\+Reader.\+hh.

\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a88e2011ca42baa579175f01c6e63121e}\label{classOpenMesh_1_1IO_1_1__OFFReader___a88e2011ca42baa579175f01c6e63121e}} 
\index{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+@{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+}!read@{read}}
\index{read@{read}!Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+@{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+}}
\subsubsection{\texorpdfstring{read()}{read()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily bool Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+\+::read (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{\+\_\+filename,  }\item[{\hyperlink{classOpenMesh_1_1IO_1_1BaseImporter}{Base\+Importer} \&}]{\+\_\+bi,  }\item[{\hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} \&}]{\+\_\+opt }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}}

Reads a mesh given by a filename. Usually this method opens a stream and passes it to stream read method. Acceptance checks by filename extension can be placed here.

\hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} can be passed via \+\_\+opt. After execution \+\_\+opt contains the \hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} that were available 

Implements \hyperlink{classOpenMesh_1_1IO_1_1BaseReader_af4a32645528c1bf2043a9259b172f411}{Open\+Mesh\+::\+I\+O\+::\+Base\+Reader}.



Definition at line 106 of file O\+F\+F\+Reader.\+cc.

\mbox{\Hypertarget{classOpenMesh_1_1IO_1_1__OFFReader___a44641981102decac8882009401469af5}\label{classOpenMesh_1_1IO_1_1__OFFReader___a44641981102decac8882009401469af5}} 
\index{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+@{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+}!read@{read}}
\index{read@{read}!Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+@{Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+}}
\subsubsection{\texorpdfstring{read()}{read()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily bool Open\+Mesh\+::\+I\+O\+::\+\_\+\+O\+F\+F\+Reader\+\_\+\+::read (\begin{DoxyParamCaption}\item[{std\+::istream \&}]{\+\_\+is,  }\item[{\hyperlink{classOpenMesh_1_1IO_1_1BaseImporter}{Base\+Importer} \&}]{\+\_\+bi,  }\item[{\hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} \&}]{\+\_\+opt }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}}

Reads a mesh given by a std\+::stream. This method usually uses the same stream reading method that read uses. \hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} can be passed via \+\_\+opt. After execution \+\_\+opt contains the \hyperlink{classOpenMesh_1_1IO_1_1Options}{Options} that were available.

Please make sure that if \+\_\+is is std\+::ifstream, the correct std\+::ios\+\_\+base\+::openmode flags are set. 

Implements \hyperlink{classOpenMesh_1_1IO_1_1BaseReader_a0fd4df36decf91cd91a7f363aae56065}{Open\+Mesh\+::\+I\+O\+::\+Base\+Reader}.



Definition at line 133 of file O\+F\+F\+Reader.\+cc.



The documentation for this class was generated from the following files\+:\begin{DoxyCompactItemize}
\item 
Open\+Flipper/libs\+\_\+required/\+Open\+Mesh/src/\+Open\+Mesh/\+Core/\+I\+O/reader/O\+F\+F\+Reader.\+hh\item 
Open\+Flipper/libs\+\_\+required/\+Open\+Mesh/src/\+Open\+Mesh/\+Core/\+I\+O/reader/O\+F\+F\+Reader.\+cc\end{DoxyCompactItemize}
