The ZBuffer - Managed DirectX resources
Search ZBuffer
Links


 

Tom has specifically asked for feedback on the design changes. Please let him know your ideas, feelings and bugs. Either use directx@microsoft.com or contact him via his blog.

Tom has also informed me that about 40% of D3DX is unintentionally missing from the beta. So don't assume any classes that are gone are gone for good.

The following are the changes I have determined in the Microsoft.DirectX.DirectSound namespace. My analysis is as good as my tools and my eyesight. Please check the facts yourself before berating anyone in public forums or making business decisions. Please let me know if you find any errors.

DirectSound was a bear to analyze - a lot of the classes have changed names so matching the old and new was pretty tough becuase 1. they changed places alphabetically and 2. DirectSound is probably my weakest of the DirectX APIs.

Deleted Classes/Structs (or maybe moved/renamed and I've not found them - see note above):

  • DeviceInformation
  • CaptureEffectsNoiseSuppress - it's only useful parameter is moved into NoiseSuppress
  • enum WaveFormatTag
  • CaptureDevicesCollection
  • DevicesCollection
  • UnsupportedException

Changed Classes/Structs:

  • Common Changed
    • UnmanagedComPointer, UpdateUnmanagedPointer - added to several classes
    • GetHashCode - added to lots of classes
    • ToString - becomes sealed
    • Public fields changed to property get/set
    • get_{PropertyName} functions added to match to property get functions. I assume this to allow languages that don't understand properties to have access?
    • Default Constructors gone for structs - is this a .net 2.0 thing?
    • GetObjectByValue - removed from most (all?) classes
    • Constructor(IntPtr) - removed from most (all?) classes
  • Angles - becomes ConeAngles
    • Inside, Outside - appended with *ConeAngle
  • Buffer
    • Constructors - device moves to the 1st parameter in all of them
    • Caps - becomes Capabilities
    • NotVirtualized - becomes IsNotVirtualized
    • PlayPosition - becomes BufferPosition and returns a BufferPosition (I'm guessing this replaces the WritePosition and GetCurrentPosition that have been removed)
    • WritePosition, GetCurrentPosition, Read, Write - removed
    • Play - new overload with no parameters
  • Buffer3D
    • Buffer3D - new constructor taking an EffectBuffer
    • Buffer3D - new constructor taking an IDirectSound3DBuffer*
    • ConeAngles - now returns ConeAngles rather than Angles
    • MinDistance, MaxDistance - spelled out in full
  • Buffer3DSettings
    • MinDistance, MaxDistance - spelled out in full
  • BufferCaps - becomes BufferCapabilites
    • BufferBytes - has property set added
    • CanGetCurrentPosition, Control3D/Effects/Frequency/Pan/PositionNotify/Volume, GlobalFocus, LocateInHardware/Software, LocationDefer, Mute3DAtMaximumDistace, PrimaryBuffer, StaticBuffer, StickyFocus - all become prepended by Supports*
  • BufferDescription
    • BufferDescription(WaveFormat) - removed
    • Format - becomes WaveFormat and returns Nullable<WaveFormat>
  • BufferPositionNotify - becomes PositionNotify
    • SetWaitHandle - added
  • Caps - becomes Capabilities
    • Certified, ContinuousRate - prepended by Is*
    • EmulateDriver - becomes IsEmulatedDriver
    • FreeHardwareMemBytes - spelled out in full
    • PlayCPUOverheadSoftwareBuffer - becomes PlayCpuOverheadSwBuffers
    • Primary16bit/8Bit/Mono/Stereo, Secondary16Bit/8Bit/Mono/Stereo - all prepended by Supports*
    • TotalHardwareMemoryBytes - becomes TotalHardwareMemBytes
  • Capture
    • Capture(IDirectSoundCapture*) - added
    • Caps - becomes Capabilites and returns CaptureCapabilities
  • CaptureAcousticEchoCancellationEffect - becomes AcousticEchoCancellation
    • AcousticEchoCancellation(IDirectSoundCaptureFXAec*) added
    • AllParameters - now returns AcousticEchoCancellationParameters rather than CaptureEffectsAcousticEchoCancellation
  • CaptureEffectsAcousticEchoCancellation - becomes AcousticEchoCancellationParameters
    • Enbale - becomes IsEnabled
    • NoiseFill - becomes UseNoiseFill
  • CaptureBuffer
    • CaptureBuffer(IDirectSoundCaptureBuffer8*) - added
    • Capturing, Looping - prepended by Is*
    • GetCurrentPosition - becomes Position and returns a BufferPosition
    • GetEffectsStatus - becomes GetStatus
    • Read, Write - removed
  • CaptureBufferCaps - becomes CaptureBufferCapabilities
    • WaveMapped - becomes IsWaveMapped
  • CaptureBufferDescription
    • CaptureEffectDescription - removed. Maybe a chance that this is replaced with the new Flags that returns a BufferDescriptionFlags
    • Flags - added
    • Format - becomes WaveFormat and returns Nullable<WaveFormat>
    • WaveMapped - becomes IsWaveMapped
  • CaptureCaps - becomes CaptureCapabilities
    • Certified, EmulatedDriver - prepended with Is*
    • Almost all other caps prepended with Supports*
  • CaptureEffectDescription
    • GuidEffectsClass, GuidEffectInstance - lose the Guid
  • CaptureNoiseSuppressEffect - becomes NoiseSppress
    • NoiseSuppress(IDirectSoundCaptureFXNoiseSuppress*) - added
    • IsEnabled - added (actually moved from the now removed CaptureEffectsNoiseSuppress)
    • AllParameters - removed
  • ChorusEffect - becomes Chorus
    • Chorus(IDrectSoundFXChorus*) - added
    • static readonly fields - become consts
    • AllParameters - now a ChorusParameters rather then EffectsChorus
  • CompressorEffect - becomes Compressor
    • Compressor(IDrectSoundFXChorus*) - added
    • static readonly fields - become consts
    • AllParameters - now a CompressorParameters rather then EffectsCompressor
  • Device
    • Caps - becomes Capabilities and returns Capabilities
    • SpeakerConfig - becomes SpeakerConfiguration and returns SpeakerConfiguration
    • SetCooperativeLevel(Control, ...) - added
  • DistortionEffect - becomes Distortion
    • Chorus(IDrectSoundFXDistortion*) - added
    • static readonly fields - become consts
    • AllParameters - now a DistortionParameters rather then EffectsDistortion
  • DSoundHelper - becomes Constants
    • Some static readonly change to const
    • InterfaceSecondaryBuffer - becomes InterfaceEffectsBuffer (this is a guess!)
    • InterfaceEffectsParamEq - becomes InterfaceEffectsParametricEqualizer
    • GetObjectFromInterfaceGuid - removed
  • EchoEffect - becomes Echo
    • Chorus(IDrectSoundFXEcho*) - added
    • static readonly fields - become consts
    • AllParameters - now a EchoParameters rather then EffectsEcho
  • EffectDescription
    • GuidEffectCkass - becomes EffectClass
  • EffectsChorus - becomes ChorusParameters
    • Waveform - becomes WaveForm
  • EffectsCompressor - becomes CommmpressorParameters
  • EffectsDistortion - becomes DistortionParameters
  • EffectsEcho - becomes EchoParameters
  • EffectsFlanger - becomes FlangerParameters
  • EffectsGargle - becomes GargleParameters
  • EffectsParamEq - becomes ParametricEqualizerParameters
  • EffectsWavesReverb becomes WavesReverbParameters
  • FlangerEffect - becomes Flanger
    • Flanger(IDirectSoundFXFlanger*) - added
    • static readonly fields - become consts
    • AllParameters - now returns FlangerParameters
  • FullDuplex
    • FullDuplex(CaptureBufferDescription, ...) - 2 constructors removed (maybe merged into an exisiting one - look carefully here!)
    • FullDuplex(IDirectSoundFullDuplex*), EffectsBuffer, CaptureBuffer - added
  • GargleEffect - becomes Gargle
    • Gargle(IDirectSoundFXGargle*) - added
    • AllParameters - returns GargleParameters rather than EffectsGargle
  • Interactive3DLevel2ReverbEffect - becomes Interactive3DLevel2Reverb
    • Interactive3DLevel2Reverb(IDirectSoundFXI3DL2Reverb*) - added
    • static readonly fields - become consts
    • AllParameters - returns Interactive3DLevel2ReverbParameters rather than EffectsInteractive3DLevel2Reverb
  • EffectsInteractive3DLevel2Reverb - becomes Interactive3DLevel2ReverbParameters
  • Listener3D - becomes Listener
    • Listner(EffectsBuffer), Listener(IDirectSound3DListener*_ - added
    • Listener3DOrientation - becomes ListenerOrientation
    • AllParameters - returns ListenerSettings rather than Listener3DSettings
  • Listener3DOrientation - becomes ListenerOrientation
    • Default constructor - removed
    • Front - becomes FrontOrientation
    • Top - becomes TopOrientation
  • Listener3DSetting - becomes ListenerSettings
    • Default constructor removed
    • OrientFront - becomes FrontOrientation
    • OrientTop - becomes TopOrientation
  • Notify
    • Notify(IDirectSoundNotify*) - added
  • ParamEqEffect - becomes ParametricEqualizer
    • ParametricEqualizer(IDirectSoundFXParamEq*) - added
    • static readonly fields - become consts
    • AllParameters - returns ParametricEqualizerParameters rather than EffectsParamEq
  • SecondaryBuffer - becomes EffectsBuffer
    • All constructors - device becomes the 1st parameter
    • EffectsBuffer(IDirectSoundBuffer8*) - added
    • AquireResources - new overload that returns void and has effectsReturn value as out parameter
    • Clone - now returns EffectsBuffer
  • Speakers - becomes SpeakerConfiguration
  • WaveFormat
    • BlockAlign - becomes BlackAlign
    • FormatTag - removed
  • WaveReverbEffect
    • WavesReverb(IDirectSoundFXWavesReverb*) - added
    • static readonly fields - become consts
    • AllParameters - returns WavesReverbParameters rather than EffectsWavesReverb
  • enum BufferPlayFlags - becomes PlayFlags
  • enum EffectsEnvironmentPreset - becomes EnvironmentPreset
  • *Exception - now inherit from DirectXException rather than SoundException

New Classes/Structs:

  • BufferPosition

Issues/Inconsistencies/Things that SHOULD have been changed/While we are making major changes lets do this too?

  • Buffer, Buffer3D, EffectsBuffer, FullDuplex (and more?) - UnmanagedComPointer/UpdateUnmanagedPointer: names are not consistent. Is it a COM pointer or not?
  • Caps - has several properties containitng Max which is not spelled out in full as with other properties in other classes
  • Caps::PlayCPUOverheadSoftwareBuffer - becomes PlayCpuOverheadSwBuffers - this is the opposite of the .Net guidelines
  • Caps::TotalHardwareMemoryBytes - becomes TotalHardwareMemBytes - ditto, original spelling is the recommended one
  • Device::SetCooperativeLevel - now has a constructor that takes a control. Odd since D3D seems to have removed any references to WinForms
  • Many of the {Effect}Parameters classes still have Min and Max abbreviated
  • EffectBuffer::AquireResources - why does the new overload return void and have an out parameter. Not consistent with other overloas
  • ListenerOrientation/ListenerSetting - Top and Front don't need Orientation added - they are vectors so we get the idea. We don't use this postfix notation in the Up vector for LookAt(). If they must stay then match the constructor parameter names to the properties.
  • CaptureEffectsNoiseSuppress::Enabled - is renamed to IsEnabled and moved from here to NoiseSuppress. This isn't consistent with AcousticEchoCancellation which leaves the enabled flag inside the AcousticEchoCancellationParameters. They should match one way or the other
  • WaveFormat::BlackAlign - has to be a typo - the original BLOCKalign seemed correct.
  • Why do all the Effects not inherit from a common base class?
  • Why do all the {Effect}Parameters not inherit from a common base class?
Updated 10/17/2005 8:13:00 PM by Zman