--- xawtv/Makefile Tue Mar 11 14:49:22 2003 +++ xawtv/Makefile Tue Mar 11 14:49:43 2003 @@ -7,6 +7,7 @@ PORTNAME= xawtv PORTVERSION= 3.85 +PORTREVISION= 1 CATEGORIES= graphics MASTER_SITES= http://bytesex.org/xawtv/ DISTNAME= ${PORTNAME}_${PORTVERSION} --- xawtv/files/patch-libng::grab-ng.h Thu Jan 1 01:00:00 1970 +++ xawtv/files/patch-libng::grab-ng.h Mon Mar 10 20:49:39 2003 @@ -0,0 +1,10 @@ +--- libng/grab-ng.h.orig Mon Mar 10 20:49:19 2003 ++++ libng/grab-ng.h Mon Mar 10 20:17:01 2003 +@@ -95,6 +95,7 @@ + #define ATTR_ID_HUE 8 + #define ATTR_ID_CONTRAST 9 + #define ATTR_ID_COUNT 10 ++#define ATTR_ID_AUDIO 11 + + #define CAN_OVERLAY 1 + #define CAN_CAPTURE 2 --- xawtv/files/patch-libng::plugins::drv0-bsd.c Thu Jan 1 01:00:00 1970 +++ xawtv/files/patch-libng::plugins::drv0-bsd.c Mon Mar 10 20:37:18 2003 @@ -0,0 +1,53 @@ +--- libng/plugins/drv0-bsd.c.orig Mon Mar 10 20:36:37 2003 ++++ libng/plugins/drv0-bsd.c Mon Mar 10 20:33:55 2003 +@@ -154,8 +154,27 @@ + BT848_IFORM_F_RSVD, + }; + ++static struct STRTAB audio[] = { ++ { 0, "Tuner" }, ++ { 1, "Extern" }, ++ { 2, "Intern" }, ++ { -1, NULL } ++}; ++static int audio_map[] = { ++ AUDIO_TUNER, ++ AUDIO_EXTERN, ++ AUDIO_INTERN, ++}; ++ + static struct ng_attribute bsd_attr[] = { + { ++ id: ATTR_ID_AUDIO, ++ name: "audio", ++ type: ATTR_TYPE_CHOICE, ++ choices: audio, ++ read: bsd_read_attr, ++ write: bsd_write_attr, ++ },{ + id: ATTR_ID_NORM, + name: "norm", + type: ATTR_TYPE_CHOICE, +@@ -511,6 +530,12 @@ + if (-1 != xioctl(h->tfd,get,&arg)) + value = arg; + break; ++ case ATTR_ID_AUDIO: ++ if (-1 != xioctl(h->tfd, BT848_GAUDIO, &arg)) ++ for (i = 0; i < sizeof(audio_map)/sizeof(int); i++) ++ if (arg == audio_map[i]) ++ value = i; ++ break; + default: + break; + } +@@ -541,6 +566,9 @@ + bsd_get_range(attr->id,&get,&set); + arg = value; + xioctl(h->tfd,set,&arg); ++ break; ++ case ATTR_ID_AUDIO: ++ xioctl(h->tfd, BT848_SAUDIO,&audio_map[value]); + break; + default: + break;