\hypertarget{classACG_1_1FBO}{}\section{A\+CG\+:\+:F\+BO Class Reference}
\label{classACG_1_1FBO}\index{A\+C\+G\+::\+F\+BO@{A\+C\+G\+::\+F\+BO}}


{\ttfamily \#include $<$AC$>$}

\subsection*{Classes}
\begin{DoxyCompactItemize}
\item 
struct \hyperlink{structACG_1_1FBO_1_1RenderTexture}{Render\+Texture}
\begin{DoxyCompactList}\small\item\em attached textures \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{classACG_1_1FBO_a52d6858c476464ebbbd275d37f6531dc}\label{classACG_1_1FBO_a52d6858c476464ebbbd275d37f6531dc}} 
\hyperlink{classACG_1_1FBO_a52d6858c476464ebbbd275d37f6531dc}{F\+BO} ()
\begin{DoxyCompactList}\small\item\em Default constructor. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_affaea090595400f09ba37ee9d3bcadbe}\label{classACG_1_1FBO_affaea090595400f09ba37ee9d3bcadbe}} 
\hyperlink{classACG_1_1FBO_affaea090595400f09ba37ee9d3bcadbe}{$\sim$\+F\+BO} ()
\begin{DoxyCompactList}\small\item\em Destructor. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_ab4256b7f0f97005a05e8af2a09897cfc}\label{classACG_1_1FBO_ab4256b7f0f97005a05e8af2a09897cfc}} 
void \hyperlink{classACG_1_1FBO_ab4256b7f0f97005a05e8af2a09897cfc}{init} ()
\begin{DoxyCompactList}\small\item\em function to generate the framebuffer object \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a7397969046758e5b6ffa15722b7a2178}\label{classACG_1_1FBO_a7397969046758e5b6ffa15722b7a2178}} 
void \hyperlink{classACG_1_1FBO_a7397969046758e5b6ffa15722b7a2178}{del} ()
\begin{DoxyCompactList}\small\item\em delete fbo and all internally created render textures \end{DoxyCompactList}\item 
G\+Lsizei \hyperlink{classACG_1_1FBO_a24ffe53ca287f1279072a08a7f88388b}{set\+Multisampling} (G\+Lsizei \+\_\+samples, G\+Lboolean \+\_\+fixedsamplelocations=G\+L\+\_\+\+T\+R\+UE)
\item 
\mbox{\Hypertarget{classACG_1_1FBO_ad0adbab24bfbbaa60558873ca0d54121}\label{classACG_1_1FBO_ad0adbab24bfbbaa60558873ca0d54121}} 
G\+Lsizei \hyperlink{classACG_1_1FBO_ad0adbab24bfbbaa60558873ca0d54121}{get\+Multisampling\+Count} () const
\begin{DoxyCompactList}\small\item\em get number of samples \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_ad5263d260b50c3d0a9c35e0651f6151d}\label{classACG_1_1FBO_ad5263d260b50c3d0a9c35e0651f6151d}} 
void \hyperlink{classACG_1_1FBO_ad5263d260b50c3d0a9c35e0651f6151d}{attach\+Texture} (G\+Lenum \+\_\+attachment, G\+Luint \+\_\+texture, G\+Luint \+\_\+level=0)
\begin{DoxyCompactList}\small\item\em attach a texture of arbitrary dimension (requires Open\+GL 3.\+2) \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_aaab06a095274921d4f4e6b9f734cc073}\label{classACG_1_1FBO_aaab06a095274921d4f4e6b9f734cc073}} 
void \hyperlink{classACG_1_1FBO_aaab06a095274921d4f4e6b9f734cc073}{attach\+Texture2D} (G\+Lenum \+\_\+attachment, G\+Lsizei \+\_\+width, G\+Lsizei \+\_\+height, G\+Luint \+\_\+internal\+Fmt, G\+Lenum \+\_\+format, G\+Lint \+\_\+wrap\+Mode=G\+L\+\_\+\+C\+L\+A\+M\+P\+\_\+\+T\+O\+\_\+\+E\+D\+GE, G\+Lint \+\_\+min\+Filter=G\+L\+\_\+\+N\+E\+A\+R\+E\+ST, G\+Lint \+\_\+mag\+Filter=G\+L\+\_\+\+N\+E\+A\+R\+E\+ST)
\begin{DoxyCompactList}\small\item\em function to attach a texture to fbo \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_ac0deb2211a762c5b862764ec6f6fdf3e}\label{classACG_1_1FBO_ac0deb2211a762c5b862764ec6f6fdf3e}} 
void \hyperlink{classACG_1_1FBO_ac0deb2211a762c5b862764ec6f6fdf3e}{attach\+Texture2D} (G\+Lenum \+\_\+attachment, G\+Luint \+\_\+texture, G\+Lenum \+\_\+target=G\+L\+\_\+\+T\+E\+X\+T\+U\+R\+E\+\_\+2D)
\begin{DoxyCompactList}\small\item\em function to attach a texture to fbo \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_afec8577e57408e04b2ec7a2f2bfbe280}\label{classACG_1_1FBO_afec8577e57408e04b2ec7a2f2bfbe280}} 
void \hyperlink{classACG_1_1FBO_afec8577e57408e04b2ec7a2f2bfbe280}{attach\+Texture2\+D\+Depth} (G\+Lsizei \+\_\+width, G\+Lsizei \+\_\+height, G\+Luint \+\_\+internal\+Fmt=G\+L\+\_\+\+D\+E\+P\+T\+H\+\_\+\+C\+O\+M\+P\+O\+N\+E\+N\+T32, G\+Lenum \+\_\+format=G\+L\+\_\+\+D\+E\+P\+T\+H\+\_\+\+C\+O\+M\+P\+O\+N\+E\+NT)
\begin{DoxyCompactList}\small\item\em function to attach a depth-\/buffer texture to fbo (using G\+L\+\_\+\+D\+E\+P\+T\+H\+\_\+\+A\+T\+T\+A\+C\+H\+M\+E\+NT) \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a4c3af42bec8994ba6a9f3b98355e8324}\label{classACG_1_1FBO_a4c3af42bec8994ba6a9f3b98355e8324}} 
void \hyperlink{classACG_1_1FBO_a4c3af42bec8994ba6a9f3b98355e8324}{attach\+Texture2\+D\+Stencil} (G\+Lsizei \+\_\+width, G\+Lsizei \+\_\+height)
\begin{DoxyCompactList}\small\item\em function to attach a stencil-\/buffer texture to fbo (texformat = G\+L\+\_\+\+S\+T\+E\+N\+C\+I\+L\+\_\+\+I\+N\+D\+E\+X8) \end{DoxyCompactList}\item 
void \hyperlink{classACG_1_1FBO_ac02da5463edf0a255b384bf3ea59af19}{attach\+Texture3D} (G\+Lenum \+\_\+attachment, G\+Lsizei \+\_\+width, G\+Lsizei \+\_\+height, G\+Lsizei \+\_\+depth, G\+Luint \+\_\+internal\+Fmt, G\+Lenum \+\_\+format, G\+Lint \+\_\+wrap\+Mode=G\+L\+\_\+\+C\+L\+A\+MP, G\+Lint \+\_\+min\+Filter=G\+L\+\_\+\+N\+E\+A\+R\+E\+ST, G\+Lint \+\_\+mag\+Filter=G\+L\+\_\+\+N\+E\+A\+R\+E\+ST)
\item 
\mbox{\Hypertarget{classACG_1_1FBO_a62783d9990c73b69dd89a8283804de5d}\label{classACG_1_1FBO_a62783d9990c73b69dd89a8283804de5d}} 
void \hyperlink{classACG_1_1FBO_a62783d9990c73b69dd89a8283804de5d}{add\+Depth\+Buffer} (G\+Luint \+\_\+width, G\+Luint \+\_\+height)
\begin{DoxyCompactList}\small\item\em function to add a depth renderbuffer to the fbo \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_acbbde3c1dfab8255c7aade893e393565}\label{classACG_1_1FBO_acbbde3c1dfab8255c7aade893e393565}} 
void \hyperlink{classACG_1_1FBO_acbbde3c1dfab8255c7aade893e393565}{add\+Stencil\+Buffer} (G\+Luint \+\_\+width, G\+Luint \+\_\+height)
\begin{DoxyCompactList}\small\item\em function to add a stencil renderbuffer to the fbo \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_aef98b9f3115105b91fbdf4fe85af625a}\label{classACG_1_1FBO_aef98b9f3115105b91fbdf4fe85af625a}} 
void \hyperlink{classACG_1_1FBO_aef98b9f3115105b91fbdf4fe85af625a}{add\+Depth\+Stencil\+Buffer} (G\+Luint \+\_\+width, G\+Luint \+\_\+height)
\begin{DoxyCompactList}\small\item\em add a packed depth24\+\_\+stencil8 renderbuffer \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_acb9b2f3bf2f14c540dfd3372bae6d209}\label{classACG_1_1FBO_acb9b2f3bf2f14c540dfd3372bae6d209}} 
G\+Luint \hyperlink{classACG_1_1FBO_acb9b2f3bf2f14c540dfd3372bae6d209}{get\+Attachment} (G\+Lenum \+\_\+attachment)
\begin{DoxyCompactList}\small\item\em return attached texture id \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a0aa9c142397d219a0820f009f034eaaf}\label{classACG_1_1FBO_a0aa9c142397d219a0820f009f034eaaf}} 
G\+Luint \hyperlink{classACG_1_1FBO_a0aa9c142397d219a0820f009f034eaaf}{get\+Internal\+Format} (G\+Lenum \+\_\+attachment)
\begin{DoxyCompactList}\small\item\em return internal texture format of attachment \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_aaf48d9758bfc1b6eaeba332b40d6a32e}\label{classACG_1_1FBO_aaf48d9758bfc1b6eaeba332b40d6a32e}} 
G\+Luint \hyperlink{classACG_1_1FBO_aaf48d9758bfc1b6eaeba332b40d6a32e}{get\+Fbo\+ID} ()
\begin{DoxyCompactList}\small\item\em return opengl id \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a02bca0359a2fd432a8bdc7ca3d40fa41}\label{classACG_1_1FBO_a02bca0359a2fd432a8bdc7ca3d40fa41}} 
void \hyperlink{classACG_1_1FBO_a02bca0359a2fd432a8bdc7ca3d40fa41}{resize} (G\+Lsizei \+\_\+width, G\+Lsizei \+\_\+height, bool \+\_\+force\+Resize=false)
\begin{DoxyCompactList}\small\item\em resize function (if textures created by this class) \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a4e958161ffa96b16f029ab0a0adf55dc}\label{classACG_1_1FBO_a4e958161ffa96b16f029ab0a0adf55dc}} 
G\+Lsizei \hyperlink{classACG_1_1FBO_a4e958161ffa96b16f029ab0a0adf55dc}{width} () const
\begin{DoxyCompactList}\small\item\em get width of fbo texture \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a9e35d3206bf1dc8f879fd4a5df785176}\label{classACG_1_1FBO_a9e35d3206bf1dc8f879fd4a5df785176}} 
G\+Lsizei \hyperlink{classACG_1_1FBO_a9e35d3206bf1dc8f879fd4a5df785176}{height} () const
\begin{DoxyCompactList}\small\item\em get height of fbo texture \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a3b37a2dbd148a7ec989fe3a9187e92be}\label{classACG_1_1FBO_a3b37a2dbd148a7ec989fe3a9187e92be}} 
\hyperlink{namespaceACG_a72710dc6f55cd56f968f22bca0178e8c}{A\+C\+G\+::\+Vec2i} \hyperlink{classACG_1_1FBO_a3b37a2dbd148a7ec989fe3a9187e92be}{size} () const
\begin{DoxyCompactList}\small\item\em get width and height of fbo texture \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a286d9e8e30434040357e71ffbc51a04b}\label{classACG_1_1FBO_a286d9e8e30434040357e71ffbc51a04b}} 
bool \hyperlink{classACG_1_1FBO_a286d9e8e30434040357e71ffbc51a04b}{bind} ()
\begin{DoxyCompactList}\small\item\em bind the fbo and sets it as rendertarget \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_aa93b3a9ee52177e656298f092faa079e}\label{classACG_1_1FBO_aa93b3a9ee52177e656298f092faa079e}} 
void \hyperlink{classACG_1_1FBO_aa93b3a9ee52177e656298f092faa079e}{unbind} ()
\begin{DoxyCompactList}\small\item\em unbind fbo, go to normal rendering mode \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_afa31c68d9bc9056ab33244a065241730}\label{classACG_1_1FBO_afa31c68d9bc9056ab33244a065241730}} 
bool \hyperlink{classACG_1_1FBO_afa31c68d9bc9056ab33244a065241730}{check\+Framebuffer\+Status} ()
\begin{DoxyCompactList}\small\item\em function to check the framebuffer status \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Types}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{classACG_1_1FBO_a4dc57c8f4eca2ef5b4949195b34574b3}\label{classACG_1_1FBO_a4dc57c8f4eca2ef5b4949195b34574b3}} 
typedef std\+::map$<$ G\+Lenum, \hyperlink{structACG_1_1FBO_1_1RenderTexture}{Render\+Texture} $>$ {\bfseries Attachment\+List}
\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{classACG_1_1FBO_a2396f548f16bdec4623998222cd016e9}\label{classACG_1_1FBO_a2396f548f16bdec4623998222cd016e9}} 
G\+Luint \hyperlink{classACG_1_1FBO_a2396f548f16bdec4623998222cd016e9}{fbo\+\_\+}
\begin{DoxyCompactList}\small\item\em handle of frame buffer object \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_ac192e20b6443399956631ad01509f151}\label{classACG_1_1FBO_ac192e20b6443399956631ad01509f151}} 
G\+Luint \hyperlink{classACG_1_1FBO_ac192e20b6443399956631ad01509f151}{depthbuffer\+\_\+}
\begin{DoxyCompactList}\small\item\em depthbuffer \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a9f23e7f6d0acc2dbe6bd6e134226a153}\label{classACG_1_1FBO_a9f23e7f6d0acc2dbe6bd6e134226a153}} 
G\+Luint \hyperlink{classACG_1_1FBO_a9f23e7f6d0acc2dbe6bd6e134226a153}{stencilbuffer\+\_\+}
\begin{DoxyCompactList}\small\item\em stencilbuffer \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a523d231ffb128350dbe8750ce7806e4a}\label{classACG_1_1FBO_a523d231ffb128350dbe8750ce7806e4a}} 
Attachment\+List {\bfseries attachments\+\_\+}
\item 
\mbox{\Hypertarget{classACG_1_1FBO_ac900e11aec54df6fd58f4c034cf4a9da}\label{classACG_1_1FBO_ac900e11aec54df6fd58f4c034cf4a9da}} 
G\+Lsizei \hyperlink{classACG_1_1FBO_ac900e11aec54df6fd58f4c034cf4a9da}{width\+\_\+}
\begin{DoxyCompactList}\small\item\em width and height of render textures \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a773d36e3653f69bc58faffcdaaa1b589}\label{classACG_1_1FBO_a773d36e3653f69bc58faffcdaaa1b589}} 
G\+Lsizei {\bfseries height\+\_\+}
\item 
\mbox{\Hypertarget{classACG_1_1FBO_a0327bab62eddf6d344b0de4a3b9304f2}\label{classACG_1_1FBO_a0327bab62eddf6d344b0de4a3b9304f2}} 
G\+Lsizei \hyperlink{classACG_1_1FBO_a0327bab62eddf6d344b0de4a3b9304f2}{samples\+\_\+}
\begin{DoxyCompactList}\small\item\em sample count if multisampling \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a335818d9d70bf23f4187de48e0993a1d}\label{classACG_1_1FBO_a335818d9d70bf23f4187de48e0993a1d}} 
G\+Lboolean \hyperlink{classACG_1_1FBO_a335818d9d70bf23f4187de48e0993a1d}{fixedsamplelocation\+\_\+}
\begin{DoxyCompactList}\small\item\em enable fixed sample location if multisampling \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a5114d40b29c25fc40196a5cb199ee93d}\label{classACG_1_1FBO_a5114d40b29c25fc40196a5cb199ee93d}} 
G\+Luint \hyperlink{classACG_1_1FBO_a5114d40b29c25fc40196a5cb199ee93d}{prev\+Fbo\+\_\+}
\begin{DoxyCompactList}\small\item\em handle of previously bound fbo \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classACG_1_1FBO_a7e786ea0efc38a05e8e36ed98798a932}\label{classACG_1_1FBO_a7e786ea0efc38a05e8e36ed98798a932}} 
G\+Luint {\bfseries prev\+Draw\+Buffer\+\_\+}
\end{DoxyCompactItemize}


\subsection{Detailed Description}
/.../\+F\+BO.hh$>$

Brief Description.

A more elaborate description follows. 

Definition at line 71 of file F\+B\+O.\+hh.



\subsection{Member Function Documentation}
\mbox{\Hypertarget{classACG_1_1FBO_ac02da5463edf0a255b384bf3ea59af19}\label{classACG_1_1FBO_ac02da5463edf0a255b384bf3ea59af19}} 
\index{A\+C\+G\+::\+F\+BO@{A\+C\+G\+::\+F\+BO}!attach\+Texture3D@{attach\+Texture3D}}
\index{attach\+Texture3D@{attach\+Texture3D}!A\+C\+G\+::\+F\+BO@{A\+C\+G\+::\+F\+BO}}
\subsubsection{\texorpdfstring{attach\+Texture3\+D()}{attachTexture3D()}}
{\footnotesize\ttfamily void A\+C\+G\+::\+F\+B\+O\+::attach\+Texture3D (\begin{DoxyParamCaption}\item[{G\+Lenum}]{\+\_\+attachment,  }\item[{G\+Lsizei}]{\+\_\+width,  }\item[{G\+Lsizei}]{\+\_\+height,  }\item[{G\+Lsizei}]{\+\_\+depth,  }\item[{G\+Luint}]{\+\_\+internal\+Fmt,  }\item[{G\+Lenum}]{\+\_\+format,  }\item[{G\+Lint}]{\+\_\+wrap\+Mode = {\ttfamily GL\+\_\+CLAMP},  }\item[{G\+Lint}]{\+\_\+min\+Filter = {\ttfamily GL\+\_\+NEAREST},  }\item[{G\+Lint}]{\+\_\+mag\+Filter = {\ttfamily GL\+\_\+NEAREST} }\end{DoxyParamCaption})}

attach a 3D texture for render to volume (requires Open\+GL 3.\+2) binds all slices at once, target slice has to be chosen via gl\+\_\+\+Layer in geometry shader 

Definition at line 286 of file F\+B\+O.\+cc.

\mbox{\Hypertarget{classACG_1_1FBO_a24ffe53ca287f1279072a08a7f88388b}\label{classACG_1_1FBO_a24ffe53ca287f1279072a08a7f88388b}} 
\index{A\+C\+G\+::\+F\+BO@{A\+C\+G\+::\+F\+BO}!set\+Multisampling@{set\+Multisampling}}
\index{set\+Multisampling@{set\+Multisampling}!A\+C\+G\+::\+F\+BO@{A\+C\+G\+::\+F\+BO}}
\subsubsection{\texorpdfstring{set\+Multisampling()}{setMultisampling()}}
{\footnotesize\ttfamily G\+Lsizei A\+C\+G\+::\+F\+B\+O\+::set\+Multisampling (\begin{DoxyParamCaption}\item[{G\+Lsizei}]{\+\_\+samples,  }\item[{G\+Lboolean}]{\+\_\+fixedsamplelocations = {\ttfamily GL\+\_\+TRUE} }\end{DoxyParamCaption})}

enable/disable multisampling returns the M\+S\+AA sample count of the fbo, which might not be equal to the requested \+\_\+samples count but you\textquotesingle{}ll get something close 

Definition at line 609 of file F\+B\+O.\+cc.



The documentation for this class was generated from the following files\+:\begin{DoxyCompactItemize}
\item 
Open\+Flipper/libs\+\_\+required/\+A\+C\+G/\+G\+L/F\+B\+O.\+hh\item 
Open\+Flipper/libs\+\_\+required/\+A\+C\+G/\+G\+L/F\+B\+O.\+cc\end{DoxyCompactItemize}
