summaryrefslogtreecommitdiffstats
path: root/stream/stream_radio.c
diff options
context:
space:
mode:
authorvoroshil <voroshil@b3059339-0415-0410-9bf9-f77b7e298cf2>2007-04-11 05:39:09 +0000
committervoroshil <voroshil@b3059339-0415-0410-9bf9-f77b7e298cf2>2007-04-11 05:39:09 +0000
commitfe5f586f118cfaf9a904834015ea4b811c2999e0 (patch)
tree3307599691f43a9cd86a93421eaf4c98eece35d9 /stream/stream_radio.c
parent6b925eca4f9821f300603de179ebab617b9a3c5b (diff)
downloadmpv-fe5f586f118cfaf9a904834015ea4b811c2999e0.tar.bz2
mpv-fe5f586f118cfaf9a904834015ea4b811c2999e0.tar.xz
Rework of *BSD BT848 detection for radio://
to reuse recently added BT848 interface headers detection code. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@22966 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'stream/stream_radio.c')
-rw-r--r--stream/stream_radio.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/stream/stream_radio.c b/stream/stream_radio.c
index eb87c117a3..2a3e36d515 100644
--- a/stream/stream_radio.c
+++ b/stream/stream_radio.c
@@ -34,11 +34,13 @@
#include <errno.h>
#include <unistd.h>
-#ifdef RADIO_BSDBT848_HDR
+#ifdef HAVE_RADIO_BSDBT848
#include <sys/param.h>
-#include RADIO_BSDBT848_HDR
+#ifdef IOCTL_BT848_H_NAME
+#include IOCTL_BT848_H_NAME
+#endif
-#else // RADIO_BSDBT848_HDR
+#else // HAVE_RADIO_BSDBT848
#include <linux/types.h>
@@ -51,7 +53,7 @@
#warning "V4L is deprecated and will be removed in future"
#endif
-#endif // !RADIO_BSDBT848_HDR
+#endif // !IOCTL_BT848_H_NAME
#include "stream.h"
@@ -85,7 +87,7 @@ typedef struct radio_channels_s {
struct radio_channels_s * prev;
} radio_channels_t;
-#ifdef RADIO_BSDBT848_HDR
+#ifdef HAVE_RADIO_BSDBT848
/** (device,string, "/dev/tuner0") name of radio device file */
char* radio_param_device="/dev/tuner0";
/** radio_param_freq_min (freq_min,float,87.5) minimal allowed frequency */
@@ -552,7 +554,8 @@ static const radio_driver_t radio_driver_v4l={
get_frequency_v4l
};
#endif //HAVE_RADIO_V4L
-#ifdef RADIO_BSDBT848_HDR
+#ifdef HAVE_RADIO_BSDBT848
+
/*****************************************************************
* \brief get fraction value for using in set_frequency and get_frequency
* \return STREAM_OK if success, STREAM_ERROR otherwise
@@ -662,7 +665,7 @@ static const radio_driver_t radio_driver_bsdbt848={
set_frequency_bsdbt848,
get_frequency_bsdbt848
};
-#endif //RADIO_BSDBT848_HDR
+#endif //HAVE_RADIO_BSDBT848
static inline int init_frac(radio_priv_t* priv){
return priv->driver->init_frac(priv);
@@ -1087,7 +1090,7 @@ static int fill_buffer_s(struct stream_st *s, char* buffer, int max_len){
when no driver explicitly specified first available will be used
*/
static const radio_driver_t* radio_drivers[]={
-#ifdef RADIO_BSDBT848_HDR
+#ifdef HAVE_RADIO_BSDBT848
&radio_driver_bsdbt848,
#endif
#ifdef HAVE_RADIO_V4L2