\section{Video}
\label{group__Video}\index{Video@{Video}}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
Evas\+\_\+\+Object $\ast$ \hyperlink{group__Video_ga618831f5036568cdf466ef3d6a13e8cf}{elm\+\_\+player\+\_\+add} (Evas\+\_\+\+Object $\ast$parent)
\begin{DoxyCompactList}\small\item\em Add a new Elm\+\_\+\+Player object to the given parent Elementary (container) object. \end{DoxyCompactList}\item 
Evas\+\_\+\+Object $\ast$ \hyperlink{group__Video_ga9d972bc458ae1875f63acf04db2d84ea}{elm\+\_\+video\+\_\+add} (Evas\+\_\+\+Object $\ast$parent)
\begin{DoxyCompactList}\small\item\em Add a new Elm\+\_\+\+Video object to the given parent Elementary (container) object. \end{DoxyCompactList}\item 
Eina\+\_\+\+Bool \hyperlink{group__Video_ga94ed29518f5215687622eb46ae61a896}{elm\+\_\+video\+\_\+file\+\_\+set} (Eo $\ast$obj, const char $\ast$filename)
\begin{DoxyCompactList}\small\item\em Define the file or U\+RI that will be the video source. \end{DoxyCompactList}\item 
void \hyperlink{group__Video_gab5ecb38fb4be0cb6e64fb8c0b66e5d4b}{elm\+\_\+video\+\_\+file\+\_\+get} (Eo $\ast$obj, const char $\ast$$\ast$filename)
\begin{DoxyCompactList}\small\item\em Get the file or U\+RI that is used as the video source. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
 
\begin{DoxyImageNoCaption}
  \mbox{\includegraphics[width=\textwidth,height=\textheight/2,keepaspectratio=true]{video_inheritance_tree}}
\end{DoxyImageNoCaption}


 
\begin{DoxyImageNoCaption}
  \mbox{\includegraphics[width=\textwidth,height=\textheight/2,keepaspectratio=true]{player_inheritance_tree}}
\end{DoxyImageNoCaption}


Elementary comes with two object that help design application that need to display video.

The first one, Elm\+\_\+\+Video, display a video by using Emotion. It embeds the video inside an Edje object, so you can do some animation depending on the video state change. It also implements a resource management policy to remove this burden from the application.

The second one, Elm\+\_\+\+Player is a video player that need to be linked with an Elm\+\_\+\+Video. It take care of updating its content according to Emotion event and provide a way to theme itself. It also automatically raises the priority of the linked Elm\+\_\+\+Video so it will use the video decoder, if available. It also activates the \char`\"{}remember\char`\"{} function on the linked Elm\+\_\+\+Video object.

Both widgets inherit from the \hyperlink{group__Layout}{Layout} one, so that all the functions acting on it also work for video objects.

This widget emits the following signals, besides the ones sent from Layout\+: \begin{DoxyItemize}
\item {\ttfamily \char`\"{}focused\char`\"{}} \+: When the video has received focus. (since 1.\+8) \item {\ttfamily \char`\"{}unfocused\char`\"{}} \+: When the video has lost focus. (since 1.\+8)\end{DoxyItemize}
The player widget emits the following signals, besides the ones sent from Layout\+:
\begin{DoxyItemize}
\item {\ttfamily \char`\"{}forward,clicked\char`\"{}} -\/ the user clicked the forward button.
\item {\ttfamily \char`\"{}info,clicked\char`\"{}} -\/ the user clicked the info button.
\item {\ttfamily \char`\"{}next,clicked\char`\"{}} -\/ the user clicked the next button.
\item {\ttfamily \char`\"{}pause,clicked\char`\"{}} -\/ the user clicked the pause button.
\item {\ttfamily \char`\"{}play,clicked\char`\"{}} -\/ the user clicked the play button.
\item {\ttfamily \char`\"{}prev,clicked\char`\"{}} -\/ the user clicked the prev button.
\item {\ttfamily \char`\"{}rewind,clicked\char`\"{}} -\/ the user clicked the rewind button.
\item {\ttfamily \char`\"{}stop,clicked\char`\"{}} -\/ the user clicked the stop button.
\end{DoxyItemize}

Default content parts of the player widget that you can use for are\+: \begin{DoxyItemize}
\item \char`\"{}video\char`\"{} -\/ A video of the player \end{DoxyItemize}


\subsection{Function Documentation}
\index{Video@{Video}!elm\+\_\+player\+\_\+add@{elm\+\_\+player\+\_\+add}}
\index{elm\+\_\+player\+\_\+add@{elm\+\_\+player\+\_\+add}!Video@{Video}}
\subsubsection[{\texorpdfstring{elm\+\_\+player\+\_\+add(\+Evas\+\_\+\+Object $\ast$parent)}{elm_player_add(Evas_Object *parent)}}]{\setlength{\rightskip}{0pt plus 5cm}Evas\+\_\+\+Object$\ast$ elm\+\_\+player\+\_\+add (
\begin{DoxyParamCaption}
\item[{Evas\+\_\+\+Object $\ast$}]{parent}
\end{DoxyParamCaption}
)}\label{group__Video_ga618831f5036568cdf466ef3d6a13e8cf}


Add a new Elm\+\_\+\+Player object to the given parent Elementary (container) object. 


\begin{DoxyParams}{Parameters}
{\em parent} & The parent object \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
a new player widget handle or {\ttfamily N\+U\+LL}, on errors.
\end{DoxyReturn}
This function inserts a new player widget on the canvas.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__General_ga0531ec8867c72def7c780601764ca642}{elm\+\_\+object\+\_\+part\+\_\+content\+\_\+set()} 
\end{DoxySeeAlso}
\index{Video@{Video}!elm\+\_\+video\+\_\+add@{elm\+\_\+video\+\_\+add}}
\index{elm\+\_\+video\+\_\+add@{elm\+\_\+video\+\_\+add}!Video@{Video}}
\subsubsection[{\texorpdfstring{elm\+\_\+video\+\_\+add(\+Evas\+\_\+\+Object $\ast$parent)}{elm_video_add(Evas_Object *parent)}}]{\setlength{\rightskip}{0pt plus 5cm}Evas\+\_\+\+Object$\ast$ elm\+\_\+video\+\_\+add (
\begin{DoxyParamCaption}
\item[{Evas\+\_\+\+Object $\ast$}]{parent}
\end{DoxyParamCaption}
)}\label{group__Video_ga9d972bc458ae1875f63acf04db2d84ea}


Add a new Elm\+\_\+\+Video object to the given parent Elementary (container) object. 


\begin{DoxyParams}{Parameters}
{\em parent} & The parent object \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
a new video widget handle or {\ttfamily N\+U\+LL}, on errors.
\end{DoxyReturn}
This function inserts a new video widget on the canvas.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__Video_ga94ed29518f5215687622eb46ae61a896}{elm\+\_\+video\+\_\+file\+\_\+set()} 
\end{DoxySeeAlso}
\index{Video@{Video}!elm\+\_\+video\+\_\+file\+\_\+get@{elm\+\_\+video\+\_\+file\+\_\+get}}
\index{elm\+\_\+video\+\_\+file\+\_\+get@{elm\+\_\+video\+\_\+file\+\_\+get}!Video@{Video}}
\subsubsection[{\texorpdfstring{elm\+\_\+video\+\_\+file\+\_\+get(\+Eo $\ast$obj, const char $\ast$$\ast$filename)}{elm_video_file_get(Eo *obj, const char **filename)}}]{\setlength{\rightskip}{0pt plus 5cm}void elm\+\_\+video\+\_\+file\+\_\+get (
\begin{DoxyParamCaption}
\item[{Eo $\ast$}]{obj, }
\item[{const char $\ast$$\ast$}]{filename}
\end{DoxyParamCaption}
)}\label{group__Video_gab5ecb38fb4be0cb6e64fb8c0b66e5d4b}


Get the file or U\+RI that is used as the video source. 


\begin{DoxyParams}{Parameters}
{\em filename} & The file or U\+RI.\\
\hline
\end{DoxyParams}
\begin{DoxySince}{Since}
1.\+14 
\end{DoxySince}
\index{Video@{Video}!elm\+\_\+video\+\_\+file\+\_\+set@{elm\+\_\+video\+\_\+file\+\_\+set}}
\index{elm\+\_\+video\+\_\+file\+\_\+set@{elm\+\_\+video\+\_\+file\+\_\+set}!Video@{Video}}
\subsubsection[{\texorpdfstring{elm\+\_\+video\+\_\+file\+\_\+set(\+Eo $\ast$obj, const char $\ast$filename)}{elm_video_file_set(Eo *obj, const char *filename)}}]{\setlength{\rightskip}{0pt plus 5cm}Eina\+\_\+\+Bool elm\+\_\+video\+\_\+file\+\_\+set (
\begin{DoxyParamCaption}
\item[{Eo $\ast$}]{obj, }
\item[{const char $\ast$}]{filename}
\end{DoxyParamCaption}
)}\label{group__Video_ga94ed29518f5215687622eb46ae61a896}


Define the file or U\+RI that will be the video source. 

\begin{DoxyReturn}{Returns}
{\ttfamily E\+I\+N\+A\+\_\+\+T\+R\+UE} on success, {\ttfamily E\+I\+N\+A\+\_\+\+F\+A\+L\+SE} otherwise
\end{DoxyReturn}
This function will explicitly define a file or U\+RI as a source for the video of the Elm\+\_\+\+Video object.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__Video_ga9d972bc458ae1875f63acf04db2d84ea}{elm\+\_\+video\+\_\+add()} 

\hyperlink{group__Video_ga618831f5036568cdf466ef3d6a13e8cf}{elm\+\_\+player\+\_\+add()}
\end{DoxySeeAlso}

\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em filename} & The file or U\+RI to target. Local files can be specified using \href{file://}{\tt file\+://} or by using full file paths. U\+RI could be remote source of video, like \href{http://}{\tt http\+://} or local source like Web\+Cam (v4l2\+://). (You can use Emotion A\+PI to request and list the available Webcam on your system). \\
\hline
\end{DoxyParams}
