Inspecting SDRSharp.PanView.dll - peak hold mod

 17.5.2020
Inspecting SDRSharp.PanView.dll - peak hold mod

Spectrum analyzer peak hold modification
Visual Studio Community Edition 2019
dotPeek

Export SDRSharp.PanView.dll to VS project with dotPeek. Copy also SDRSharp.Radio.dll into same folder because PanView.dll uses it.

Modify code in SpectrumAnalyzer.cs

  public class SpectrumAnalyzer : UserControl
  {
        // ADD
    private int _performCounter = 0;
    ...

public SpectrumAnalyzer()
{
  ...
  this._graphics = Graphics.FromImage((Image) this._buffer);
  // ADD
 _buffer.MakeTransparent();
...

Add method (clear FFT from app using dll)
public void resetKeepFFT()
{
    _performCounter = 0;
}
 
private void DrawLayers()
{
       if (this._buffer.Width <= 30 || this._buffer.Height <= 30)
        return;
      // ADD
      if (_performCounter < 50) this._graphics.Clear(Color.Black);
      ...

private void Perform(bool force)
{
      ...
      this._performNeeded = false;
     // ADD
      _performCounter++;
}







Comments

Popular posts from this blog

Modifying old SDR# TETRA demod plug-in

Mods for SDR# TETRA demod plugin 1.0.14.0 - 2