The DXVUMeterNETGDI class provides access to all the functionality provided by the control to monitor, playback and record audio.

Namespace: NDXVUMeterNET
Assembly: DXVUMeterNETGDI (in DXVUMeterNETGDI.dll) Version: 3.0.4021.33606 (3.1.0.0)

Syntax

C#
public class DXVUMeterNETGDI : Control
Visual Basic
Public Class DXVUMeterNETGDI _
	Inherits Control
Visual C++
public ref class DXVUMeterNETGDI : public Control

Remarks

DXVUMeterNETGDI is a .NET class library which can monitor any audio device configured as a recording source such as a Microphone, CD, etc... and display the monitored audio levels like a standard Digital VU Meter, as an Oscilloscope or even display the audio in the frequency domain using the Fast Fourier Transform).

DXVUMeterNETGDI is also able to save to a WAV file the audio data being monitored and since it uses a circular (or infinite) buffer there's no limitation on the amount of audio that can be captured. Playback of WAV and MP3 files is also supported.

The interface of the control is fully resizable in order to let it fit into any form design.

The DigitalVU mode supports vertical and horizontal placement of the bars and the FFT display mode implements many settings found only on professional applications which can be used to either beautify the display or perform professional audio analysis.

An application can use multiple instances of the control to display multiple versions of the same audio data but, since DXVUMeterNETGDI can monitor audio from different sound cards it is also possible to develop applications that incorporate multiple instances of the control where each instance monitors a different sound card.

DXVUMeterNETGDI uses GDI+ to render the audio data. Custom functions using GDI+ can also be designed to render your own audio display interface. This can be done by setting the Style property to UserPaintGDI.

Requirements

  • Microsoft .NET 4.0
  • DirectX 9 or above
  • A version of Windows that supports the .NET 4.0 framework and Direct3D

Important considerations when using DXVUMeterNETGDI

There are two things that you must keep in mind when using DXVUMeterNETGDI on a Form:
  1. Make sure you do not access any of DXVUMeterNETGDI's methods or properties before the ControlIsReady event has been raised. Trying to do so can cause unpredictable results. When the control has raised the event, you can start working with DXVUMeterNETGDI. For example, you could call the StartMonitoring method as shown in this code:
    CopyVB.NET
    Private Sub DxvuMeterNETGDI1_ControlIsReady() Handles DxvuMeterNETGDI1.ControlIsReady
        DxvuMeterNETGDI1.StartMonitoring()
    End Sub
  2. Make sure you stop DXVUMeterNETGDI before the form is closed. The best way to do this is as follows:
    CopyVB.NET
    Private Sub Form1_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
        DxvuMeterNETGDI1.StopMonitoring()
        Application.DoEvents()
    End Sub
  3. It is very important that you add the following code to the configuration section of the app.config file for your applications:
    CopyXML
    <startup useLegacyV2RuntimeActivationPolicy="true"><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0" /></startup>
If you are using a registered version of DXVUMeterNETGDI, you should pass your registration information to the control from the ControlIsReady event, using the LicenseControl method:
CopyVB.NET
Private Sub DxvuMeterNETGDI1_ControlIsReady() Handles DxvuMeterNETGDI1.ControlIsReady
    DXVUMeterNET1.LicenseControl("2J0N1X88015AE33FNED3141592653968", "DXVUNET-KP28-11AY-TJ2A")
End Sub

Inheritance Hierarchy

See Also