locked
DirectX volume control RRS feed

  • Question

  •  

    hi,

     

    I have an instance of DirectX's audio player called :

     

    Microsoft.DirectX.AudioVideoPlayback.Audio DXShipFires = new Microsoft.DirectX.AudioVideoPlayback.Audio("C:\\Games\\Asteroids_C#\\ShipFires.wav");

     

    and the playback

     

    playSound(DXShipFires);

     

    private void playSound(Microsoft.DirectX.AudioVideoPlayback.Audio DXThisAudio)

    {

    //DXThisAudio.Volume = (int) nudVolume.value;

    DXThisAudio.CurrentPosition = 0.0;

    DXThisAudio.Play();

    }

     

    works fine ... except, as you can see the commented out line, which refuses to work with any value other than zero and is still much, much too loud! 

    I don't know how to set the volume despite looking at the volume property's calling header which reads 'int Audio.Volume' !?!

     

    any ideas?

    BadButBit

    Sunday, September 9, 2007 5:33 PM

Answers

All replies

  • 0 is max loudness.  Try -10000.

    Sunday, September 9, 2007 8:53 PM
  • cool!

     

    at -10000 you can't hear anything but the negative values are where its at... 

     

    my eardrums thank you

     

    BadButBit

    Monday, September 10, 2007 12:14 AM