[vlc-commits] input/stream: add STREAM_GET_SIGNAL (fixes #8414)
Rémi Denis-Courmont
git at videolan.org
Wed Apr 17 23:11:41 CEST 2013
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Apr 18 00:00:10 2013 +0300| [57fe6b36d55fade84a77ebe7fdee089eb95b5332] | committer: Rémi Denis-Courmont
input/stream: add STREAM_GET_SIGNAL (fixes #8414)
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=57fe6b36d55fade84a77ebe7fdee089eb95b5332
---
include/vlc_stream.h | 1 +
src/input/input.c | 2 +-
src/input/stream.c | 2 ++
src/input/stream_demux.c | 1 +
src/input/stream_memory.c | 1 +
5 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/include/vlc_stream.h b/include/vlc_stream.h
index 400a75f..f77a843 100644
--- a/include/vlc_stream.h
+++ b/include/vlc_stream.h
@@ -112,6 +112,7 @@ enum stream_query_e
STREAM_GET_TITLE_INFO = 0x102, /**< arg1=input_title_t*** arg2=int* res=can fail */
STREAM_GET_META, /**< arg1= vlc_meta_t ** res=can fail */
STREAM_GET_CONTENT_TYPE, /**< arg1= char ** res=can fail */
+ STREAM_GET_SIGNAL, /**< arg1=double *pf_quality, arg2=double *pf_strength res=can fail */
STREAM_SET_PAUSE_STATE = 0x200, /**< arg1= bool res=can fail */
STREAM_SET_TITLE, /**< arg1= int res=can fail */
diff --git a/src/input/input.c b/src/input/input.c
index 37f57e6..be1959a 100644
--- a/src/input/input.c
+++ b/src/input/input.c
@@ -2287,7 +2287,7 @@ static void UpdateGenericFromAccess( input_thread_t *p_input )
double f_quality;
double f_strength;
- if( access_Control( p_access, ACCESS_GET_SIGNAL, &f_quality, &f_strength ) )
+ if( stream_Control( p_stream, STREAM_GET_SIGNAL, &f_quality, &f_strength ) )
f_quality = f_strength = -1;
input_SendEventSignal( p_input, f_quality, f_strength );
diff --git a/src/input/stream.c b/src/input/stream.c
index 2f5022d..4718f70 100644
--- a/src/input/stream.c
+++ b/src/input/stream.c
@@ -616,6 +616,8 @@ static int AStreamControl( stream_t *s, int i_query, va_list args )
return access_vaControl( p_access, ACCESS_GET_META, args );
case STREAM_GET_CONTENT_TYPE:
return access_vaControl( p_access, ACCESS_GET_CONTENT_TYPE, args );
+ case STREAM_GET_SIGNAL:
+ return access_vaControl( p_access, ACCESS_GET_SIGNAL, args );
case STREAM_SET_PAUSE_STATE:
return access_vaControl( p_access, ACCESS_SET_PAUSE_STATE, args );
diff --git a/src/input/stream_demux.c b/src/input/stream_demux.c
index 12882f6..01d251c 100644
--- a/src/input/stream_demux.c
+++ b/src/input/stream_demux.c
@@ -300,6 +300,7 @@ static int DStreamControl( stream_t *s, int i_query, va_list args )
case STREAM_GET_TITLE_INFO:
case STREAM_GET_META:
case STREAM_GET_CONTENT_TYPE:
+ case STREAM_GET_SIGNAL:
case STREAM_SET_PAUSE_STATE:
case STREAM_SET_TITLE:
case STREAM_SET_SEEKPOINT:
diff --git a/src/input/stream_memory.c b/src/input/stream_memory.c
index fed59a7..87b7f1b 100644
--- a/src/input/stream_memory.c
+++ b/src/input/stream_memory.c
@@ -125,6 +125,7 @@ static int Control( stream_t *s, int i_query, va_list args )
case STREAM_GET_TITLE_INFO:
case STREAM_GET_META:
case STREAM_GET_CONTENT_TYPE:
+ case STREAM_GET_SIGNAL:
case STREAM_SET_TITLE:
case STREAM_SET_SEEKPOINT:
return VLC_EGENERIC;
More information about the vlc-commits
mailing list