Rebuild wavtm with curve finerCoraser - language - various chnages to denoise

This commit is contained in:
Desmis
2020-05-12 09:11:16 +02:00
parent 8581799a7a
commit e25f5aa455
15 changed files with 255 additions and 72 deletions

View File

@@ -1278,6 +1278,43 @@ void WavOpacityCurveRG::Set(const std::vector<double> &curvePoints)
}
WavOpacityCurveSH::WavOpacityCurveSH() {}
void WavOpacityCurveSH::Reset()
{
lutOpacityCurveSH.reset();
}
void WavOpacityCurveSH::Set(const Curve &pCurve)
{
if (pCurve.isIdentity()) {
Reset(); // raise this value if the quality suffers from this number of samples
return;
}
lutOpacityCurveSH(501); // raise this value if the quality suffers from this number of samples
for (int i = 0; i < 501; i++) {
lutOpacityCurveSH[i] = pCurve.getVal(double(i) / 500.);
}
}
void WavOpacityCurveSH::Set(const std::vector<double> &curvePoints)
{
if (!curvePoints.empty() && curvePoints[0] > FCT_Linear && curvePoints[0] < FCT_Unchanged) {
FlatCurve tcurve(curvePoints, false, CURVES_MIN_POLY_POINTS / 2);
tcurve.setIdentityValue(0.);
Set(tcurve);
} else {
Reset();
}
}
WavOpacityCurveBY::WavOpacityCurveBY() {}
void WavOpacityCurveBY::Reset()