Show / Hide Table of Contents

Struct BassInfo

Used with GetInfo(out BassInfo) to retrieve information on the current device.

Namespace: System.Dynamic.ExpandoObject
Assembly: ManagedBass.dll
Syntax
public struct BassInfo
Remarks

The DSCAPS_SECONDARY flags only indicate which sample formats are supported by hardware mixing.

Platform-specific

On Windows, it is possible for speakers to mistakenly be 2 with some devices/drivers when the device in fact supports more speakers. In that case, the CPSpeakers flag can be used (with Init(Int32, Int32, DeviceInitFlags, IntPtr, IntPtr)) to use the Windows control panel setting, or the ForcedSpeakerAssignment flag can be used to force the enabling of speaker assignment to up to 8 speakers, even though the device may not really support that many speakers. The result of assigning channels to nonexistent speakers is undefined; they may be heard on other speakers or not heard at all.

The flags, hwsize, hwfree, freesam, free3d, minrate, maxrate, eax, and dsver members are only used on Windows, as DirectSound and hardware mixing are only available there. The freq member is not available on Windows prior to Vista.

On Windows, the availability of the latency and minbuf values depends on the Latency flag being used when Init(Int32, Int32, DeviceInitFlags, IntPtr, IntPtr) was called.

Properties

DSVersion

DirectSound version.

9 = DX9/8/7/5 features are available, 8 = DX8/7/5 features are available, 7 = DX7/5 features are available, 5 = DX5 features are available. 0 = none of the DX9/8/7/5 features are available.

Declaration
public int DSVersion { get; }
Property Value
Int32

EAXEnabled

The device supports EAX and has it enabled?

The device's "Hardware acceleration" needs to be set to "Full" in it's "Advanced Properties" setup, else EAX is disabled.

This is always false if Device3D was not used when Init(Int32, Int32, DeviceInitFlags, IntPtr, IntPtr) was called.

Declaration
public bool EAXEnabled { get; }
Property Value
Boolean

Free3DSampleSlots

The number of free 3D sample slots in the hardware.

Declaration
public int Free3DSampleSlots { get; }
Property Value
Int32

FreeHardwareMemory

The device's amount of free hardware memory.

Declaration
public int FreeHardwareMemory { get; }
Property Value
Int32

FreeSampleSlots

The number of free sample slots in the hardware.

Declaration
public int FreeSampleSlots { get; }
Property Value
Int32

InitFlags

The flags parameter of the Init(Int32, Int32, DeviceInitFlags, IntPtr, IntPtr) call (DeviceInitFlags).

Declaration
public DeviceInitFlags InitFlags { get; }
Property Value
DeviceInitFlags

IsCertified

The device driver has been certified by Microsoft. Always true for WDM drivers.

Declaration
public bool IsCertified { get; }
Property Value
Boolean

Latency

The delay (rounded up to the nearest millisecond) for playback of HSTREAM/HMUSIC channels to start and be heard.

Requires that Latency was used when Init(Int32, Int32, DeviceInitFlags, IntPtr, IntPtr) was called.

Declaration
public int Latency { get; }
Property Value
Int32

MaxSampleRate

The maximum sample rate supported by the hardware.

Declaration
public int MaxSampleRate { get; }
Property Value
Int32

MinBufferLength

The minimum Buffer Length (rounded up to the nearest millisecond) recommended for use with the PlaybackBufferLength config option.

Requires that Latency was used when Init(Int32, Int32, DeviceInitFlags, IntPtr, IntPtr) was called.

Declaration
public int MinBufferLength { get; }
Property Value
Int32

MinSampleRate

The minimum sample rate supported by the hardware.

Declaration
public int MinSampleRate { get; }
Property Value
Int32

SampleRate

The device's current output sample rate. This is only available on Windows Vista and OSX.

Declaration
public int SampleRate { get; }
Property Value
Int32

SpeakerCount

The number of speakers the device/drivers supports... 2 means that there is no support for speaker assignment - this will always be the case with non-WDM drivers in Windows.

It's also possible that it could mistakenly be 2 with some devices/drivers, when the device in fact supports more speakers.

In that case the ForcedSpeakerAssignment or CPSpeakers flag can be used in the Init(Int32, Int32, DeviceInitFlags, IntPtr, IntPtr) call to force the enabling of speaker assignment.

Declaration
public int SpeakerCount { get; }
Property Value
Int32

Supports16BitSamples

16-bit samples are supported by hardware mixing.

Declaration
public bool Supports16BitSamples { get; }
Property Value
Boolean

Supports8BitSamples

8-bit samples are supported by hardware mixing.

Declaration
public bool Supports8BitSamples { get; }
Property Value
Boolean

SupportsContinuousRate

The device supports all sample rates between minrate and maxrate.

Declaration
public bool SupportsContinuousRate { get; }
Property Value
Boolean

SupportsDirectSound

The device's drivers has DirectSound support

Declaration
public bool SupportsDirectSound { get; }
Property Value
Boolean

SupportsMonoSamples

Mono samples are supported by hardware mixing.

Declaration
public bool SupportsMonoSamples { get; }
Property Value
Boolean

SupportsStereoSamples

Stereo samples are supported by hardware mixing.

Declaration
public bool SupportsStereoSamples { get; }
Property Value
Boolean

TotalHardwareMemory

The device's total amount of hardware memory.

Declaration
public int TotalHardwareMemory { get; }
Property Value
Int32

Back to top Copyright © 2017 Mathew Sachin
Generated by DocFx