SoundEffect.FromStream Method (Microsoft.Xna.Framework.Audio)
Creates a new SoundEffect object based on the specified data stream.
Namespace: Microsoft.Xna.Framework.Audio
Assembly: MonoGame.Framework (MonoGame.Framework.dll 3.8.0.1082)
Assembly: MonoGame.Framework (MonoGame.Framework.dll 3.8.0.1082)
- C#
- VB
- F#
public static SoundEffect FromStream( Stream stream )
Syntax for VB is not yet implemented.
Syntax for F# is not yet implemented.
Parameters
- stream
-
Type: System.IO.Stream
A stream containing the wave data.
Return Value
Type: Microsoft.Xna.Framework.Audio.SoundEffectA new SoundEffect object.
The stream must point to the head of a valid wave file in the RIFF bitstream format. The formats supported are:
8-bit unsigned PCM 16-bit signed PCM 24-bit signed PCM 32-bit IEEE float PCM MS-ADPCM 4-bit compressed IMA/ADPCM (IMA4) 4-bit compressed
Supported in:
Windows DirectX Desktop
Linux Desktop
Windows OpenGL Desktop
Web
Windows DirectX Desktop
Linux Desktop
Windows OpenGL Desktop
Web