[Kst] kst_0_99_branch: kdeextragear-2/kst/kst
Barth Netterfield
netterfield at astro.utoronto.ca
Tue Aug 17 05:17:54 CEST 2004
CVS commit by netterfield:
fix for [Bug 87177] equations are incorrectly re-sampled
CCMAIL: 87177-done at bugs.kde.org
M +5 -10 kstequationcurve.cpp 1.61.2.1
--- kdeextragear-2/kst/kst/kstequationcurve.cpp #1.61:1.61.2.1
@@ -371,16 +371,11 @@ bool KstEquationCurve::FillY(bool force)
}
}
- if ((*_xVector)->sampleCount() > 0) {
- _interp = (ns+1) / (*_xVector)->sampleCount();
- } else { // avoid divide by zero
- _interp = 1;
- }
} else {
- _interp = 1;
+ ns = (*_xVector)->sampleCount();
}
- if (NS != (*_xVector)->sampleCount() || _interp != 1 ||
+ if (NS != (*_xVector)->sampleCount() || (ns != (*_xVector)->sampleCount()) ||
(*_xVector)->numShift() != (*_xVector)->numNew()) {
- NS = (*_xVector)->sampleCount()*_interp;// - 1;
+ NS = ns;
KstVectorPtr yv = *_yVector;
@@ -395,6 +390,6 @@ bool KstEquationCurve::FillY(bool force)
// calculate shift and new samples
// only do shift optimization if all used vectors are same size and shift
- v_shift = (*_xVector)->numShift()*_interp;
- v_new = (*_xVector)->numNew()*_interp;
+ v_shift = (*_xVector)->numShift();
+ v_new = (*_xVector)->numNew();
for (i_v = 0; i_v < VectorsUsed.count(); i_v++) {
More information about the Kst
mailing list