/*****************************************************************************
* libvlc.h: libvlc external API
*****************************************************************************
- * Copyright (C) 1998-2005 the VideoLAN team
+ * Copyright (C) 1998-2009 the VideoLAN team
* $Id$
*
* Authors: Clément Stenac <zorglub@videolan.org>
*/
VLC_PUBLIC_API void libvlc_media_player_stop ( libvlc_media_player_t *, libvlc_exception_t * );
+/**
+ * Set the agl handler where the media player should render its video output.
+ *
+ * \param p_mi the Media Player
+ * \param drawable the agl handler
+ * \param p_e an initialized exception pointer
+ */
+VLC_PUBLIC_API void libvlc_media_player_set_nsobject ( libvlc_media_player_t *p_mi, void * drawable, libvlc_exception_t *p_e );
+
+/**
+ * Get the agl handler previously set with libvlc_media_player_set_agl().
+ *
+ * \return the agl handler or 0 if none where set
+ */
+VLC_PUBLIC_API uint32_t libvlc_media_player_get_nsobject ( libvlc_media_player_t *p_mi );
+
/**
* Set the agl handler where the media player should render its video output.
*
*/
VLC_PUBLIC_API int libvlc_video_get_width( libvlc_media_player_t *, libvlc_exception_t * );
+/**
+ * Get the current video scaling factor.
+ * See also libvlc_video_set_scale().
+ *
+ * \param p_mediaplayer the media player
+ * \return the currently configured zoom factor, or 0. if the video is set
+ * to fit to the output window/drawable automatically.
+ */
+VLC_PUBLIC_API float libvlc_video_get_scale( libvlc_media_player_t *,
+ libvlc_exception_t *p_e );
+
+/**
+ * Set the video scaling factor. That is the ratio of the number of pixels on
+ * screen to the number of pixels in the original decoded video in each
+ * dimension. Zero is a special value; it will adjust the video to the output
+ * window/drawable (in windowed mode) or the entire screen.
+ *
+ * Note that not all video outputs support scaling.
+ *
+ * \param p_mediaplayer the media player
+ * \param i_factor the scaling factor, or zero
+ */
+VLC_PUBLIC_API void libvlc_video_set_scale( libvlc_media_player_t *, float,
+ libvlc_exception_t *p_e );
+
/**
* Get current video aspect ratio.
*
* If i_width AND i_height is 0, original size is used.
* If i_width XOR i_height is 0, original aspect-ratio is preserved.
*
- * \param p_mediaplayer the media player
+ * \param p_mi media player instance
* \param psz_filepath the path where to save the screenshot to
* \param i_width the snapshot's width
* \param i_height the snapshot's height
* \param p_e an initialized exception pointer
*/
-VLC_PUBLIC_API void libvlc_video_take_snapshot( libvlc_media_player_t *, char *,unsigned int, unsigned int, libvlc_exception_t * );
+VLC_PUBLIC_API void libvlc_video_take_snapshot( libvlc_media_player_t *, const char *,unsigned int, unsigned int, libvlc_exception_t * );
/**
* Resize the current video output window.
*
- * \param p_instance libvlc instance
+ * \param p_mi media player instance
* \param width new width for video output window
* \param height new height for video output window
* \param p_e an initialized exception pointer
/**
* Tell windowless video output to redraw rectangular area (MacOS X only).
*
- * \param p_instance libvlc instance
+ * \param p_mi media player instance
* \param area coordinates within video drawable
* \param p_e an initialized exception pointer
*/
* This setting will be used as default for all video outputs.
*
* \param p_instance libvlc instance
+ * \param p_mi media player instance
* \param view coordinates within video drawable
* \param clip coordinates within video drawable
* \param p_e an initialized exception pointer
*/
-VLC_PUBLIC_API void libvlc_video_set_viewport( libvlc_instance_t *, const libvlc_rectangle_t *, const libvlc_rectangle_t *, libvlc_exception_t * );
+VLC_PUBLIC_API void libvlc_video_set_viewport( libvlc_instance_t *, libvlc_media_player_t *, const libvlc_rectangle_t *, const libvlc_rectangle_t *, libvlc_exception_t * );
/** @} video */