b17dbe9bf0f623929698e081c58589f1b76661ad
[profile/ivi/emotion.git] / src / lib / Emotion.h
1 #ifndef EMOTION_H
2 #define EMOTION_H
3
4 #include <Evas.h>
5
6 #ifdef EAPI
7 # undef EAPI
8 #endif
9
10 #ifdef _WIN32
11 # ifdef EFL_EMOTION_BUILD
12 #  ifdef DLL_EXPORT
13 #   define EAPI __declspec(dllexport)
14 #  else
15 #   define EAPI
16 #  endif /* ! DLL_EXPORT */
17 # else
18 #  define EAPI __declspec(dllimport)
19 # endif /* ! EFL_EMOTION_BUILD */
20 #else
21 # ifdef __GNUC__
22 #  if __GNUC__ >= 4
23 #   define EAPI __attribute__ ((visibility("default")))
24 #  else
25 #   define EAPI
26 #  endif
27 # else
28 #  define EAPI
29 # endif
30 #endif /* ! _WIN32 */
31
32 /**
33  * @file Emotion.h
34  * @brief The file that provides Emotion the API, with functions available for
35  *        play, seek, change volume, etc.
36  */
37
38 enum _Emotion_Module
39 {
40   EMOTION_MODULE_XINE,
41   EMOTION_MODULE_GSTREAMER
42 };
43
44 enum _Emotion_Event
45 {
46    EMOTION_EVENT_MENU1, // Escape Menu
47    EMOTION_EVENT_MENU2, // Title Menu
48    EMOTION_EVENT_MENU3, // Root Menu
49    EMOTION_EVENT_MENU4, // Subpicture Menu
50    EMOTION_EVENT_MENU5, // Audio Menu
51    EMOTION_EVENT_MENU6, // Angle Menu
52    EMOTION_EVENT_MENU7, // Part Menu
53    EMOTION_EVENT_UP,
54    EMOTION_EVENT_DOWN,
55    EMOTION_EVENT_LEFT,
56    EMOTION_EVENT_RIGHT,
57    EMOTION_EVENT_SELECT,
58    EMOTION_EVENT_NEXT,
59    EMOTION_EVENT_PREV,
60    EMOTION_EVENT_ANGLE_NEXT,
61    EMOTION_EVENT_ANGLE_PREV,
62    EMOTION_EVENT_FORCE,
63    EMOTION_EVENT_0,
64    EMOTION_EVENT_1,
65    EMOTION_EVENT_2,
66    EMOTION_EVENT_3,
67    EMOTION_EVENT_4,
68    EMOTION_EVENT_5,
69    EMOTION_EVENT_6,
70    EMOTION_EVENT_7,
71    EMOTION_EVENT_8,
72    EMOTION_EVENT_9,
73    EMOTION_EVENT_10
74 };
75
76 /**
77  * @enum _Emotion_Meta_Info
78  *
79  * Used for retrieving information about the media file being played.
80  *
81  * @see emotion_object_meta_info_get()
82  *
83  * @ingroup Emotion_Info
84  */
85 enum _Emotion_Meta_Info
86 {
87    EMOTION_META_INFO_TRACK_TITLE, /**< track title */
88    EMOTION_META_INFO_TRACK_ARTIST, /**< artist name */
89    EMOTION_META_INFO_TRACK_ALBUM, /**< album name */
90    EMOTION_META_INFO_TRACK_YEAR, /**< track year */
91    EMOTION_META_INFO_TRACK_GENRE, /**< track genre */
92    EMOTION_META_INFO_TRACK_COMMENT, /**< track comments */
93    EMOTION_META_INFO_TRACK_DISC_ID, /**< track disc ID */
94    EMOTION_META_INFO_TRACK_COUNT /**< track count - number of the track in the album */
95 };
96
97 /**
98  * @enum _Emotion_Vis
99  *
100  * Used for displaying a visualization on the emotion object.
101  *
102  * @see emotion_object_vis_set()
103  *
104  * @ingroup Emotion_Visualization
105  */
106 enum _Emotion_Vis
107 {
108   EMOTION_VIS_NONE, /**< no visualization set */
109   EMOTION_VIS_GOOM, /**< goom */
110   EMOTION_VIS_LIBVISUAL_BUMPSCOPE, /**< bumpscope */
111   EMOTION_VIS_LIBVISUAL_CORONA, /**< corona */
112   EMOTION_VIS_LIBVISUAL_DANCING_PARTICLES, /**< dancing particles */
113   EMOTION_VIS_LIBVISUAL_GDKPIXBUF, /**< gdkpixbuf */
114   EMOTION_VIS_LIBVISUAL_G_FORCE, /**< G force */
115   EMOTION_VIS_LIBVISUAL_GOOM, /**< goom */
116   EMOTION_VIS_LIBVISUAL_INFINITE, /**< infinite */
117   EMOTION_VIS_LIBVISUAL_JAKDAW, /**< jakdaw */
118   EMOTION_VIS_LIBVISUAL_JESS, /**< jess */
119   EMOTION_VIS_LIBVISUAL_LV_ANALYSER, /**< lv analyser */
120   EMOTION_VIS_LIBVISUAL_LV_FLOWER, /**< lv flower */
121   EMOTION_VIS_LIBVISUAL_LV_GLTEST, /**< lv gltest */
122   EMOTION_VIS_LIBVISUAL_LV_SCOPE, /**< lv scope */
123   EMOTION_VIS_LIBVISUAL_MADSPIN, /**< madspin */
124   EMOTION_VIS_LIBVISUAL_NEBULUS, /**< nebulus */
125   EMOTION_VIS_LIBVISUAL_OINKSIE, /**< oinksie */
126   EMOTION_VIS_LIBVISUAL_PLASMA, /**< plasma */
127   EMOTION_VIS_LAST /* sentinel */
128 };
129
130 typedef enum
131 {
132   EMOTION_WAKEUP,
133   EMOTION_SLEEP,
134   EMOTION_DEEP_SLEEP,
135   EMOTION_HIBERNATE
136 } Emotion_Suspend;
137
138 typedef enum _Emotion_Module    Emotion_Module;
139 typedef enum _Emotion_Event     Emotion_Event;
140 typedef enum _Emotion_Meta_Info Emotion_Meta_Info; /**< Meta info type to be retrieved. */
141 typedef enum _Emotion_Vis       Emotion_Vis; /**< Type of visualization. */
142
143 #define EMOTION_CHANNEL_AUTO -1
144 #define EMOTION_CHANNEL_DEFAULT 0
145
146 #ifdef __cplusplus
147 extern "C" {
148 #endif
149
150 /* api calls available */
151
152 /**
153  * @brief How to create, initialize, manipulate and connect to signals of an
154  * Emotion object.
155  * @defgroup Emotion_API API available for manipulating Emotion object.
156  *
157  * @{
158  *
159  * Emotion provides an Evas smart object that allows to play, control and
160  * display a video or audio file. The API is synchronous but not everything
161  * happens immediately. There are also some signals to report changed states.
162  *
163  * Basically, once the object is created and initialized, a file will be set to
164  * it, and then it can be resized, moved, and controlled by other Evas object
165  * functions.
166  *
167  * However, the decoding of the music and video occurs not in the Ecore main
168  * loop, but usually in another thread (this depends on the module being used).
169  * The synchronization between this other thread and the main loop not visible
170  * to the end user of the library. The user can just register callbacks to the
171  * available signals to receive information about the changed states, and can
172  * call other functions from the API to request more changes on the current
173  * loaded file.
174  *
175  * There will be a delay between an API being called and it being really
176  * executed, since this request will be done in the main thread, and it needs to
177  * be sent to the decoding thread. For this reason, always call functions like
178  * emotion_object_size_get() or emotion_object_length_get() after some signal
179  * being sent, like "playback_started" or "open_done". @ref
180  * emotion_signals_example.c "This example demonstrates this behavior".
181  *
182  * @section signals Available signals
183  * The Evas_Object returned by emotion_object_add() has a number of signals that
184  * can be listened to using evas' smart callbacks mechanism. All signals have
185  * NULL as event info. The following is a list of interesting signals:
186  * @li "playback_started" - Emitted when the playback starts
187  * @li "playback_finished" - Emitted when the playback finishes
188  * @li "frame_decode" - Emitted every time a frame is decoded
189  * @li "open_done" - Emitted when the media file is opened
190  * @li "position_update" - Emitted when emotion_object_position_set is called
191  * @li "decode_stop" - Emitted after the last frame is decoded
192  *
193  * @section Examples
194  *
195  * The following examples exemplify the emotion usage. There's also the
196  * emotion_test binary that is distributed with this library and cover the
197  * entire API, but since it is too long and repetitive to be explained, its code
198  * is just displayed as another example.
199  *
200  * @li @ref emotion_basic_example_c
201  * @li @ref emotion_signals_example.c "Emotion signals"
202  * @li @ref emotion_test_main.c "emotion_test - full API usage"
203  *
204  */
205
206 /**
207  * @defgroup Emotion_Init Creation and initialization functions
208  */
209
210 /**
211  * @defgroup Emotion_Audio Audio control functions
212  */
213
214 /**
215  * @defgroup Emotion_Video Video control functions
216  */
217
218 /**
219  * @defgroup Emotion_Visualization Visualization control functions
220  */
221
222 /**
223  * @defgroup Emotion_Info Miscellaneous information retrieval functions
224  */
225
226 /**
227  * @brief Add an emotion object to the canvas.
228  *
229  * @param evas The canvas where the object will be added to.
230  * @return The emotion object just created.
231  *
232  * This function creates an emotion object and adds it to the specified @p evas.
233  * The returned object can be manipulated as any other Evas object, using the
234  * default object manipulation functions - evas_object_*.
235  *
236  * After creating the object with this function, it's still necessary to
237  * initialize it with emotion_object_init(), and if an audio file is going to be
238  * played with this object instead of a video, use
239  * emotion_object_video_mute_set().
240  *
241  * The next step is to open the desired file with emotion_object_file_set(), and
242  * start playing it with emotion_object_play_set().
243  *
244  * @see emotion_object_init()
245  * @see emotion_object_video_mute_set()
246  * @see emotion_object_file_set()
247  * @see emotion_object_play_set()
248  *
249  * @ingroup Emotion_Init
250  */
251 EAPI Evas_Object *emotion_object_add                   (Evas *evas);
252
253 /**
254  * @brief Set the specified option for the current module.
255  *
256  * @param obj The emotion object which the option is being set to.
257  * @param opt The option that is being set. Currently supported optiosn: "video"
258  * and "audio".
259  * @param val The value of the option. Currently only supports "off" (?!?!?!)
260  *
261  * This function allows one to mute the video or audio of the emotion object.
262  *
263  * @note Please don't use this function, consider using
264  * emotion_object_audio_mute_set() and emotion_object_video_mute_set() instead.
265  *
266  * @see emotion_object_audio_mute_set()
267  * @see emotion_object_video_mute_set()
268  *
269  * @ingroup Emotion_Audio
270  * @ingroup Emotion_Video
271  */
272 EAPI void         emotion_object_module_option_set     (Evas_Object *obj, const char *opt, const char *val);
273
274 /**
275  * @brief Initializes an emotion object with the specified module.
276  *
277  * @param obj The emotion object to be initialized.
278  * @param module_filename The name of the module to be used (gstreamer or xine).
279  * @return @c EINA_TRUE if the specified module was successfully initialized for
280  * this object, @c EINA_FALSE otherwise.
281  *
282  * This function is required after creating the emotion object, in order to
283  * specify which module will be used with this object. Different objects can
284  * use different modules to play a media file. The current supported modules are
285  * @b gstreamer and @b xine.
286  *
287  * To use any of them, you need to make sure that support for them was compiled
288  * correctly.
289  *
290  * @note It's possible to disable the build of a module with
291  * --disable-module_name.
292  *
293  * @see emotion_object_add()
294  * @see emotion_object_file_set()
295  *
296  * @ingroup Emotion_Init
297  */
298 EAPI Eina_Bool    emotion_object_init                  (Evas_Object *obj, const char *module_filename);
299
300 /**
301  * @brief Set the file to be played in the Emotion object.
302  *
303  * @param obj The emotion object where the file is being loaded.
304  * @param filename Path to the file to be loaded. It can be absolute or relative
305  * path.
306  * @return EINA_TRUE if the new file could be loaded successfully, and
307  * EINA_FALSE if the file could not be loaded. This happens when the filename is
308  * could not be found, when the module couldn't open the file, when no module is
309  * initialized in this object, or when the @p filename is the same as the
310  * one previously set.
311  *
312  * This function sets the file to be used with this emotion object. If the
313  * object already has another file set, this file will be unset and unloaded,
314  * and the new file will be loaded to this emotion object. The seek position
315  * will be set to 0, and the emotion object will be paused, instead of playing.
316  *
317  * If there was already a filename set, and it's the same as the one being set
318  * now, this function does nothing and returns EINA_FALSE.
319  *
320  * Use @c NULL as argument to @p filename if you want to unload the current file
321  * but don't want to load anything else.
322  *
323  * @see emotion_object_init()
324  * @see emotion_object_play_set()
325  * @see emotion_object_file_get()
326  *
327  * @ingroup Emotion_Init
328  */
329 EAPI Eina_Bool    emotion_object_file_set              (Evas_Object *obj, const char *filename);
330
331 /**
332  * @brief Get the filename of the file associated with the emotion object.
333  *
334  * @param obj The emotion object from which the filename will be retrieved.
335  * @return The path to the file loaded into this emotion object.
336  *
337  * This function returns the path of the file loaded in this emotion object. If
338  * no object is loaded, it will return @c NULL.
339  *
340  * @note Don't free or change the string returned by this function in any way.
341  * If you want to unset it, use @c emotion_object_file_set(obj, NULL).
342  *
343  * @see emotion_object_file_set()
344  *
345  * @ingroup Emotion_Init
346  */
347 EAPI const char  *emotion_object_file_get              (const Evas_Object *obj);
348 /**
349  * @defgroup Emotion_Play Play control functions
350  *
351  * @{
352  */
353 /**
354  *
355  * @brief Set play/pause state of the media file.
356  *
357  * @param obj The emotion object whose state will be changed.
358  * @param play EINA_TRUE to play, EINA_FALSE to pause.
359  *
360  * This functions sets the currently playing status of the video. Using this
361  * function to play or pause the video doesn't alter it's current position.
362  */
363 EAPI void         emotion_object_play_set              (Evas_Object *obj, Eina_Bool play);
364 /**
365  * @brief Get play/pause state of the media file.
366  *
367  * @param obj The emotion object from which the state will be retrieved.
368  * @return EINA_TRUE if playing. EINA_FALSE if not playing.
369  */
370 EAPI Eina_Bool    emotion_object_play_get              (const Evas_Object *obj);
371 /**
372  * @brief Set the position in the media file.
373  *
374  * @param obj The emotion object whose position will be changed.
375  * @param sec The position(in seconds) to which the media file will be set.
376  *
377  * This functions sets the current position of the media file to @p sec, this
378  * only works on seekable streams. Setting the position doesn't change the
379  * playing state of the media file.
380  *
381  * @see emotion_object_seekable_get
382  */
383 EAPI void         emotion_object_position_set          (Evas_Object *obj, double sec);
384 /**
385  * @brief Get the position in the media file.
386  *
387  * @param obj The emotion object from which the position will be retrieved.
388  * @return The position of the media file.
389  *
390  * The position is returned as the number of seconds since the beginning of the
391  * media file.
392  */
393 EAPI double       emotion_object_position_get          (const Evas_Object *obj);
394 /**
395  * @brief Get whether the media file is seekable.
396  *
397  * @param obj The emotion object from which the seekable status will be
398  * retrieved.
399  * @return EINA_TRUE if the media file is seekable, EINA_FALSE otherwise.
400  */
401 EAPI Eina_Bool    emotion_object_seekable_get          (const Evas_Object *obj);
402 /**
403  * @brief Get the length of play for the media file.
404  *
405  * @param obj The emotion object from which the length will be retrieved.
406  * @return The length of the media file in seconds.
407  *
408  * This function returns the length of the media file in seconds.
409  *
410  * @warning This will return 0 if called before the "length_change" signal has,
411  * been emitted.
412  */
413 EAPI double       emotion_object_play_length_get       (const Evas_Object *obj);
414
415 /**
416  * @brief Set the play speed of the media file.
417  *
418  * @param obj The emotion object whose speed will be set.
419  * @param speed The speed to be set in the range [0,infinity)
420  *
421  * This function sets the speed with which the media file will be played. 1.0
422  * represents the normal speed, 2 double speed, 0.5 half speed and so on.
423  *
424  * @warning The only backend that implements this is the experimental VLC
425  * backend.
426  */
427 EAPI void         emotion_object_play_speed_set        (Evas_Object *obj, double speed);
428 /**
429  * @brief Get  the play speed of the media file.
430  *
431  * @param obj The emotion object from which the filename will be retrieved.
432  * @return The current speed of the media file.
433  *
434  * @see emotion_object_play_speed_set
435  */
436 EAPI double       emotion_object_play_speed_get        (const Evas_Object *obj);
437 /**
438  * @brief Get how much of the file has been played.
439  *
440  * @param obj The emotion object from which the filename will be retrieved.
441  * @return The progress of the media file.
442  *
443  * @warning Don't change of free the returned string.
444  * @warning gstreamer xine backends don't implement this(will return NULL).
445  */
446 EAPI const char  *emotion_object_progress_info_get     (const Evas_Object *obj);
447 /**
448  * @brief Get how much of the file has been played.
449  *
450  * @param obj The emotion object from which the filename will be retrieved
451  * @return The progress of the media file.
452  *
453  * This function gets the progress in playing the file, the return value is in
454  * the [0, 1] range.
455  *
456  * @warning gstreamer xine backends don't implement this(will return 0).
457  */
458 EAPI double       emotion_object_progress_status_get   (const Evas_Object *obj);
459 /**
460  * @}
461  */
462 EAPI Eina_Bool    emotion_object_video_handled_get     (const Evas_Object *obj);
463 EAPI Eina_Bool    emotion_object_audio_handled_get     (const Evas_Object *obj);
464
465 /**
466  * @brief Retrieve the video aspect ratio of the media file loaded.
467  *
468  * @param obj The emotion object which the video aspect ratio will be retrieved
469  * from.
470  * @return The video aspect ratio of the file loaded.
471  *
472  * This function returns the video aspect ratio (width / height) of the file
473  * loaded. It can be used to adapt the size of the emotion object in the canvas,
474  * so the aspect won't be changed (by wrongly resizing the object). Or to crop
475  * the video correctly, if necessary.
476  *
477  * @note This function returns the aspect ratio that the video @b should be, but
478  * sometimes the reported size from emotion_object_size_get() represents a
479  * different aspect ratio. You can safely resize the video to respect the aspect
480  * ratio returned by @b this function.
481  *
482  * @see emotion_object_size_get()
483  *
484  * @ingroup Emotion_Video
485  */
486 EAPI double       emotion_object_ratio_get             (const Evas_Object *obj);
487
488 /**
489  * @brief Retrieve the video size of the loaded file.
490  *
491  * @param obj The object from which we are retrieving the video size.
492  * @param iw A pointer to a variable where the width will be stored.
493  * @param iw A pointer to a variable where the height will be stored.
494  *
495  * This function returns the reported size of the loaded video file. If a file
496  * that doesn't contain a video channel is loaded, then this size can be
497  * ignored.
498  *
499  * The value reported by this function should be consistent with the aspect
500  * ratio returned by emotion_object_ratio_get(), but sometimes the information
501  * stored in the file is wrong. So use the ratio size reported by
502  * emotion_object_ratio_get(), since it is more likely going to be accurate.
503  *
504  * @note Use @c NULL for @p iw or @p ih if you don't need one of these values.
505  *
506  * @see emotion_object_ratio_get()
507  *
508  * @ingroup Emotion_Video
509  */
510 EAPI void         emotion_object_size_get              (const Evas_Object *obj, int *iw, int *ih);
511
512 /**
513  * @brief Sets whether to use of high-quality image scaling algorithm
514  * of the given video object.
515  *
516  * When enabled, a higher quality video scaling algorithm is used when
517  * scaling videos to sizes other than the source video. This gives
518  * better results but is more computationally expensive.
519  *
520  * @param obj The given video object.
521  * @param smooth Whether to use smooth scale or not.
522  *
523  * @see emotion_object_smooth_scale_get()
524  *
525  * @ingroup Emotion_Video
526  */
527 EAPI void         emotion_object_smooth_scale_set      (Evas_Object *obj, Eina_Bool smooth);
528
529 /**
530  * @brief Gets whether the high-quality image scaling algorithm
531  * of the given video object is used.
532  *
533  * @param obj The given video object.
534  * @return Whether the smooth scale is used or not.
535  *
536  * @see emotion_object_smooth_scale_set()
537  *
538  * @ingroup Emotion_Video
539  */
540 EAPI Eina_Bool    emotion_object_smooth_scale_get      (const Evas_Object *obj);
541 EAPI void         emotion_object_event_simple_send     (Evas_Object *obj, Emotion_Event ev);
542
543 /**
544  * @brief Set the audio volume.
545  *
546  * @param obj The object where the volume is being set.
547  * @param vol The new volume parameter. Range is from 0.0 to 1.0.
548  *
549  * Sets the audio volume of the stream being played. This has nothing to do with
550  * the system volume. This volume will be multiplied by the system volume. e.g.:
551  * if the current volume level is 0.5, and the system volume is 50%, it will be
552  * 0.5 * 0.5 = 0.25.
553  *
554  * The default value depends on the module used. This value doesn't get changed
555  * when another file is loaded.
556  *
557  * @see emotion_object_audio_volume_get()
558  *
559  * @ingroup Emotion_Audio
560  */
561 EAPI void         emotion_object_audio_volume_set      (Evas_Object *obj, double vol);
562
563 /**
564  * @brief Get the audio volume.
565  *
566  * @param obj The object from which we are retrieving the volume.
567  * @return The current audio volume level for this object.
568  *
569  * Get the current value for the audio volume level. Range is from 0.0 to 1.0.
570  * This volume is set with emotion_object_audio_volume_set().
571  *
572  * @see emotion_object_audio_volume_set()
573  *
574  * @ingroup Emotion_Audio
575  */
576 EAPI double       emotion_object_audio_volume_get      (const Evas_Object *obj);
577
578 /**
579  * @brief Set the mute audio option for this object.
580  *
581  * @param obj The object which we are setting the mute audio option.
582  * @param mute Whether the audio should be muted (@c EINA_TRUE) or not (@c
583  * EINA_FALSE).
584  *
585  * This function sets the mute audio option for this emotion object. The current
586  * module used for this object can use this to avoid decoding the audio portion
587  * of the loaded media file.
588  *
589  * @see emotion_object_audio_mute_get()
590  * @see emotion_object_video_mute_set()
591  *
592  * @ingroup Emotion_Audio
593  */
594 EAPI void         emotion_object_audio_mute_set        (Evas_Object *obj, Eina_Bool mute);
595
596 /**
597  * @brief Get the mute audio option of this object.
598  *
599  * @param obj The object which we are retrieving the mute audio option from.
600  * @return Whether the audio is muted (@c EINA_TRUE) or not (@c EINA_FALSE).
601  *
602  * This function return the mute audio option from this emotion object. It can
603  * be set with emotion_object_audio_mute_set().
604  *
605  * @see emotion_object_audio_mute_set()
606  *
607  * @ingroup Emotion_Audio
608  */
609 EAPI Eina_Bool    emotion_object_audio_mute_get        (const Evas_Object *obj);
610 EAPI int          emotion_object_audio_channel_count   (const Evas_Object *obj);
611 EAPI const char  *emotion_object_audio_channel_name_get(const Evas_Object *obj, int channel);
612 EAPI void         emotion_object_audio_channel_set     (Evas_Object *obj, int channel);
613 EAPI int          emotion_object_audio_channel_get     (const Evas_Object *obj);
614
615 /**
616  * @brief Set the mute video option for this object.
617  *
618  * @param obj The object which we are setting the mute video option.
619  * @param mute Whether the video should be muted (@c EINA_TRUE) or not (@c
620  * EINA_FALSE).
621  *
622  * This function sets the mute video option for this emotion object. The
623  * current module used for this object can use this information to avoid
624  * decoding the video portion of the loaded media file.
625  *
626  * @see emotion_object_video_mute_get()
627  * @see emotion_object_audio_mute_set()
628  *
629  * @ingroup Emotion_Video
630  */
631 EAPI void         emotion_object_video_mute_set        (Evas_Object *obj, Eina_Bool mute);
632
633 /**
634  * @brief Get the mute video option of this object.
635  *
636  * @param obj The object which we are retrieving the mute video option from.
637  * @return Whether the video is muted (@c EINA_TRUE) or not (@c EINA_FALSE).
638  *
639  * This function returns the mute video option from this emotion object. It can
640  * be set with emotion_object_video_mute_set().
641  *
642  * @see emotion_object_video_mute_set()
643  *
644  * @ingroup Emotion_Video
645  */
646 EAPI Eina_Bool    emotion_object_video_mute_get        (const Evas_Object *obj);
647 EAPI int          emotion_object_video_channel_count   (const Evas_Object *obj);
648 EAPI const char  *emotion_object_video_channel_name_get(const Evas_Object *obj, int channel);
649 EAPI void         emotion_object_video_channel_set     (Evas_Object *obj, int channel);
650 EAPI int          emotion_object_video_channel_get     (const Evas_Object *obj);
651 EAPI void         emotion_object_spu_mute_set          (Evas_Object *obj, Eina_Bool mute);
652 EAPI Eina_Bool    emotion_object_spu_mute_get          (const Evas_Object *obj);
653 EAPI int          emotion_object_spu_channel_count     (const Evas_Object *obj);
654 EAPI const char  *emotion_object_spu_channel_name_get  (const Evas_Object *obj, int channel);
655 EAPI void         emotion_object_spu_channel_set       (Evas_Object *obj, int channel);
656 EAPI int          emotion_object_spu_channel_get       (const Evas_Object *obj);
657 EAPI int          emotion_object_chapter_count         (const Evas_Object *obj);
658 EAPI void         emotion_object_chapter_set           (Evas_Object *obj, int chapter);
659 EAPI int          emotion_object_chapter_get           (const Evas_Object *obj);
660 EAPI const char  *emotion_object_chapter_name_get      (const Evas_Object *obj, int chapter);
661 EAPI void         emotion_object_eject                 (Evas_Object *obj);
662
663 /**
664  * @brief Get the dvd title from this emotion object.
665  *
666  * @param obj The object which the title will be retrieved from.
667  * @return A string containing the title.
668  *
669  * This function is only useful when playing a DVD.
670  *
671  * @note Don't change or free the string returned by this function.
672  *
673  * @ingroup Emotion_Info
674  */
675 EAPI const char  *emotion_object_title_get             (const Evas_Object *obj);
676 EAPI const char  *emotion_object_ref_file_get          (const Evas_Object *obj);
677 EAPI int          emotion_object_ref_num_get           (const Evas_Object *obj);
678 EAPI int          emotion_object_spu_button_count_get  (const Evas_Object *obj);
679 EAPI int          emotion_object_spu_button_get        (const Evas_Object *obj);
680
681 /**
682  * @brief Retrieve meta information from this file being played.
683  *
684  * @param obj The object which the meta info will be extracted from.
685  * @param meta The type of meta information that will be extracted.
686  *
687  * This function retrieves information about the file loaded. It can retrieve
688  * the track title, artist name, album name, etc. See @ref Emotion_Meta_Info
689  * for all the possibilities.
690  *
691  * The meta info may be not available on all types of files. It will return @c
692  * NULL if the the file doesn't have meta info, or if this specific field is
693  * empty.
694  *
695  * @note Don't change or free the string returned by this function.
696  *
697  * @see Emotion_Meta_Info
698  *
699  * @ingroup Emotion_Info
700  */
701 EAPI const char  *emotion_object_meta_info_get         (const Evas_Object *obj, Emotion_Meta_Info meta);
702
703 /**
704  * @brief Set the visualization to be used with this object.
705  *
706  * @param obj The object where the visualization will be set on.
707  * @param visualization The type of visualization to be used.
708  *
709  * The @p visualization specified will be played instead of a video. This is
710  * commonly used to display a visualization for audio only files (musics).
711  *
712  * The available visualizations are @ref Emotion_Vis.
713  *
714  * @see Emotion_Vis
715  * @see emotion_object_vis_get()
716  * @see emotion_object_vis_supported()
717  *
718  * @ingroup Emotion_Visualization
719  */
720 EAPI void         emotion_object_vis_set               (Evas_Object *obj, Emotion_Vis visualization);
721
722 /**
723  * @brief Get the type of visualization in use by this emotion object.
724  *
725  * @param obj The emotion object which the visualization is being retrieved
726  * from.
727  * @return The type of visualization in use by this object.
728  *
729  * The type of visualization can be set by emotion_object_vis_set().
730  *
731  * @see Emotion_Vis
732  * @see emotion_object_vis_set()
733  * @see emotion_object_vis_supported()
734  *
735  * @ingroup Emotion_Visualization
736  */
737 EAPI Emotion_Vis  emotion_object_vis_get               (const Evas_Object *obj);
738
739 /**
740  * @brief Query whether a type of visualization is supported by this object.
741  *
742  * @param obj The object which the query is being ran on.
743  * @param visualization The type of visualization that is being queried.
744  * @return EINA_TRUE if the visualization is supported, EINA_FALSE otherwise.
745  *
746  * This can be used to check if a visualization is supported. e.g.: one wants to
747  * display a list of available visualizations for a specific object.
748  *
749  * @see Emotion_Vis
750  * @see emotion_object_vis_set()
751  * @see emotion_object_vis_get()
752  *
753  * @ingroup Emotion_Visualization
754  */
755 EAPI Eina_Bool    emotion_object_vis_supported         (const Evas_Object *obj, Emotion_Vis visualization);
756
757 EAPI void         emotion_object_last_position_load    (Evas_Object *obj);
758 EAPI void         emotion_object_last_position_save    (Evas_Object *obj);
759
760 EAPI void         emotion_object_suspend_set           (Evas_Object *obj, Emotion_Suspend state);
761 EAPI Emotion_Suspend emotion_object_suspend_get        (Evas_Object *obj);
762
763 EAPI Eina_Bool    emotion_object_extension_can_play_get(const Evas_Object *obj, const char *file);
764 EAPI Eina_Bool    emotion_object_extension_can_play_fast_get(const Evas_Object *obj, const char *file);
765
766 EAPI Eina_Bool    emotion_object_extension_may_play_fast_get(const char *file);
767 EAPI Eina_Bool    emotion_object_extension_may_play_get(const char *file);
768
769 /**
770  * @}
771  */
772
773 #ifdef __cplusplus
774 }
775 #endif
776
777 #endif