LibreOffice Module basegfx (master) 1
Functions
basegfx::fTools Namespace Reference

Functions

double getSmallValue ()
 Get threshold value for equalZero and friends. More...
 
template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool equalZero (const T &rfVal)
 Compare against small value. More...
 
template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool equalZero (const T &rfVal, const T &rfSmallValue)
 Compare against given small value. More...
 
template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool equal (T const &rfValA, T const &rfValB)
 
template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool equal (const T &rfValA, const T &rfValB, const T &rfSmallValue)
 
template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool less (const T &rfValA, const T &rfValB)
 
template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool lessOrEqual (const T &rfValA, const T &rfValB)
 
template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool more (const T &rfValA, const T &rfValB)
 
template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool moreOrEqual (const T &rfValA, const T &rfValB)
 
template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool betweenOrEqualEither (const T &rfValA, const T &rfValB, const T &rfValC)
 

Function Documentation

◆ betweenOrEqualEither()

template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool basegfx::fTools::betweenOrEqualEither ( const T &  rfValA,
const T &  rfValB,
const T &  rfValC 
)
inline

Definition at line 206 of file ftools.hxx.

References equal().

Referenced by basegfx::B2DCubicBezier::testAndSolveTrivialBezier().

◆ equal() [1/2]

template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool basegfx::fTools::equal ( const T &  rfValA,
const T &  rfValB,
const T &  rfSmallValue 
)
inline

Definition at line 176 of file ftools.hxx.

◆ equal() [2/2]

template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool basegfx::fTools::equal ( T const &  rfValA,
T const &  rfValB 
)
inline

Definition at line 169 of file ftools.hxx.

Referenced by basegfx::utils::applyDefaultTextureCoordinatesSphere(), basegfx::areParallel(), betweenOrEqualEither(), basegfx::BColorStops::blendToIntensity(), basegfx::BColorStops::checkPenultimate(), basegfx::utils::createAreaGeometry(), basegfx::utils::createLineTrapezoidFromEdge(), basegfx::utils::createPolygonFromUnitEllipseSegment(), basegfx::utils::createScaleB2DHomMatrix(), basegfx::utils::createScaleShearXRotateTranslateB2DHomMatrix(), basegfx::utils::createScaleTranslateB2DHomMatrix(), basegfx::utils::createSourceRangeTargetRangeTransform(), basegfx::utils::createUnitSpherePolyPolygon(), basegfx::BasicRange< T, Traits >::equal(), basegfx::Tuple2D< TYPE >::equal(), basegfx::B3DHomMatrix::frustum(), basegfx::getContinuity(), basegfx::BColorStops::getInterpolatedBColor(), basegfx::utils::getSmallestDistancePointToPolygon(), basegfx::utils::getSmallestDistancePointToPolyPolygon(), basegfx::utils::getSnippetAbsolute(), basegfx::utils::hsv2rgb(), basegfx::init1DGradientInfo(), basegfx::initEllipticalGradientInfo(), basegfx::initRectGradientInfo(), basegfx::utils::isPointOnEdge(), basegfx::BColorStops::isSymmetrical(), less(), lessOrEqual(), more(), moreOrEqual(), basegfx::B2DVector::normalize(), basegfx::B3DPoint::operator*=(), basegfx::B3DHomMatrix::operator*=(), basegfx::B3DHomMatrix::operator/=(), basegfx::B3DHomMatrix::ortho(), basegfx::BColorStops::removeSpaceAtStart(), basegfx::B2DHomMatrix::scale(), basegfx::B3DHomMatrix::scale(), basegfx::utils::setContinuityInPoint(), basegfx::B2DVector::setLength(), basegfx::snapToNearestMultiple(), basegfx::snapToRange(), basegfx::B2DCubicBezier::snippet(), and basegfx::utils::synchronizeColorStops().

◆ equalZero() [1/2]

template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool basegfx::fTools::equalZero ( const T &  rfVal)
inline

Compare against small value.

Definition at line 156 of file ftools.hxx.

References getSmallValue().

Referenced by basegfx::InterpolatorProvider3D::addColorInterpolator(), basegfx::InterpolatorProvider3D::addInverseTextureInterpolator(), basegfx::InterpolatorProvider3D::addNormalInterpolator(), basegfx::InterpolatorProvider3D::addTextureInterpolator(), basegfx::utils::applyDefaultTextureCoordinatesParallel(), basegfx::utils::applyDefaultTextureCoordinatesSphere(), basegfx::utils::applyLineDashing(), basegfx::B3DTuple::correctValues(), basegfx::utils::createAreaGeometryForLineStartEnd(), basegfx::utils::createEdgesOfGivenLength(), basegfx::utils::createRotateAroundPoint(), basegfx::utils::createRotateB2DHomMatrix(), basegfx::utils::createScaleShearXRotateTranslateB2DHomMatrix(), basegfx::utils::createScaleTranslateB2DHomMatrix(), basegfx::utils::createShearXB2DHomMatrix(), basegfx::utils::createShearXRotateTranslateB2DHomMatrix(), basegfx::utils::createShearYB2DHomMatrix(), basegfx::utils::createSinCosOrthogonal(), basegfx::utils::createSourceRangeTargetRangeTransform(), basegfx::BColorStops::createSpaceAtStart(), basegfx::utils::createTranslateB2DHomMatrix(), basegfx::utils::createWaveline(), basegfx::B2DHomMatrix::decompose(), basegfx::B3DHomMatrix::decompose(), basegfx::utils::distort(), basegfx::BColorStops::doApplyAxial(), basegfx::BColorStops::doApplySteps(), basegfx::B3DTuple::equalZero(), basegfx::Tuple2D< TYPE >::equalZero(), basegfx::utils::findCut(), basegfx::B2DCubicBezier::getAllExtremumPositions(), basegfx::utils::getCutBetweenLineAndPlane(), basegfx::B2DSize::getLength(), basegfx::B2DVector::getLength(), basegfx::utils::getOrientation(), basegfx::getOrientation(), basegfx::utils::getPositionAbsolute(), basegfx::utils::getPositionRelative(), basegfx::utils::getSignedArea(), basegfx::utils::getSnippetAbsolute(), basegfx::utils::hsl2rgb(), basegfx::utils::hsv2rgb(), basegfx::init1DGradientInfo(), basegfx::initEllipticalGradientInfo(), basegfx::initRectGradientInfo(), basegfx::B2DHomMatrix::invert(), basegfx::B2DHomMatrix::isInvertible(), basegfx::B2DPolygon::isNextControlPointUsed(), basegfx::utils::isPointOnEdge(), basegfx::B2DPolygon::isPrevControlPointUsed(), basegfx::internal::ImplHomMatrixTemplate< RowSize >::lubksb(), basegfx::internal::ImplHomMatrixTemplate< RowSize >::ludcmp(), basegfx::B2DVector::normalize(), basegfx::B3DVector::normalize(), basegfx::B3DPoint::operator*=(), basegfx::BColorStops::removeSpaceAtStart(), basegfx::B2DPolygon::resetNextControlPoint(), basegfx::B2DPolygon::resetPrevControlPoint(), basegfx::utils::rgb2hsl(), basegfx::utils::rgb2hsv(), basegfx::B3DHomMatrix::rotate(), basegfx::B2DHomMatrix::rotate(), basegfx::B2DVector::setLength(), basegfx::B2IVector::setLength(), basegfx::B3DVector::setLength(), basegfx::B2DHomMatrix::shearX(), basegfx::B3DHomMatrix::shearXY(), basegfx::B3DHomMatrix::shearXZ(), basegfx::B2DHomMatrix::shearY(), basegfx::snapToNearestMultiple(), basegfx::snapToZeroRange(), basegfx::B2DCubicBezier::snippet(), basegfx::B2DCubicBezier::testAndSolveTrivialBezier(), basegfx::B2DHomMatrix::translate(), basegfx::B3DHomMatrix::translate(), and basegfx::BGradient::tryToRecreateBorder().

◆ equalZero() [2/2]

template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool basegfx::fTools::equalZero ( const T &  rfVal,
const T &  rfSmallValue 
)
inline

Compare against given small value.

Definition at line 163 of file ftools.hxx.

◆ getSmallValue()

double basegfx::fTools::getSmallValue ( )
inline

Get threshold value for equalZero and friends.

Definition at line 152 of file ftools.hxx.

Referenced by equalZero().

◆ less()

template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool basegfx::fTools::less ( const T &  rfValA,
const T &  rfValB 
)
inline

◆ lessOrEqual()

template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool basegfx::fTools::lessOrEqual ( const T &  rfValA,
const T &  rfValB 
)
inline

◆ more()

template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool basegfx::fTools::more ( const T &  rfValA,
const T &  rfValB 
)
inline

◆ moreOrEqual()

template<typename T , std::enable_if_t< std::is_floating_point_v< T >, int > = 0>
bool basegfx::fTools::moreOrEqual ( const T &  rfValA,
const T &  rfValB 
)
inline