You can install the filter using the UpperFilters registry value, just like any other filter driver. To process data, intercept IOCTL_KS_WRITE_STREAM and IOCTL_KS_READ_STREAM. You'll also need to track format changes. This will not work in all cases though. In particular, IOCTL_KS_WRITE_STREAM may set the KSSTREAM_HEADER_OPTIONSF_LOOPEDDATA flag, which means you'll only see one write IOCTL, but the buffer will continuously play. There is no guaranteed way (that I know of) to process data in a buffer that uses this flag. (This is just one of several issues, but I thought I'd mention it because it's not obvious, and it took me quite awhile to figure out what was going on.) In this case, you don't really insert the filter into the graph. (This is an unfortunate byproduct of the term "filter" being used in two different contexts; We're referring to a filter driver, not a DirectShow filter.) If you use the filter driver method, you don't need to worry about inserting into a filter graphs -- you'll automatically intercept the audio data. To create a filter driver, I would recommend Walter Oney's "Programming the Windows Driver Model". There's some good information on filter drivers in there, and you can get a simple passthrough filter working pretty quickly. Jeff -----Original Message----- From: admin@xxxxxxxxxxxxxxxxx [mailto:admin@xxxxxxxxxxxxxxxxx] Sent: Wednesday, May 12, 2004 4:32 AM To: wdmaudiodev@xxxxxxxxxxxxx Subject: [wdmaudiodev] Re: help with virtual audio driver. Do you find any samples of a filter driver? It's better to have a sample template to start. Another question, if you install such a driver, will it be automatically created and inserted into the graph at the right position? > Yes if you write a filter driver , it will be be in between dsound/wavout > and the output device. The thing is i havent done implementation of this > myself ... but i m interested in pursuing it. > > Regards > Raza > > > > > > ----- Original Message ----- > From: <admin@xxxxxxxxxxxxxxxxx> > To: <wdmaudiodev@xxxxxxxxxxxxx> > Sent: Wednesday, May 12, 2004 2:43 AM > Subject: [wdmaudiodev] Re: help with virtual audio driver. > > >> Hi, Raza: >> >> Mainly I want to capture and have a chance to modify the audio data to > (and from) the card. >> I think the filter may be solution if it is between the dsound/waveout and > the output sound device. >> >> I really appreciate if you can help. >> >> >> >> >> >> >> >> > Hi, >> > I had the same issue at hand a little while ago and i wrote to a company > who >> > just writes DirectShow filters, they responded by sayin that this cannot > be >> > done using DirectShow filters and then i found out i need to write a > upper >> > filter for audio.sys. I am not pursuing this project anymore but just >> > letting u know of my findings which will speed up ur decision making. >> > Let me know if u need further help. >> > btw i m still interested in coding it , if u agree we can do it together > . >> > >> > Regards >> > Raza >> > >> > >> > >> > ----- Original Message ----- >> > From: "Tim Roberts" <timr@xxxxxxxxx> >> > To: <wdmaudiodev@xxxxxxxxxxxxx> >> > Sent: Tuesday, May 11, 2004 5:50 PM >> > Subject: [wdmaudiodev] Re: help with virtual audio driver. >> > >> > >> >> admin@xxxxxxxxxxxxxxxxx wrote: >> >> >> >> >Thanks for the reply. >> >> > >> >> >Actually >> >> >I want to make it a virtual audio driver. It don't need a specific >> > hardware. It uses the sound >> >> >card to play or record. But it acts like a true audio device there. So >> > apps that use it can work >> >> >normally, but I can have control on the data stream in this driver > now. >> >> > >> >> >I have looked at MSVAD driver in WINXP DDK. It writes the data to > disk. I >> > wonder how to send the >> >> >data to another true sourd device at the same time. >> >> > >> >> > >> >> >> >> I don't think you really want a driver. You want a filter. You can do >> >> all of this in user mode by writing a DirectShow filter. >> >> >> >> -- >> >> - Tim Roberts, timr@xxxxxxxxx >> >> Providenza & Boekelheide, Inc. >> >> >> >> ****************** >> >> >> >> WDMAUDIODEV addresses: >> >> Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx >> >> Subscribe: > mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe >> >> Unsubscribe: > mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe >> >> Moderator: mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx >> >> >> >> URL to WDMAUDIODEV page: >> >> http://www.wdmaudiodev.de/ >> >> >> > >> > ****************** >> > >> > WDMAUDIODEV addresses: >> > Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx >> > Subscribe: mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe >> > Unsubscribe: > mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe >> > Moderator: mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx >> > >> > URL to WDMAUDIODEV page: >> > http://www.wdmaudiodev.de/ >> > >> > >> >> ****************** >> >> WDMAUDIODEV addresses: >> Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx >> Subscribe: mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe >> Unsubscribe: mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe >> Moderator: mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx >> >> URL to WDMAUDIODEV page: >> http://www.wdmaudiodev.de/ >> > > ****************** > > WDMAUDIODEV addresses: > Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx > Subscribe: mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe > Unsubscribe: mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe > Moderator: mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx > > URL to WDMAUDIODEV page: > http://www.wdmaudiodev.de/ > > ****************** WDMAUDIODEV addresses: Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx Subscribe: mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe Unsubscribe: mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe Moderator: mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx URL to WDMAUDIODEV page: http://www.wdmaudiodev.de/