Kernel-mode DirectShow filter vs WDM filter driver

Kernel-mode DirectShow filter vs WDM filter driver

Post by Michael Ran » Thu, 09 May 2002 07:50:27



I hadn't realised that it was possible for DirectShow filters to be low
level enough to be called by DirectSound as well as the normal Windows
APIs.

I'm confused about the lack of documentation issue. For a WDM filter
approach, there is a WDM generic filter example in the DDK under WDM/USB -
isn't this more or less all I need or is it missing a great deal? For a
DirectShow filter approach, aren't DirectShow filters well documented, or
is it specifically kernel-mode ones that are not?

Mike



Quote:> Actually, what I was trying to get across was writing a kernel-mode
> DirectShow filter that accepted multiple channels of audio, and
> converted it to something that your sound card could handle.  You
> could start with the sample in the DDK. To get your driver loaded
> would require the use of the SWENUM bus driver.  This stuff is very
> poorly documented, and very difficult.  The alternative is a WDM
> filter, but that is probably worse, because you'll spend months trying
> to figure out all the undocumented *that gets passed to you (I
> know, because I went through it.  I've gotten a flat spot on my head
> from beating it against the wall so often!).  Also, because just about
> everything is undocumented, it often changes between operating system
> releases; Microsoft will only guarantee the APIs won't change.

>  -Brian

> Brian Catlin, Sannas Consulting 310-798-8930
> Windows Network, Video, WDM Device Driver Training & Consulting
> See WWW.AZIUS.COM for courses and scheduling

 
 
 

Kernel-mode DirectShow filter vs WDM filter driver

Post by Brian Catli » Thu, 09 May 2002 08:43:30



Quote:> I hadn't realised that it was possible for DirectShow filters to be low
> level enough to be called by DirectSound as well as the normal Windows
> APIs.

> I'm confused about the lack of documentation issue.

You and everyone else!

Quote:>For a WDM filter
> approach, there is a WDM generic filter example in the DDK under WDM/USB -
> isn't this more or less all I need or is it missing a great deal?

In theory it will work; however, in practice, there are only a few KS IRPs, but
hundreds of GUIDs that are used to control various streaming functions and
attributes.  Not only aren't these GUIDs documented, Microsoft won't even
guarantee that they will be supported from release-to-release (e.g. a whole
bunch disappeared between Win2K and WinXP).

Quote:> For a
> DirectShow filter approach, aren't DirectShow filters well documented, or
> is it specifically kernel-mode ones that are not?

The kernel-mode DS filter documentation is useless.

 -Brian

> Mike



> > Actually, what I was trying to get across was writing a kernel-mode
> > DirectShow filter that accepted multiple channels of audio, and
> > converted it to something that your sound card could handle.  You
> > could start with the sample in the DDK. To get your driver loaded
> > would require the use of the SWENUM bus driver.  This stuff is very
> > poorly documented, and very difficult.  The alternative is a WDM
> > filter, but that is probably worse, because you'll spend months trying
> > to figure out all the undocumented *that gets passed to you (I
> > know, because I went through it.  I've gotten a flat spot on my head
> > from beating it against the wall so often!).  Also, because just about
> > everything is undocumented, it often changes between operating system
> > releases; Microsoft will only guarantee the APIs won't change.

> >  -Brian

> > Brian Catlin, Sannas Consulting 310-798-8930
> > Windows Network, Video, WDM Device Driver Training & Consulting
> > See WWW.AZIUS.COM for courses and scheduling


 
 
 

1. Load a Kernel-mode driver from another Kernel-mode Driver

Hello all,

We need to be able to cause Windows NT 4.0 kernel-mode drivers to be
loaded and unloaded by another Kernel-mode Driver. The kernel-mode
drivers may need to be loaded at boot time or may need to be loaded
during execution.

Background Information
Our understanding of how Windows NT works in this area is that the
Service Control Manager is the only mechanism to cause a kernel-mode
driver to be loaded "on demand".  To issue the start service request,
the OpenSCManger call is made to obtain a handle.  A call is made to
CreateService to create a service object and obtain a handle to the
service.  A call to StartService is then made to start the service,
which loads the kernel-mode driver.

We have not been able to locate an API which allows a kernel-mode driver
to make the
OpenSCManger, CreateService, or StartService calls and to ensure that
Administrator Privilege applies for the current kernel-mode driver
context.

Request:

Is there any way to start a service without having Administrator
Privilege?  (We cannot guarantee that the Phoenix Technologies
kernel-mode driver will be executing in a context which has
Administrator Privileges.)

We would like to know if there is another mechanism which would load a
kernel-mode driver on demand.

If the Service Control Manager is the only mechanism, is there a library
or DLL which would allow a kernel-mode driver to communicate with the
Service Control Manager?

Does the call to CreateService to create the service object need to be
performed even if the service is defined in the registry?

Thanks in advance for your help.
--
Bob Daniel
Phoenix Technologies Ltd.
Irvine, Ca

2. cannot add domain controller in existing domain

3. Kernel Mode DirectShow filter problem

4. SSS and APM

5. Link filter in Kernel mode driver

6. DCT

7. Writing Directshow source filters and parser filters

8. Vpn : as ?

9. How to do filtering in decode filter when in full-screen mode

10. NDIS Filter Driver Sample Filter Automatic INF install?

11. Filtering out directory entries in a filter driver

12. DirectShow Filter Transform to DirectDraw Video Mode Renderer

13. Kernel mode driver vs. User Mode DLL