SoundEffectInstance.Volume Property (Microsoft.Xna.Framework.Audio)

Gets or sets the volume of the SoundEffectInstance.

Namespace: Microsoft.Xna.Framework.Audio
Assembly: MonoGame.Framework (MonoGame.Framework.dll 3.8.0.1082)
  • C#
  • VB
  • F#
public float Volume { get; set; }

Syntax for VB is not yet implemented.

Syntax for F# is not yet implemented.

Property Value

Type: System.Single
Volume, ranging from 0.0 (silence) to 1.0 (full volume). Volume during playback is scaled by SoundEffect.MasterVolume.
This is the volume relative to SoundEffect.MasterVolume. Before playback, this Volume property is multiplied by SoundEffect.MasterVolume when determining the final mix volume.
Supported in:

    
 Windows DirectX Desktop
    
 Linux Desktop
    
 Windows OpenGL Desktop
    
 Web