24inline qreal calculateRelativeOpacityForLayer(
int currentLayerIndex,
int layerIndexNext,
float threshold)
26 int layerOffset = currentLayerIndex - layerIndexNext;
27 int absoluteOffset = qAbs(layerOffset);
28 qreal newOpacity = 1.0;
29 if (absoluteOffset != 0)
31 newOpacity = qPow(
static_cast<qreal
>(threshold), absoluteOffset);