[MPlayer-dev-eng] BSD BT848 Radio interface (patch)

Diego Biurrun diego at biurrun.de
Thu Nov 9 15:06:11 CET 2006


On Thu, Nov 09, 2006 at 07:36:17PM +0600, Vladimir Voroshilov wrote:
> I have made new version of bsdbt848 patch.
> Notes:
> Removed code related to mixer (currently, stream_radio's *_volume
> functions   control volume level
> of radio card only).
> Initialization of constants (frequency range and factor) moved to
> init_frac_bsdbt848.
> 
> Please, anybody test it (i haven't bt848).
> 
> --- stream/stream_radio.c	(revision 20812)
> +++ stream/stream_radio.c	(working copy)
> @@ -33,6 +33,22 @@
>  #include <sys/ioctl.h>
>  #include <errno.h>
>  #include <unistd.h>
> +
> +#ifdef HAVE_RADIO_BSDBT848
> +#include <sys/param.h>
> +#if defined(__DragonFly__)
> +#include <dev/video/meteor/ioctl_meteor.h>
> +#include <dev/video/bktr/ioctl_bt848.h>
> +#elif __FreeBSD_version >= 502100
> +#include <dev/bktr/ioctl_meteor.h>
> +#include <dev/bktr/ioctl_bt848.h>
> +#else
> +#include <machine/ioctl_meteor.h>
> +#include <machine/ioctl_bt848.h>
> +#endif

This is very ugly.

> --- configure	(revision 20811)
> +++ configure	(working copy)
> @@ -6718,10 +6722,41 @@
>  fi
>  echores "$_radio_v4l"
>  
> -if test "$_radio_v4l" = no && test "$_radio_v4l2" = no && test "$_radio" = yes ; then
> -    die "Radio driver requires V4L or V4L2!"
> +if bsd; then
> +echocheck "*BSD BrookTree 848 Radio interface"
> +if test "$_radio_bsdbt848" = auto ; then
> +  _radio_bsdbt848=no
> +  if test "$_radio" = yes ; then

This can be simplified, combine the two tests into one line.

Diego



More information about the MPlayer-dev-eng mailing list