Mercurial > mplayer.hg
comparison stream/tvi_bsdbt848.c @ 22934:da61a88adf63
remove ugly #include from tvi_bsdbt848.c
(better detection of bt848 headers)
author | voroshil |
---|---|
date | Mon, 09 Apr 2007 13:18:06 +0000 |
parents | b5b63e82bb3e |
children | c51b95236413 |
comparison
equal
deleted
inserted
replaced
22933:b99c2feda3eb | 22934:da61a88adf63 |
---|---|
36 #include <sys/time.h> | 36 #include <sys/time.h> |
37 #include <signal.h> | 37 #include <signal.h> |
38 #include <string.h> | 38 #include <string.h> |
39 | 39 |
40 #include <sys/param.h> | 40 #include <sys/param.h> |
41 #ifdef __NetBSD__ | 41 #ifdef USE_SUN_AUDIO |
42 #include <dev/ic/bt8xx.h> | |
43 #include <sys/audioio.h> | 42 #include <sys/audioio.h> |
44 #elif defined(__DragonFly__) | 43 #endif |
45 #include <dev/video/meteor/ioctl_meteor.h> | 44 |
46 #include <dev/video/bktr/ioctl_bt848.h> | 45 #ifdef IOCTL_METEOR_H_NAME |
47 #elif (__FreeBSD_version >= 502100) || defined(__FreeBSD_kernel__) | 46 #include IOCTL_METEOR_H_NAME |
48 #include <dev/bktr/ioctl_meteor.h> | 47 #endif |
49 #include <dev/bktr/ioctl_bt848.h> | 48 |
50 #else | 49 #ifdef IOCTL_BT848_H_NAME |
51 #include <machine/ioctl_meteor.h> | 50 #include IOCTL_BT848_H_NAME |
52 #include <machine/ioctl_bt848.h> | |
53 #endif | 51 #endif |
54 | 52 |
55 #ifdef HAVE_SYS_SOUNDCARD_H | 53 #ifdef HAVE_SYS_SOUNDCARD_H |
56 #include <sys/soundcard.h> | 54 #include <sys/soundcard.h> |
57 #else | 55 #else |
202 } | 200 } |
203 } | 201 } |
204 | 202 |
205 /* set audio device name */ | 203 /* set audio device name */ |
206 if (!adevice) | 204 if (!adevice) |
207 #ifdef __NetBSD__ | 205 #ifdef USE_SUN_AUDIO |
208 priv->dspdev = strdup("/dev/sound"); | 206 priv->dspdev = strdup("/dev/sound"); |
209 #else | 207 #else |
210 priv->dspdev = strdup("/dev/dsp"); | 208 priv->dspdev = strdup("/dev/dsp"); |
211 #endif | 209 #endif |
212 else | 210 else |
832 } | 830 } |
833 | 831 |
834 static int get_audio_framesize(priv_t *priv) | 832 static int get_audio_framesize(priv_t *priv) |
835 { | 833 { |
836 int bytesavail; | 834 int bytesavail; |
837 #ifdef __NetBSD__ | 835 #ifdef USE_SUN_AUDIO |
838 struct audio_info auinf; | 836 struct audio_info auinf; |
839 #endif | 837 #endif |
840 | 838 |
841 if(priv->dspready == FALSE) return 0; | 839 if(priv->dspready == FALSE) return 0; |
842 | 840 |
843 #ifdef __NetBSD__ | 841 #ifdef USE_SUN_AUDIO |
844 if(ioctl(priv->dspfd, AUDIO_GETINFO, &auinf) < 0) | 842 if(ioctl(priv->dspfd, AUDIO_GETINFO, &auinf) < 0) |
845 { | 843 { |
846 perror("AUDIO_GETINFO"); | 844 perror("AUDIO_GETINFO"); |
847 return(TVI_CONTROL_FALSE); | 845 return(TVI_CONTROL_FALSE); |
848 } | 846 } |