[vlc-devel] commit: Added input_DecoderGetFifoSize helper. (Laurent Aimar )

git version control git at videolan.org
Thu Jul 16 21:23:54 CEST 2009


vlc | branch: master | Laurent Aimar <fenrir at videolan.org> | Thu Jul 16 14:49:02 2009 +0200| [43aab2462d7b1d9c9fc9aa7eb51af25320bf09d7] | committer: Laurent Aimar 

Added input_DecoderGetFifoSize helper.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=43aab2462d7b1d9c9fc9aa7eb51af25320bf09d7
---

 src/input/decoder.c |    7 +++++++
 src/input/decoder.h |    5 +++++
 2 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/src/input/decoder.c b/src/input/decoder.c
index b740580..34f8831 100644
--- a/src/input/decoder.c
+++ b/src/input/decoder.c
@@ -620,6 +620,13 @@ bool input_DecoderHasFormatChanged( decoder_t *p_dec, es_format_t *p_fmt, vlc_me
     return b_changed;
 }
 
+size_t input_DecoderGetFifoSize( decoder_t *p_dec )
+{
+    decoder_owner_sys_t *p_owner = p_dec->p_owner;
+
+    return block_FifoSize( p_owner->p_fifo );
+}
+
 /*****************************************************************************
  * Internal functions
  *****************************************************************************/
diff --git a/src/input/decoder.h b/src/input/decoder.h
index d47119d..fe99b42 100644
--- a/src/input/decoder.h
+++ b/src/input/decoder.h
@@ -99,4 +99,9 @@ void input_DecoderFrameNext( decoder_t *p_dec, mtime_t *pi_duration );
  */
 bool input_DecoderHasFormatChanged( decoder_t *p_dec, es_format_t *p_fmt, vlc_meta_t **pp_meta );
 
+/**
+ * This function returns the current size in bytes of the decoder fifo
+ */
+size_t input_DecoderGetFifoSize( decoder_t *p_dec );
+
 #endif




More information about the vlc-devel mailing list