]> git.sesse.net Git - vlc/blobdiff - include/vlc_vout.h
Qt: Sout strings modification.
[vlc] / include / vlc_vout.h
index c322288805c40bd397e7c27a96163f08294b76f8..36b4b11de28c1f47e8d1572b75c0963321d0aa8c 100644 (file)
@@ -208,6 +208,21 @@ static inline void picture_Copy( picture_t *p_dst, const picture_t *p_src )
     picture_CopyProperties( p_dst, p_src );
 }
 
+/**
+ * This function will export a picture to an encoded bitstream.
+ *
+ * pp_image will contain the encoded bitstream in psz_format format.
+ *
+ * p_fmt can be NULL otherwise it will be set with the format used for the
+ * picture before encoding.
+ *
+ * i_override_width/height allow to override the width and/or the height of the
+ * picture to be encoded. If at most one of them is > 0 then the picture aspect
+ * ratio will be kept.
+ */
+VLC_EXPORT( int, picture_Export, ( vlc_object_t *p_obj, block_t **pp_image, video_format_t *p_fmt, picture_t *p_picture, vlc_fourcc_t i_format, int i_override_width, int i_override_height ) );
+
+
 /**
  * Video picture heap, either render (to store pictures used
  * by the decoder) or output (to store pictures displayed by the vout plugin)
@@ -668,6 +683,23 @@ static inline void vout_CloseAndRelease( vout_thread_t *p_vout )
     vlc_object_release( p_vout );
 }
 
+/**
+ * This function will handle a snapshot request.
+ *
+ * pp_image, pp_picture and p_fmt can be NULL otherwise they will be
+ * set with returned value in case of success.
+ *
+ * pp_image will hold an encoded picture in psz_format format.
+ *
+ * i_timeout specifies the time the function will wait for a snapshot to be
+ * available.
+ *
+ */
+VLC_EXPORT( int, vout_GetSnapshot, ( vout_thread_t *p_vout,
+                                     block_t **pp_image, picture_t **pp_picture,
+                                     video_format_t *p_fmt,
+                                     const char *psz_format, mtime_t i_timeout ) );
+
 /* */
 VLC_EXPORT( int,             vout_ChromaCmp,      ( uint32_t, uint32_t ) );
 
@@ -711,17 +743,6 @@ enum output_query_e
     VOUT_REDRAW_RECT,       /* arg1= area rect, res= */
 };
 
-typedef struct snapshot_t {
-  char *p_data;  /* Data area */
-
-  int i_width;       /* In pixels */
-  int i_height;      /* In pixels */
-  int i_datasize;    /* In bytes */
-  mtime_t date;      /* Presentation time */
-  vlc_cond_t p_condvar;
-  vlc_mutex_t p_mutex;
-} snapshot_t;
-
 /**@}*/
 
 #endif /* _VLC_VIDEO_H */