Partilhar via


WaveBank Constructor (AudioEngine, String)

Initializes a new, in-memory instance of this class using a specified AudioEngine and path to a wave bank file.

Namespace: Microsoft.Xna.Framework.Audio
Assembly: Microsoft.Xna.Framework (in microsoft.xna.framework.dll)

Syntax

public WaveBank (
         AudioEngine audioEngine,
         string nonStreamingWaveBankFilename
)

Parameters

  • audioEngine
    Instance of an AudioEngine to associate this wave bank with.
  • nonStreamingWaveBankFilename
    Path to the wave bank file to load.

Exceptions

Exception type Condition
ArgumentNullException The audioEngine or nonStreamingWaveBankFilenameparameter is null.
InvalidOperationException Unable to create the WaveBank resource.

Remarks

This constructor generates an in-memory version of a wave bank. The entire wave bank contents are held in memory.

See Also

Reference

WaveBank Class
WaveBank Members
Microsoft.Xna.Framework.Audio Namespace

Platforms

Xbox 360, Windows XP SP2, Windows Vista