From 2e92af10c3f353638bcc630bd882487eb0ee7f3d Mon Sep 17 00:00:00 2001 From: Joe Taylor Date: Wed, 6 Mar 2013 00:52:38 +0000 Subject: [PATCH] Fix horizontal scale of cumulative 2d spectrum. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@3037 ab8295b8-cf94-4d9e-aec4-7959e3be5d79 --- mainwindow.cpp | 2 +- plotter.cpp | 9 ++++++++- wsjtx.iss | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/mainwindow.cpp b/mainwindow.cpp index a30982160..7cc4d7203 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -1,4 +1,4 @@ -//------------------------------------------------------------ MainWindow +//------------------------------------------------------------- MainWindow #include "mainwindow.h" #include "ui_mainwindow.h" #include "devsetup.h" diff --git a/plotter.cpp b/plotter.cpp index 2842211c3..c42b836f9 100644 --- a/plotter.cpp +++ b/plotter.cpp @@ -122,7 +122,14 @@ void CPlotter::draw(float swide[], float red[], int i0) //draw() painter1.drawPoint(i,0); y2=0; if(m_bCurrent) y2 = 0.4*gain*y - 15; - if(m_bCumulative) y2=1.5*gain*10.0*log10(jt9com_.savg[i]) - 20; + if(m_bCumulative) { + float sum=0.0; + int j=m_binsPerPixel*i; + for(int k=0; k