diff stream/stream_radio.c @ 20968:1e6ebb9e49eb

add public wrapper for get_frequency
author voroshil
date Fri, 17 Nov 2006 14:36:13 +0000
parents 460da4c85cb4
children 20110e4437c6
line wrap: on
line diff
--- a/stream/stream_radio.c	Fri Nov 17 13:42:46 2006 +0000
+++ b/stream/stream_radio.c	Fri Nov 17 14:36:13 2006 +0000
@@ -807,6 +807,21 @@
  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
  * \return 1 if success,0 - otherwise