[wdmaudiodev] Re: KSPROPERTY_STEPPING_LONG problem!

  • From: eric <esnothing@xxxxxxxxx>
  • To: wdmaudiodev@xxxxxxxxxxxxx
  • Date: Mon, 29 Mar 2010 10:19:19 +0800

Hello Tim,

       Thank you for your quick response. Actually, I have tried
many different settings of Values and KSPROPERTY_STEPPING_LONG but there is
no any difference. Here is on of the settings I tried, the upperest
value of volume control is 0x31, but the lowest value strangely become
-0x2147483648 (signed value 0x80000000).

const
KSPROPERTY_STEPPING_LONG VolumeRangeAndStep [] =
{
    {
        1,     // SteppingDelta
        0,     // Reserved
        {
               0x0,     // Minimum
               0x31    // Maximum
        }
    }
};

const
KSPROPERTY_MEMBERSLIST VolumeMembersList [] =
{
    {
        {
            KSPROPERTY_MEMBER_STEPPEDRANGES,
            sizeof(KSPROPERTY_STEPPING_LONG),
            1,
            KSPROPERTY_MEMBER_FLAG_BASICSUPPORT_UNIFORM
        },
        (PVOID)VolumeRangeAndStep
    }
};

const
KSPROPERTY_VALUES VolumeValues =
{
    {
        STATICGUIDOF (KSPROPTYPESETID_General),
        VT_I4,
        0
    },
    SIZEOF_ARRAY (VolumeMembersList),
    VolumeMembersList
};

DEFINE_KSPROPERTY_TABLE(AudioCaptureFilterVolumePT)
{
    DEFINE_KSPROPERTY_ITEM
    (
        KSPROPERTY_AUDIO_VOLUMELEVEL,
        GetVolume,
// GetSupported or Handler
        sizeof(KSNODEPROPERTY_AUDIO_CHANNEL),  // MinProperty
        sizeof(LONG),                                                     //
MinData
        SetVolume,                                                        //
SetSupported or Handler
        &VolumeValues,                                                 //
Values

0,                                                                      //
RelationsCount
        NULL,
// Relations
        NULL,
// SupportHandler

0                                                                      //
SerializedSize
    )
};



2010/3/27, Tim Roberts <timr@xxxxxxxxx>:
>
> eric wrote:
> >
> >       Recently, I implmented an audio capture filter in avstream
> > architecture under XP, and then I implment it's volume node to get a
> > volume control on my capture filter. After a lot of try and error, I
> > finally made the volume scroll bar work. However, the volume range of
> > scroll bar does not hornor the lower bounds of
> > KSPROPERTY_STEPPING_LONG, but honor the upper bound. I have tried to
> > implment BASICSUPPORT handler, but it did not work. I found somebody
> > run into the same problem here, if this were solved, could any one help?
>
> How can you possibly expect us to answer this question without showing
> us the actual values?  Show us the whole property setup structure,
> including the actual upper and lower values.  This problem came up
> earlier in the year and ended up being a simple confusion over the size
> of the data type.
>
> --
> 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.com/
>
>

Other related posts: