[vlc-commits] commit: Added video_format_Print. (Laurent Aimar )
git at videolan.org
git at videolan.org
Wed May 12 20:20:07 CEST 2010
vlc | branch: master | Laurent Aimar <fenrir at videolan.org> | Tue May 11 21:14:07 2010 +0200| [0ae5c1cda4da2498e86ec182b7a52542c740030c] | committer: Laurent Aimar
Added video_format_Print.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=0ae5c1cda4da2498e86ec182b7a52542c740030c
---
include/vlc_es.h | 5 +++++
src/libvlccore.sym | 1 +
src/misc/es_format.c | 12 ++++++++++++
src/video_output/video_output.c | 19 +------------------
4 files changed, 19 insertions(+), 18 deletions(-)
diff --git a/include/vlc_es.h b/include/vlc_es.h
index 3d1ec2f..556b414 100644
--- a/include/vlc_es.h
+++ b/include/vlc_es.h
@@ -179,6 +179,11 @@ VLC_EXPORT( void, video_format_Setup, ( video_format_t *, vlc_fourcc_t i_chroma,
VLC_EXPORT( bool, video_format_IsSimilar, ( const video_format_t *, const video_format_t * ) );
/**
+ * It prints details about the given video_format_t
+ */
+VLC_EXPORT( void, video_format_Print, ( vlc_object_t *, const char *, const video_format_t * ) );
+
+/**
* subtitles format description
*/
struct subs_format_t
diff --git a/src/libvlccore.sym b/src/libvlccore.sym
index ffb933a..79f3213 100644
--- a/src/libvlccore.sym
+++ b/src/libvlccore.sym
@@ -468,6 +468,7 @@ var_Inherit
video_format_FixRgb
video_format_IsSimilar
video_format_Setup
+video_format_Print
video_splitter_Delete
video_splitter_New
vlc_avcodec_mutex
diff --git a/src/misc/es_format.c b/src/misc/es_format.c
index 3c37f4f..9864a0f 100644
--- a/src/misc/es_format.c
+++ b/src/misc/es_format.c
@@ -237,6 +237,18 @@ bool video_format_IsSimilar( const video_format_t *p_fmt1, const video_format_t
}
return true;
}
+void video_format_Print( vlc_object_t *p_this,
+ const char *psz_text, const video_format_t *fmt )
+{
+ msg_Dbg( p_this,
+ "%s sz %ix%i, of (%i,%i), vsz %ix%i, 4cc %4.4s, sar %i:%i, msk r0x%x g0x%x b0x%x",
+ psz_text,
+ fmt->i_width, fmt->i_height, fmt->i_x_offset, fmt->i_y_offset,
+ fmt->i_visible_width, fmt->i_visible_height,
+ (char*)&fmt->i_chroma,
+ fmt->i_sar_num, fmt->i_sar_den,
+ fmt->i_rmask, fmt->i_gmask, fmt->i_bmask );
+}
void es_format_Init( es_format_t *fmt,
int i_cat, vlc_fourcc_t i_codec )
diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
index 492c576..d4ed3ae 100644
--- a/src/video_output/video_output.c
+++ b/src/video_output/video_output.c
@@ -64,9 +64,6 @@ static int FilterCallback( vlc_object_t *, char const *,
static int VideoFilter2Callback( vlc_object_t *, char const *,
vlc_value_t, vlc_value_t, void * );
-/* */
-static void PrintVideoFormat(vout_thread_t *, const char *, const video_format_t *);
-
/* Maximum delay between 2 displayed pictures.
* XXX it is needed for now but should be removed in the long term.
*/
@@ -991,7 +988,7 @@ static int ThreadInit(vout_thread_t *vout)
vout->p->displayed.decoded = NULL;
- PrintVideoFormat(vout, "original format", &vout->p->original);
+ video_format_Print(VLC_OBJECT(vout), "original format", &vout->p->original);
return VLC_SUCCESS;
}
@@ -1154,17 +1151,3 @@ static int VideoFilter2Callback(vlc_object_t *object, char const *cmd,
return VLC_SUCCESS;
}
-/* */
-static void PrintVideoFormat(vout_thread_t *vout,
- const char *description,
- const video_format_t *fmt)
-{
- msg_Dbg(vout, "%s sz %ix%i, of (%i,%i), vsz %ix%i, 4cc %4.4s, sar %i:%i, msk r0x%x g0x%x b0x%x",
- description,
- fmt->i_width, fmt->i_height, fmt->i_x_offset, fmt->i_y_offset,
- fmt->i_visible_width, fmt->i_visible_height,
- (char*)&fmt->i_chroma,
- fmt->i_sar_num, fmt->i_sar_den,
- fmt->i_rmask, fmt->i_gmask, fmt->i_bmask);
-}
-
More information about the vlc-commits
mailing list