]> git.sesse.net Git - vlc/blobdiff - include/vlc/libvlc_media_player.h
Add libvlc_set_exit_handler(), more powerful than libvlc_wait()
[vlc] / include / vlc / libvlc_media_player.h
index 3bbb6b9b489e206a07ef4f2b6ad84e210ab68c68..fb7b05b6dc4f3d11a19d88a6f804457b6214134d 100644 (file)
@@ -193,8 +193,10 @@ VLC_PUBLIC_API void libvlc_media_player_stop ( libvlc_media_player_t *p_mi );
 /**
  * Set the NSView handler where the media player should render its video output.
  *
- * The object minimal_macosx expects is of kind NSObject and should
- * respect the protocol:
+ * Use the vout called "macosx".
+ *
+ * The drawable is an NSObject that follow the VLCOpenGLVideoViewEmbedding
+ * protocol:
  *
  * @begincode
  * \@protocol VLCOpenGLVideoViewEmbedding <NSObject>
@@ -203,10 +205,24 @@ VLC_PUBLIC_API void libvlc_media_player_stop ( libvlc_media_player_t *p_mi );
  * \@end
  * @endcode
  *
+ * Or it can be an NSView object.
+ *
+ * If you want to use it along with Qt4 see the QMacCocoaViewContainer. Then
+ * the following code should work:
+ * @begincode
+ * {
+ *     NSView *video = [[NSView alloc] init];
+ *     QMacCocoaViewContainer *container = new QMacCocoaViewContainer(video, parent);
+ *     libvlc_media_player_set_nsobject(mp, video);
+ *     [video release];
+ * }
+ * @endcode
+ *
  * You can find a live example in VLCVideoView in VLCKit.framework.
  *
  * \param p_mi the Media Player
- * \param drawable the NSView handler
+ * \param drawable the drawable that is either an NSView or an object following
+ * the VLCOpenGLVideoViewEmbedding protocol.
  */
 VLC_PUBLIC_API void libvlc_media_player_set_nsobject ( libvlc_media_player_t *p_mi, void * drawable );
 
@@ -433,6 +449,7 @@ VLC_PUBLIC_API int libvlc_media_player_set_rate( libvlc_media_player_t *p_mi, fl
  * Get current movie state
  *
  * \param p_mi the Media Player
+ * \return the current state of the media player (playing, paused, ...) \see libvlc_state_t
  */
 VLC_PUBLIC_API libvlc_state_t libvlc_media_player_get_state( libvlc_media_player_t *p_mi );
 
@@ -458,6 +475,7 @@ VLC_PUBLIC_API unsigned libvlc_media_player_has_vout( libvlc_media_player_t *p_m
  * Is this media player seekable?
  *
  * \param p_mi the media player
+ * \return true if the media player can seek
  */
 VLC_PUBLIC_API int libvlc_media_player_is_seekable( libvlc_media_player_t *p_mi );
 
@@ -465,6 +483,7 @@ VLC_PUBLIC_API int libvlc_media_player_is_seekable( libvlc_media_player_t *p_mi
  * Can this media player be paused?
  *
  * \param p_mi the media player
+ * \return true if the media player can pause
  */
 VLC_PUBLIC_API int libvlc_media_player_can_pause( libvlc_media_player_t *p_mi );