[vlc-commits] vlc_subpicture: document callbacks
Francois Cartegnie
git at videolan.org
Wed Jan 11 22:50:57 CET 2017
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed Jan 11 14:01:35 2017 +0100| [2b5daf2ce769b0328606ae236304ed5adab07f18] | committer: Francois Cartegnie
vlc_subpicture: document callbacks
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=2b5daf2ce769b0328606ae236304ed5adab07f18
---
include/vlc_subpicture.h | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/include/vlc_subpicture.h b/include/vlc_subpicture.h
index c87bbd5..aa2ed0d 100644
--- a/include/vlc_subpicture.h
+++ b/include/vlc_subpicture.h
@@ -118,14 +118,21 @@ VLC_API subpicture_region_t *subpicture_region_Copy( subpicture_region_t *p_regi
typedef struct subpicture_updater_sys_t subpicture_updater_sys_t;
typedef struct
{
+ /** Optional pre update callback, usually useful on video format change.
+ * Will skip pf_update on VLC_SUCCESS, or will delete every region before
+ * the call to pf_update */
int (*pf_validate)( subpicture_t *,
bool has_src_changed, const video_format_t *p_fmt_src,
bool has_dst_changed, const video_format_t *p_fmt_dst,
mtime_t);
+ /** Mandatory callback called after pf_validate and doing
+ * the main job of creating the subpicture regions for the
+ * current video_format */
void (*pf_update) ( subpicture_t *,
const video_format_t *p_fmt_src,
const video_format_t *p_fmt_dst,
mtime_t );
+ /** Optional callback for subpicture private data cleanup */
void (*pf_destroy) ( subpicture_t * );
subpicture_updater_sys_t *p_sys;
} subpicture_updater_t;
More information about the vlc-commits
mailing list