[wdmaudiodev] Re: AVStream and Wave Devices

  • From: "Sam Tertzakian" <sam@xxxxxxxxxxx>
  • To: <wdmaudiodev@xxxxxxxxxxxxx>
  • Date: Thu, 6 Oct 2005 08:35:54 -0700

Hi, Matt,

Isn't the friendly name this: g_PINNAME_AUDIO_RENDER or
g_PINNAME_AUDIO_CAPTURE?

It is commented out in the example I sent you...but, that is what I had
orinally...at some point in my testing I decided to go with those other
names...probably because they were in some other PortCls driver I had
written.

But, I will try those again, right now...just to make sure...

Or, if those are not the "friendly names"...then maybe I don't know what a
"friendly name" is.

-----Original Message-----
From: wdmaudiodev-bounce@xxxxxxxxxxxxx
[mailto:wdmaudiodev-bounce@xxxxxxxxxxxxx] On Behalf Of Matt Gonzalez
Sent: Thursday, October 06, 2005 8:31 AM
To: wdmaudiodev@xxxxxxxxxxxxx
Subject: [wdmaudiodev] Re: AVStream and Wave Devices

The first thing I notice is that you don't have any friendly names for 
your pins - the Name member of KSPIN_DESCRIPTOR.  This may actually be 
all it takes.  Try adding that - if that doesn't work, I'll do a closer 
look.

Windows Vista will use the friendly names of the pins to name the wave 
devices, so you'll want to do this anyhow.

Matt


Sam Tertzakian wrote:

>Hi, Matt,
>
>Thank you for your time...
>
>Yes, I have tried several variations of the "needs" and "include"....I just
>sent you one of the combinations. I am sure that is not the problem. There
>is no doubt that SysAudio sees my device...it is trying to register it, but
>returns STATUS_NOT_SUPPORTED.
>
>As for the GUID, yes, I have tried several variations of that. In my latest
>version, I use "Wave" and "Topology" instead of a GUID and I use
>KsCreateFilter twice and pass in "Wave" and "Topology".
>
>Again, I just sent one of the variations. 
>
>I thought that perhaps it was because I did not have a Topology filter. So,
>created that...as a bonus, I get two STATUS_NOT_SUPPORTED, once for the
Wave
>and now for the Topology.
>
>Here is some of the stuff you asked for...I have removed comments to reduce
>clutter and eliminate some word-wrapping issues.
>
>I have not included my Topology filter since I am pretty that is not the
>problem. If the problem is not here, then I'll send it separately.
>
>const
>GUID
>CaptureFilterCategories [CAPTURE_FILTER_CATEGORIES_COUNT] = {
>    STATICGUIDOF (KSCATEGORY_AUDIO),
>    STATICGUIDOF (KSCATEGORY_CAPTURE),
>    STATICGUIDOF (KSCATEGORY_RENDER)
>};
>
>DECLARE_SIMPLE_FRAMING_EX (
>    AudioDefaultAllocatorFraming,
>    STATICGUIDOF (KSMEMORY_TYPE_KERNEL_NONPAGED),
>    KSALLOCATOR_REQUIREMENTF_SYSTEM_MEMORY |
>        KSALLOCATOR_REQUIREMENTF_PREFERENCES_ONLY,
>    NUM_FRAMES,
>    0,
>    FRAME_SIZE,
>    FRAME_SIZE
>    );
>
>KSDATARANGE_AUDIO 
>       AudioFormat =
>{
>       {
>               sizeof( KSDATARANGE_AUDIO ),
>               0,
>               0,
>               0,
>               STATICGUIDOF( KSDATAFORMAT_TYPE_AUDIO ),
>               STATICGUIDOF( KSDATAFORMAT_SUBTYPE_PCM ),
>               STATICGUIDOF( KSDATAFORMAT_SPECIFIER_WAVEFORMATEX )
>       },
>       2,
>       16,
>       16,
>       8000
>       8000
>};
>
>const 
>PKSDATARANGE 
>AudioCapturePinDataRanges[ CAPTURE_PIN_DATA_RANGE_COUNT ] = {
>    (PKSDATARANGE) &AudioFormat
>};
>
>KSDATARANGE PinDataRangesBridge[ 1 ] =
>{
>   {
>      sizeof(KSDATARANGE),
>      0,
>      0,
>      0,
>      STATICGUIDOF(KSDATAFORMAT_TYPE_AUDIO),
>      STATICGUIDOF(KSDATAFORMAT_SUBTYPE_ANALOG),
>      STATICGUIDOF(KSDATAFORMAT_SPECIFIER_NONE)
>   }
>};
>
>PKSDATARANGE PinDataRangePointersBridge[ 1 ] =
>{
>    &PinDataRangesBridge[0]
>};
>
>const
>KSPIN_DESCRIPTOR_EX
>AudioPinDescriptorTemplate[ NUM_AUDIO_PINS + 2 ] = {
>       // Audio Render Pin: AUDIO_PIN_RENDER
>       //
>       {
>               &AudioCapturePinDispatch,                               
>               NULL,
>               { 
>                       NULL,
>                       0,                      
>                       NULL,
>                       0,
>                       SIZEOF_ARRAY( AudioCapturePinDataRanges ),
>                       AudioCapturePinDataRanges,
>                       KSPIN_DATAFLOW_IN,              
>                       KSPIN_COMMUNICATION_BOTH,
>&KSCATEGORY_AUDIO,
>                       &KSNODETYPE_SPEAKER,
>                       //&g_PINNAME_AUDIO_RENDER,
>                       0
>               },
>               KSPIN_FLAG_PROCESS_IN_RUN_STATE_ONLY |
>                       KSPIN_FLAG_FIXED_FORMAT,
>               1,                                    
>               0,                                    
>               &AudioDefaultAllocatorFraming,
>               reinterpret_cast <PFNKSINTERSECTHANDLEREX> 
>                       (CAudioPin::IntersectHandler)   
>       },
>       // Audio Capture Pin: AUDIO_PIN_CAPTURE
>       //
>       {
>               &AudioCapturePinDispatch,
>               NULL,
>               { 
>                       NULL,    
>                       0,                      
>                       NULL,    
>                       0,
>                       SIZEOF_ARRAY( AudioCapturePinDataRanges ),
>                       AudioCapturePinDataRanges,                      
>                       KSPIN_DATAFLOW_OUT,     
>                       KSPIN_COMMUNICATION_BOTH,
>                       &KSCATEGORY_AUDIO,       
>                       &KSAUDFNAME_RECORDING_CONTROL,
>                       //&g_PINNAME_AUDIO_CAPTURE,   
>                       0                             
>               },
>               KSPIN_FLAG_PROCESS_IN_RUN_STATE_ONLY |
>                       KSPIN_FLAG_FIXED_FORMAT,
>               1,                                  
>               0,                                  
>               &AudioDefaultAllocatorFraming,      
>               reinterpret_cast <PFNKSINTERSECTHANDLEREX> 
>                       (CAudioPin::IntersectHandler)
>       },
>       // Audio Render BRIDGE Pin
>       //
>       {
>               NULL,
>               NULL,
>               {
>                       0,
>                       NULL,
>                       0,
>                       NULL,
>                       SIZEOF_ARRAY(PinDataRangePointersBridge),
>                       PinDataRangePointersBridge,
>                       KSPIN_DATAFLOW_OUT,
>                       KSPIN_COMMUNICATION_BRIDGE,
>                       (GUID *) &KSCATEGORY_AUDIO,
>                       NULL,
>                       0
>               },
>               KSPIN_FLAG_PROCESS_IN_RUN_STATE_ONLY |
>                       KSPIN_FLAG_FIXED_FORMAT,
>               1,                                      
>               0,                                      
>               NULL,                                                   
>               NULL                                                    
>       },
>       // Audio Capture BRIDGE Pin
>       //
>       {
>               NULL,
>               NULL,
>               {
>                       0,
>                       NULL,
>                       0,
>                       NULL,
>                       SIZEOF_ARRAY(PinDataRangePointersBridge),
>                       PinDataRangePointersBridge,
>                       KSPIN_DATAFLOW_IN,
>                       KSPIN_COMMUNICATION_BRIDGE,
>                       (GUID *) &KSCATEGORY_AUDIO,
>                       NULL,
>                       0
>               },
>               KSPIN_FLAG_PROCESS_IN_RUN_STATE_ONLY |
>                       KSPIN_FLAG_FIXED_FORMAT,
>               1,                          
>               0,                          
>               NULL,                                   
>               NULL                                    
>       },
>};
>
>#define NODE_ADC       0
>#define NODE_DAC       1
>#define NODE_VOL       2
>#define NODE_SUM       3
>
>#define PIN_IN 1               // looks like "i" for input
>#define PIN_OUT        0               // looks like "o" for output
>
>const KSNODE_DESCRIPTOR FilterNodes[] =
>{
>    {
>        NULL,                                  
>        &KSNODETYPE_ADC,        // Type
>        NULL                    // Name
>    },
>    {
>        NULL,                                  
>        &KSNODETYPE_DAC,        // Type
>        NULL                    // Name
>    },
>};
>
>const KSTOPOLOGY_CONNECTION FilterConnections[] =
>{
>       // Render path.
>       //
>       { KSFILTER_NODE, AUDIO_PIN_RENDER, NODE_DAC, PIN_IN },    
>       { NODE_DAC,     PIN_OUT, KSFILTER_NODE, AUDIO_PIN_RENDER_BRIDGE },
>
>       // Capture path.
>       //
>       { KSFILTER_NODE,        AUDIO_PIN_CAPTURE_BRIDGE, NODE_ADC,
>PIN_IN },
>       { NODE_ADC,      PIN_OUT,       KSFILTER_NODE,  AUDIO_PIN_CAPTURE }
>};
>
>// CaptureFilterDescription:
>//
>const 
>KSFILTER_DESCRIPTOR 
>CaptureFilterDescriptor = {
>       &CaptureFilterDispatch,
>       NULL,
>KSFILTER_DESCRIPTOR_VERSION,
>       KSFILTER_FLAG_DISPATCH_LEVEL_PROCESSING,
>       &XXXXNAME_Filter,       // I call KsCreateFilter so this is ignored
>anyway
>       DEFINE_KSFILTER_PIN_DESCRIPTORS (AudioPinDescriptorTemplate),
>       DEFINE_KSFILTER_CATEGORIES (CaptureFilterCategories),
>       DEFINE_KSFILTER_NODE_DESCRIPTORS( FilterNodes ),
>DEFINE_KSFILTER_CONNECTIONS(FilterConnections),        
>       NULL
>};
>
>
>-----Original Message-----
>From: wdmaudiodev-bounce@xxxxxxxxxxxxx
>[mailto:wdmaudiodev-bounce@xxxxxxxxxxxxx] On Behalf Of Matt Gonzalez
>Sent: Wednesday, October 05, 2005 5:07 PM
>To: wdmaudiodev@xxxxxxxxxxxxx
>Subject: [wdmaudiodev] Re: AVStream and Wave Devices
>
>Here's what I have in my INF that's different:
>
>My "include" and "needs" lines are different; here's mine:
>
>Include= ks.inf, ksfilter.inf, wdmaudio.inf
>Needs=KS.Registration
>Needs=WDMAUDIO.Registration
>AlsoInstall=ks.registration(ks.inf),wdmaudio.registration(wdmaudio.inf)
>
>You've got this:
>
>XXX_FILTER_REF_GUID     = "XXXX0"
>
>but it's a real GUID in your actual INF file, right?  And you're passing 
>that same GUID in your filter descriptor as the reference guid?
>
>What you have here looks OK, though.  I would guess that the problem is 
>with your filter descriptor.  If you like, go ahead and post the whole 
>thing (filter, pins, nodes, connections, everything).
>
>Matt
>
>******************
>
>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.com/
>
>******************
>
>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.com/
>
>  
>

******************

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.com/

******************

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.com/

Other related posts: