From acce4eff134b7bd78bb85aa1fc77a7ac465a47cf Mon Sep 17 00:00:00 2001 From: voroshil Date: Fri, 17 Nov 2006 14:36:13 +0000 Subject: add public wrapper for get_frequency git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@20984 b3059339-0415-0410-9bf9-f77b7e298cf2 --- stream/stream_radio.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'stream/stream_radio.c') diff --git a/stream/stream_radio.c b/stream/stream_radio.c index ad8ad5a1fe..6010bf12f3 100644 --- a/stream/stream_radio.c +++ b/stream/stream_radio.c @@ -806,6 +806,21 @@ static int init_audio(radio_priv_t *priv) /*------------------------------------------------------------------------- for call from mplayer.c --------------------------------------------------------------------------*/ +/***************************************************************** + * \brief public wrapper for get_frequency + * \parameter frequency pointer to float, which will contain frequency in MHz + * \return 1 if success,0 - otherwise + */ +int radio_get_freq(struct stream_st *stream, float* frequency){ + radio_priv_t* priv=(radio_priv_t*)stream->priv; + + if (!frequency) + return 0; + if (get_frequency(priv,frequency)!=STREAM_OK){ + return 0; + } + return 1; +} /***************************************************************** * \brief public wrapper for set_frequency * \parameter frequency frequency in MHz -- cgit v1.2.3