[Kst] extragear/graphics/kst/kst

Rick Chern rchern at interchange.ubc.ca
Thu Jul 14 21:12:36 CEST 2005


On Thu, 2005-07-14 at 13:35 -0400, George Staikos wrote:
> On Thursday 14 July 2005 13:25, Rick Chern wrote:
> > --- trunk/extragear/graphics/kst/kst/kstimagedialog_i.cpp #434581:434582
> > @@ -492,10 +492,13 @@
> >      KstMatrixPtr matrix = *matrices.findTag(_matrix->selectedMatrix());
> >      if (matrix) {
> >        // force update
> > +      _autoThreshold->setEnabled(false);
> > +      matrix->update(true);
> >        matrix->readLock();
> >        _lowerZ->setText(QString::number(matrix->minZ()));
> >        _upperZ->setText(QString::number(matrix->maxZ()));
> >        matrix->readUnlock();
> > +      _autoThreshold->setEnabled(true);
> >      }
> >    }
> >  }
> 
>   We really need a better solution for this.  Also you have to lock the matrix 
> when you do update().  The problem is that update() can take lots of CPU time 
> and that means the GUI is frozen.  It also means that the matrix is out of 
> sync with the rest of the objects.
> 
>   Oh, and update() takes an int parameter, not a bool...
> 

The Auto Threshold button should get the current min and max of the
matrix at the time the button was clicked - so if the matrix has not
been updated, does it make sense to simply use the old min and max since
the last update (even if the matrix is unused and thus has 1 sample)?

Or, is the Auto Threshold button actually needed (since there is real-
time auto threshold)?


More information about the Kst mailing list