\hypertarget{group__Evas__Canvas3D__Camera}{}\section{Camera Object}
\label{group__Evas__Canvas3D__Camera}\index{Camera Object@{Camera Object}}


A camera object is used for taking a picture of a scene graph.  


\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
E\+O\+A\+PI void \hyperlink{group__Evas__Canvas3D__Camera_gacf96c787ccc0e8bd048ba18b4f177d5e}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set} (const \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} $\ast$matrix)
\begin{DoxyCompactList}\small\item\em Set the projection matrix of the given camera. \end{DoxyCompactList}\item 
E\+O\+A\+PI void \hyperlink{group__Evas__Canvas3D__Camera_gad04a9083d29450a158aa08dfea990585}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+get} (\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} $\ast$matrix)
\begin{DoxyCompactList}\small\item\em Get the projection matrix of the given camera. \end{DoxyCompactList}\item 
E\+O\+A\+PI void \hyperlink{group__Evas__Canvas3D__Camera_gaf71a7b0af07a514a23befe4f14b0473d}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+perspective\+\_\+set} (\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} fovy, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} aspect, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} dnear, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} dfar)
\begin{DoxyCompactList}\small\item\em Set the projection matrix of the given camera with perspective projection. \end{DoxyCompactList}\item 
E\+O\+A\+PI void \hyperlink{group__Evas__Canvas3D__Camera_ga3198f2aa7d8e39ff7bc02e837bf5aed1}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+frustum\+\_\+set} (\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} left, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} right, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} bottom, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} top, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} dnear, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} dfar)
\begin{DoxyCompactList}\small\item\em Set the projection matrix of the given camera with frustum projection. \end{DoxyCompactList}\item 
E\+O\+A\+PI void \hyperlink{group__Evas__Canvas3D__Camera_ga6a50302b79a6bfbec1baf884f4e8248c}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+ortho\+\_\+set} (\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} left, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} right, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} bottom, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} top, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} dnear, \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} dfar)
\begin{DoxyCompactList}\small\item\em Set the projection matrix of the given camera with orthogonal projection. \end{DoxyCompactList}\item 
E\+O\+A\+PI \hyperlink{group__Eina__Types__Group_ga3fe0caf72e93b1bab1ca8ee3ccf3f226}{Eina\+\_\+\+Bool} \hyperlink{group__Evas__Canvas3D__Camera_ga7943a6e65e132c9514418d834a15c61e}{evas\+\_\+canvas3d\+\_\+camera\+\_\+node\+\_\+visible\+\_\+get} (Evas\+\_\+\+Canvas3\+D\+\_\+\+Node $\ast$camera\+\_\+node, Evas\+\_\+\+Canvas3\+D\+\_\+\+Node $\ast$node, Evas\+\_\+\+Canvas3\+D\+\_\+\+Frustum\+\_\+\+Mode key)
\begin{DoxyCompactList}\small\item\em Check is bounding sphere of given node inside frustum of camera node. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
A camera object is used for taking a picture of a scene graph. 

A camera object itself is just a set of properties on how the camera should take the picture (like focus length and film size of the real world cameras). To be able to take a shot of the scene, a camera should be located in the scene, so that it has its viewing position and direction. It is done by containing the camera on a node. If one wants to locate several cameras having same properties, instead of creating multiple cameras, just create one camera and multiple nodes containing the camera and locate them at each desired position and direction. Just for convenience, use \hyperlink{group__Evas__Canvas3D__Node_ga3ae6aa423b619559f1681df11358262e}{evas\+\_\+canvas3d\+\_\+node\+\_\+position\+\_\+set()} to move the camera to desired position and use \hyperlink{group__Evas__Canvas3D__Node_ga35efbb89636f8f2fac6793f87e004bb1}{evas\+\_\+canvas3d\+\_\+node\+\_\+look\+\_\+at\+\_\+set()} to adjust the viewing direction of the camera. 

\subsection{Function Documentation}
\mbox{\Hypertarget{group__Evas__Canvas3D__Camera_gacf96c787ccc0e8bd048ba18b4f177d5e}\label{group__Evas__Canvas3D__Camera_gacf96c787ccc0e8bd048ba18b4f177d5e}} 
\index{Camera Object@{Camera Object}!evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set}}
\index{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set}!Camera Object@{Camera Object}}
\subsubsection{\texorpdfstring{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set()}{evas\_canvas3d\_camera\_projection\_matrix\_set()}}
{\footnotesize\ttfamily E\+O\+A\+PI void evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set (\begin{DoxyParamCaption}\item[{const \hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} $\ast$}]{matrix }\end{DoxyParamCaption})}



Set the projection matrix of the given camera. 

Default projection matrix is identity matrix.

See also \hyperlink{group__Evas__Canvas3D__Camera_gaf71a7b0af07a514a23befe4f14b0473d}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+perspective\+\_\+set}, \hyperlink{group__Evas__Canvas3D__Camera_ga6a50302b79a6bfbec1baf884f4e8248c}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+ortho\+\_\+set} and \hyperlink{group__Evas__Canvas3D__Camera_ga3198f2aa7d8e39ff7bc02e837bf5aed1}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+frustum\+\_\+set}.


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em matrix} & Projection Matrix \\
\hline
\end{DoxyParams}
\mbox{\Hypertarget{group__Evas__Canvas3D__Camera_gad04a9083d29450a158aa08dfea990585}\label{group__Evas__Canvas3D__Camera_gad04a9083d29450a158aa08dfea990585}} 
\index{Camera Object@{Camera Object}!evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+get@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+get}}
\index{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+get@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+get}!Camera Object@{Camera Object}}
\subsubsection{\texorpdfstring{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+get()}{evas\_canvas3d\_camera\_projection\_matrix\_get()}}
{\footnotesize\ttfamily E\+O\+A\+PI void evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+get (\begin{DoxyParamCaption}\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real} $\ast$}]{matrix }\end{DoxyParamCaption})}



Get the projection matrix of the given camera. 

See also \hyperlink{group__Evas__Canvas3D__Camera_gacf96c787ccc0e8bd048ba18b4f177d5e}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set}.


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt out}  & {\em matrix} & Projection Matrix \\
\hline
\end{DoxyParams}
\mbox{\Hypertarget{group__Evas__Canvas3D__Camera_gaf71a7b0af07a514a23befe4f14b0473d}\label{group__Evas__Canvas3D__Camera_gaf71a7b0af07a514a23befe4f14b0473d}} 
\index{Camera Object@{Camera Object}!evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+perspective\+\_\+set@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+perspective\+\_\+set}}
\index{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+perspective\+\_\+set@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+perspective\+\_\+set}!Camera Object@{Camera Object}}
\subsubsection{\texorpdfstring{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+perspective\+\_\+set()}{evas\_canvas3d\_camera\_projection\_perspective\_set()}}
{\footnotesize\ttfamily E\+O\+A\+PI void evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+perspective\+\_\+set (\begin{DoxyParamCaption}\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{fovy,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{aspect,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{dnear,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{dfar }\end{DoxyParamCaption})}



Set the projection matrix of the given camera with perspective projection. 

See also \hyperlink{group__Evas__Canvas3D__Camera_gacf96c787ccc0e8bd048ba18b4f177d5e}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set}.


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em aspect} & Aspect ratio. \\
\hline
\mbox{\tt in}  & {\em dnear} & Distance to near clipping plane. \\
\hline
\mbox{\tt in}  & {\em dfar} & Distance to far clipping plane. \\
\hline
\end{DoxyParams}
\mbox{\Hypertarget{group__Evas__Canvas3D__Camera_ga3198f2aa7d8e39ff7bc02e837bf5aed1}\label{group__Evas__Canvas3D__Camera_ga3198f2aa7d8e39ff7bc02e837bf5aed1}} 
\index{Camera Object@{Camera Object}!evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+frustum\+\_\+set@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+frustum\+\_\+set}}
\index{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+frustum\+\_\+set@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+frustum\+\_\+set}!Camera Object@{Camera Object}}
\subsubsection{\texorpdfstring{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+frustum\+\_\+set()}{evas\_canvas3d\_camera\_projection\_frustum\_set()}}
{\footnotesize\ttfamily E\+O\+A\+PI void evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+frustum\+\_\+set (\begin{DoxyParamCaption}\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{left,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{right,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{bottom,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{top,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{dnear,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{dfar }\end{DoxyParamCaption})}



Set the projection matrix of the given camera with frustum projection. 

See also \hyperlink{group__Evas__Canvas3D__Camera_gacf96c787ccc0e8bd048ba18b4f177d5e}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set}.


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em right} & Right X coordinate of the near clipping plane.. \\
\hline
\mbox{\tt in}  & {\em bottom} & Bottom Y coordinate of the near clipping plane. \\
\hline
\mbox{\tt in}  & {\em top} & Top Y coordinate of the near clipping plane \\
\hline
\mbox{\tt in}  & {\em dnear} & Distance to near clipping plane. \\
\hline
\mbox{\tt in}  & {\em dfar} & Distance to far clipping plane. \\
\hline
\end{DoxyParams}
\mbox{\Hypertarget{group__Evas__Canvas3D__Camera_ga6a50302b79a6bfbec1baf884f4e8248c}\label{group__Evas__Canvas3D__Camera_ga6a50302b79a6bfbec1baf884f4e8248c}} 
\index{Camera Object@{Camera Object}!evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+ortho\+\_\+set@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+ortho\+\_\+set}}
\index{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+ortho\+\_\+set@{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+ortho\+\_\+set}!Camera Object@{Camera Object}}
\subsubsection{\texorpdfstring{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+ortho\+\_\+set()}{evas\_canvas3d\_camera\_projection\_ortho\_set()}}
{\footnotesize\ttfamily E\+O\+A\+PI void evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+ortho\+\_\+set (\begin{DoxyParamCaption}\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{left,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{right,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{bottom,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{top,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{dnear,  }\item[{\hyperlink{group__Evas_gafe9cc74872ef141d258c2162fa0ce5ca}{Evas\+\_\+\+Real}}]{dfar }\end{DoxyParamCaption})}



Set the projection matrix of the given camera with orthogonal projection. 

See also \hyperlink{group__Evas__Canvas3D__Camera_gacf96c787ccc0e8bd048ba18b4f177d5e}{evas\+\_\+canvas3d\+\_\+camera\+\_\+projection\+\_\+matrix\+\_\+set}.


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em right} & Right X coordinate of the near clipping plane.. \\
\hline
\mbox{\tt in}  & {\em bottom} & Bottom Y coordinate of the near clipping plane. \\
\hline
\mbox{\tt in}  & {\em top} & Top Y coordinate of the near clipping plane \\
\hline
\mbox{\tt in}  & {\em dnear} & Distance to near clipping plane. \\
\hline
\mbox{\tt in}  & {\em dfar} & Distance to far clipping plane. \\
\hline
\end{DoxyParams}
\mbox{\Hypertarget{group__Evas__Canvas3D__Camera_ga7943a6e65e132c9514418d834a15c61e}\label{group__Evas__Canvas3D__Camera_ga7943a6e65e132c9514418d834a15c61e}} 
\index{Camera Object@{Camera Object}!evas\+\_\+canvas3d\+\_\+camera\+\_\+node\+\_\+visible\+\_\+get@{evas\+\_\+canvas3d\+\_\+camera\+\_\+node\+\_\+visible\+\_\+get}}
\index{evas\+\_\+canvas3d\+\_\+camera\+\_\+node\+\_\+visible\+\_\+get@{evas\+\_\+canvas3d\+\_\+camera\+\_\+node\+\_\+visible\+\_\+get}!Camera Object@{Camera Object}}
\subsubsection{\texorpdfstring{evas\+\_\+canvas3d\+\_\+camera\+\_\+node\+\_\+visible\+\_\+get()}{evas\_canvas3d\_camera\_node\_visible\_get()}}
{\footnotesize\ttfamily E\+O\+A\+PI \hyperlink{group__Eina__Types__Group_ga3fe0caf72e93b1bab1ca8ee3ccf3f226}{Eina\+\_\+\+Bool} evas\+\_\+canvas3d\+\_\+camera\+\_\+node\+\_\+visible\+\_\+get (\begin{DoxyParamCaption}\item[{Evas\+\_\+\+Canvas3\+D\+\_\+\+Node $\ast$}]{camera\+\_\+node,  }\item[{Evas\+\_\+\+Canvas3\+D\+\_\+\+Node $\ast$}]{node,  }\item[{Evas\+\_\+\+Canvas3\+D\+\_\+\+Frustum\+\_\+\+Mode}]{key }\end{DoxyParamCaption})}



Check is bounding sphere of given node inside frustum of camera node. 

If the nodes are {\ttfamily null} or nodes type mismatch error wrong type of nodes will be generated and returned {\ttfamily false}.


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em node} & The given node. \\
\hline
\mbox{\tt in}  & {\em key} & \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
{\ttfamily true} in frustum, {\ttfamily false} otherwise 
\end{DoxyReturn}
