Previous Next

KSPROPERTY_DIRECTSOUND3DLISTENER_DISTANCEFACTOR

The KSPROPERTY_DIRECTSOUND3DLISTENER_DISTANCEFACTOR property specifies the distance factor that should be applied to any distance values.

Get Set Target Property Descriptor Type Property Value Type
Yes Yes Pin KSNODEPROPERTY FLOAT

The property value (operation data) is of type FLOAT and specifies the distance factor.

Return Value

A KSPROPERTY_DIRECTSOUND3DLISTENER_DISTANCEFACTOR property request returns STATUS_SUCCESS to indicate that it has completed successfully. Otherwise, the request returns an appropriate error status code.

Headers

Declared in ksmedia.h. Include ksmedia.h.

Comments

Distances for KSPROPSETID_DirectSound3DBuffer and KSPROPSETID_DirectSound3DListener properties are expressed in units of meters times a distance factor.

By default, the distance factor is 1 and distances are therefore expressed in meters. (Also, the default velocity units are meters per second.)

A client can change the distance units for the KSPROPSETID_DirectSound3DBuffer and KSPROPSETID_DirectSound3DListener properties by sending a KSPROPERTY_DIRECTSOUND3DLISTENER_DISTANCEFACTOR set-property request that specifies a different distance factor.

DirectSound uses this property to implement the IDirectSound3DListener::GetDistanceFactor and IDirectSound3DListener::SetDistanceFactor methods, which are described in the Platform SDK documentation.

See Also

KSNODEPROPERTY