diff options
author | voroshil <voroshil@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2007-07-29 12:20:25 +0000 |
---|---|---|
committer | voroshil <voroshil@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2007-07-29 12:20:25 +0000 |
commit | 61bce335f7d0fc56a50200a4e47fe743aa5c0aaf (patch) | |
tree | 4464b8cab6d9328cb1890c74974613c9a931cc1d /stream/stream_radio.h | |
parent | db734dcc1591533da1adc9222ddb801c2da570fc (diff) | |
download | mpv-61bce335f7d0fc56a50200a4e47fe743aa5c0aaf.tar.bz2 mpv-61bce335f7d0fc56a50200a4e47fe743aa5c0aaf.tar.xz |
Replacing global variables in radio:// with
context-sensitive structure.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23910 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'stream/stream_radio.h')
-rw-r--r-- | stream/stream_radio.h | 38 |
1 files changed, 28 insertions, 10 deletions
diff --git a/stream/stream_radio.h b/stream/stream_radio.h index e2a6cd0648..c04ec48483 100644 --- a/stream/stream_radio.h +++ b/stream/stream_radio.h @@ -4,17 +4,35 @@ #define RADIO_CHANNEL_LOWER 1 #define RADIO_CHANNEL_HIGHER 2 -extern char *radio_param_device; -extern char *radio_param_driver; -#ifdef RADIO_BSDBT848_HDR -extern float radio_param_freq_min; -extern float radio_param_freq_max; +typedef struct radio_param_s{ + /** name of radio device file */ + char* device; +#ifdef HAVE_RADIO_BSDBT848 + /** minimal allowed frequency */ + float freq_min; + /** maximal allowed frequency */ + float freq_max; #endif -extern char **radio_param_channels; -extern int radio_param_volume; -extern char* radio_param_adevice; -extern int radio_param_arate; -extern int radio_param_achannels; + /** radio driver (v4l,v4l2) */ + char* driver; + /** channels list (see man page) */ + char** channels; + /** initial volume for radio device */ + int volume; + /** name of audio device file to grab data from */ + char* adevice; + /** audio framerate (please also set -rawaudio rate + parameter to the same value) */ + int arate; + /** number of audio channels */ + int achannels; + /** if channels parameter exist, here will be channel + number otherwise - frequency */ + float freq_channel; + char* capture; +} radio_param_t; + +extern radio_param_t stream_radio_defaults; int radio_set_freq(struct stream_st *stream, float freq); int radio_get_freq(struct stream_st *stream, float* freq); |