LibreOffice Module basegfx (master) 1
Namespaces | Classes | Typedefs | Enumerations | Functions | Variables
basegfx Namespace Reference

Namespaces

namespace  fTools
 
namespace  internal
 
namespace  matrix
 
namespace  trapezoidhelper
 
namespace  triangulator
 
namespace  unotools
 
namespace  utils
 
namespace  zoomtools
 

Classes

class  B1DRange
 A one-dimensional interval over doubles. More...
 
class  B2DConnectedRanges
 Calculate connected ranges from input ranges. More...
 
class  B2DCubicBezier
 
class  B2DCubicBezierHelper
 
class  B2DHomMatrix
 
class  B2DPoint
 Base Point class with two double values. More...
 
class  B2DPolygon
 
class  B2DPolyPolygon
 
class  B2DPolyRange
 Multiple ranges in one object. More...
 
class  B2DRange
 A two-dimensional interval over doubles. More...
 
class  B2DSize
 
class  B2DTuple
 Base class for all Points/Vectors with two double values. More...
 
class  B2DVector
 Base Point class with two double values. More...
 
class  B2I64Tuple
 Base class for all Points/Vectors with two sal_Int64 values. More...
 
class  B2IBox
 A two-dimensional interval over integers. More...
 
class  B2IPoint
 Base Point class with two sal_Int32 values. More...
 
class  B2IRange
 A two-dimensional interval over integers. More...
 
class  B2ISize
 
class  B2ITuple
 Base class for all Points/Vectors with two sal_Int32 values. More...
 
class  B2IVector
 Base Point class with two sal_Int32 values. More...
 
class  B3DHomMatrix
 
class  B3DPoint
 Base Point class with three double values. More...
 
class  B3DPolygon
 
class  B3DPolyPolygon
 
class  B3DRange
 
class  B3DTuple
 Base class for all Points/Vectors with three double values. More...
 
class  B3DVector
 Base Point class with three double values. More...
 
class  B3ITuple
 Base class for all Points/Vectors with three sal_Int32 values. More...
 
class  BasicBox
 Explicitly different from BasicRange, handling the inside predicates differently. More...
 
class  BasicRange
 
class  BColor
 Base Color class with three double values. More...
 
class  BColorModifier
 base class to define color modifications More...
 
class  BColorModifier_black_and_white
 convert color to black and white More...
 
class  BColorModifier_gray
 convert color to gray More...
 
class  BColorModifier_hueRotate
 Apply hueRotate This derivation is used for the svg importer and does exactly what SVG defines for this needed case. More...
 
class  BColorModifier_interpolate
 interpolate color More...
 
class  BColorModifier_invert
 invert color More...
 
class  BColorModifier_luminance_to_alpha
 convert to alpha based on luminance More...
 
class  BColorModifier_matrix
 Apply matrix This derivation is used for the svg importer and does exactly what SVG defines for this needed case. More...
 
class  BColorModifier_randomize
 gamma correction More...
 
class  BColorModifier_replace
 replace color More...
 
class  BColorModifier_saturate
 Apply saturation This derivation is used for the svg importer and does exactly what SVG defines for this needed case. More...
 
class  BColorModifierStack
 Class to hold a stack of BColorModifierSharedPtrs and to get the modified color with applying all existing entry changes as defined in the stack. More...
 
class  BColorStop
 
class  BColorStops
 
class  BGradient
 
class  BPixel
 
class  BZPixelRaster
 
struct  DoubleTraits
 
class  Impl3DHomMatrix
 
class  ImplB2DPolyPolygon
 
class  ImplB2DPolyRange
 
struct  Int32Traits
 
class  InterpolatorProvider3D
 
class  ip_double
 
class  ip_single
 
class  ip_triple
 
class  Range2D
 
class  RasterConversionLineEntry3D
 
class  Size2D
 
class  SystemDependentData
 
class  SystemDependentDataHolder
 
class  SystemDependentDataManager
 
class  Tuple2D
 
class  Tuple3D
 

Typedefs

typedef ::basegfx::internal::ImplHomMatrixTemplate< 4 > Impl3DHomMatrix_Base
 
typedef std::shared_ptr< BColorModifierBColorModifierSharedPtr
 typedef to allow working with shared instances of BColorModifier for the whole mechanism More...
 
typedef std::shared_ptr< SystemDependentDataSystemDependentData_SharedPtr
 
typedef ::std::vector< B2DPolygonB2DPolygonVector
 
typedef ::std::vector< B2DPolyPolygonB2DPolyPolygonVector
 
typedef ::std::vector< B2DTrapezoid > B2DTrapezoidVector
 
typedef B2DRange B2DRectangle
 Alias name for interface clarity (not everybody is aware of the identity) More...
 
typedef B2IRange B2IRectangle
 Alias name for interface clarity (not everybody is aware of the identity) More...
 
typedef std::weak_ptr< SystemDependentDataSystemDependentData_WeakPtr
 

Enumerations

enum class  Axis2D {
  X ,
  Y
}
 
enum class  B2VectorOrientation {
  Positive = 0 ,
  Negative ,
  Neutral
}
 Descriptor for the mathematical orientations of two 2D Vectors. More...
 
enum class  B2VectorContinuity {
  NONE = 0 ,
  C1 ,
  C2
}
 Descriptor for the mathematical continuity of two 2D Vectors. More...
 
enum class  B2DLineJoin {
  NONE = 0 ,
  Bevel = 2 ,
  Miter = 3 ,
  Round = 4
}
 Descriptor for possible line joins between two line segments. More...
 

Functions

double snapToNearestMultiple (double v, const double fStep)
 Snap v to nearest multiple of fStep, from negative and positive side. More...
 
double snapToZeroRange (double v, double fWidth)
 Snap v to the range [0.0 . More...
 
double snapToRange (double v, double fLow, double fHigh)
 Snap v to the range [fLow . More...
 
double normalizeToRange (double v, const double fRange)
 RotateFlyFrame3: Normalize to range defined by [0.0 ... fRange[, independent if v is positive or negative. More...
 
B2DPoint operator* (const ::basegfx::B2DHomMatrix &rMat, const B2DPoint &rPoint)
 
B3DPoint operator* (const ::basegfx::B3DHomMatrix &rMat, const B3DPoint &rPoint)
 
BASEGFX_DLLPUBLIC B2DPolygon createWaveLinePolygon (basegfx::B2DRectangle const &rRectangle)
 
B2IRange fround (const B2DRange &rRange)
 Round double to nearest integer for 2D range. More...
 
B2DRange operator* (const ::basegfx::B2DHomMatrix &rMat, const B2DRange &rB2DRange)
 
std::vector< B2IRange > & computeSetDifference (std::vector< B2IRange > &o_rResult, const B2IRange &rFirst, const B2IRange &rSecond)
 Compute the set difference of the two given ranges. More...
 
std::vector< B2DRange > & computeSetDifference (std::vector< B2DRange > &o_rResult, const B2DRange &rFirst, const B2DRange &rSecond)
 Compute the set difference of the two given ranges. More...
 
B3DRange operator* (const ::basegfx::B3DHomMatrix &rMat, const B3DRange &rB3DRange)
 
static ODFGradientInfo init1DGradientInfo (const B2DRange &rTargetRange, sal_uInt32 nSteps, double fBorder, double fAngle, bool bAxial)
 Most of the setup for linear & axial gradient is the same, except for the border treatment. More...
 
static ODFGradientInfo initEllipticalGradientInfo (const B2DRange &rTargetRange, const B2DVector &rOffset, sal_uInt32 nSteps, double fBorder, double fAngle, bool bCircular)
 Most of the setup for radial & ellipsoidal gradient is the same, except for the border treatment. More...
 
static ODFGradientInfo initRectGradientInfo (const B2DRange &rTargetRange, const B2DVector &rOffset, sal_uInt32 nSteps, double fBorder, double fAngle, bool bSquare)
 Setup for rect & square gradient is exactly the same. More...
 
B2ITuple fround (const B2DTuple &rTup)
 Round double to nearest integer for 2D tuple. More...
 
B3ITuple fround (const B3DTuple &rTup)
 Round double to nearest integer for 3D tuple. More...
 
bool areParallel (const B2DVector &rVecA, const B2DVector &rVecB)
 Test two vectors which need not to be normalized for parallelism. More...
 
B2VectorOrientation getOrientation (const B2DVector &rVecA, const B2DVector &rVecB)
 Calculate the orientation to another 2D Vector. More...
 
B2DVector getPerpendicular (const B2DVector &rNormalizedVec)
 Calculate a perpendicular 2D Vector to the given one. More...
 
B2DVector getNormalizedPerpendicular (const B2DVector &rVec)
 Calculate a perpendicular 2D Vector to the given one, normalize the given one as preparation. More...
 
B2DVector operator* (const B2DHomMatrix &rMat, const B2DVector &rVec)
 Transform vector by given transformation matrix. More...
 
B2VectorContinuity getContinuity (const B2DVector &rBackVector, const B2DVector &rForwardVector)
 Test continuity between given vectors. More...
 
B3DVector operator* (const ::basegfx::B3DHomMatrix &rMat, const B3DVector &rVec)
 
bool areParallel (const B3DVector &rVecA, const B3DVector &rVecB)
 Test two vectors which need not to be normalized for parallelism. More...
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, BColor const &color)
 
B2DHomMatrix operator* (const B2DHomMatrix &rMatA, const B2DHomMatrix &rMatB)
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, B2DHomMatrix const &matrix)
 
B3DHomMatrix operator* (const B3DHomMatrix &rMatA, const B3DHomMatrix &rMatB)
 
sal_Int32 fround (double fVal)
 Round double to nearest integer. More...
 
sal_Int64 fround64 (double fVal)
 Round double to nearest integer. More...
 
double pruneScaleValue (double fVal)
 Prune a small epsilon range around zero. More...
 
template<int DegMultiple = 1>
constexpr double deg2rad (double v)
 Convert value from degrees to radians. More...
 
template<int DegMultiple = 1>
constexpr double rad2deg (double v)
 Convert value radians to degrees. More...
 
double copySign (double fValue, double fSignCarrier)
 return fValue with the sign of fSignCarrier, thus evtl. More...
 
BASEGFX_DLLPUBLIC B2DPoint operator* (const B2DHomMatrix &rMat, const B2DPoint &rPoint)
 Transform B2DPoint by given transformation matrix. More...
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, const B2DPoint &point)
 
BASEGFX_DLLPUBLIC B3DPoint operator* (const B3DHomMatrix &rMat, const B3DPoint &rPoint)
 Transform B3DPoint by given transformation matrix. More...
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, const B2DPolygon &poly)
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, const B2DPolyPolygon &poly)
 
class UNLESS_MERGELIBS (BASEGFX_DLLPUBLIC) ODFGradientInfo
 Gradient definition as used in ODF 1.2. More...
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, const B1DRange &range)
 Write to char stream. More...
 
B2DRange operator* (const B2DHomMatrix &rMat, const B2DRange &rB2DRange)
 Transform B2DRange by given transformation matrix (see operator*=()) More...
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, const B2DRange &range)
 Write to char stream. More...
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, const B2IRange &range)
 Write to char stream. More...
 
B3DRange operator* (const B3DHomMatrix &rMat, const B3DRange &rB2DRange)
 Transform B3DRange by given transformation matrix (see operator*=()) More...
 
B2DTuple absolute (const B2DTuple &rTup)
 
B2DTuple interpolate (const B2DTuple &rOld1, const B2DTuple &rOld2, double t)
 
B2DTuple average (const B2DTuple &rOld1, const B2DTuple &rOld2)
 
B2DTuple operator* (const B2DTuple &rTup, double t)
 
B2DTuple operator* (double t, const B2DTuple &rTup)
 
B2DTuple operator/ (const B2DTuple &rTup, double t)
 
B2ITuple operator+ (const B2ITuple &rTupA, const B2ITuple &rTupB)
 
B2ITuple operator- (const B2ITuple &rTupA, const B2ITuple &rTupB)
 
B2ITuple operator* (sal_Int32 t, const B2ITuple &rTup)
 
B3DTuple interpolate (const B3DTuple &rOld1, const B3DTuple &rOld2, double t)
 
B3DTuple average (const B3DTuple &rOld1, const B3DTuple &rOld2)
 
B3DTuple operator+ (const B3DTuple &rTupA, const B3DTuple &rTupB)
 
B3DTuple operator- (const B3DTuple &rTupA, const B3DTuple &rTupB)
 
B3DTuple operator* (const B3DTuple &rTupA, const B3DTuple &rTupB)
 
B3DTuple operator* (const B3DTuple &rTup, double t)
 
B3DTuple operator/ (const B3DTuple &rTup, double t)
 
template<typename TYPE >
Size2D< TYPE > operator- (const Size2D< TYPE > &rSizeA, const Size2D< TYPE > &rSizeB)
 
template<typename TYPE >
Size2D< TYPE > operator+ (const Size2D< TYPE > &rSizeA, const Size2D< TYPE > &rSizeB)
 
template<typename TYPE >
Size2D< TYPE > operator* (const Size2D< TYPE > &rSizeA, const Size2D< TYPE > &rSizeB)
 
template<typename TYPE >
Size2D< TYPE > operator/ (const Size2D< TYPE > &rSizeA, const Size2D< TYPE > &rSizeB)
 
template<typename TYPE >
Tuple2D< TYPE > operator- (const Tuple2D< TYPE > &rTupA, const Tuple2D< TYPE > &rTupB)
 
template<typename TYPE >
Tuple2D< TYPE > operator+ (const Tuple2D< TYPE > &rTupA, const Tuple2D< TYPE > &rTupB)
 
template<typename TYPE >
Tuple2D< TYPE > operator* (const Tuple2D< TYPE > &rTupA, const Tuple2D< TYPE > &rTupB)
 
template<typename TYPE >
Tuple2D< TYPE > operator/ (const Tuple2D< TYPE > &rTupA, const Tuple2D< TYPE > &rTupB)
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, const B2DSize &size)
 
B2DSize operator* (B2DHomMatrix const &rMatrix, B2DSize const &rSize)
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, const B2ISize &size)
 
template<typename charT , typename traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &stream, const basegfx::B2IVector &vector)
 
BASEGFX_DLLPUBLIC B3DVector operator* (const B3DHomMatrix &rMat, const B3DVector &rVec)
 Transform vector by given transformation matrix. More...
 
B3DVector cross (const B3DVector &rVecA, const B3DVector &rVecB)
 Calculate the Cross Product of two 3D Vectors. More...
 

Variables

constexpr int RowSize = 3
 
static o3tl::cow_wrapper< ImplB2DPolygonDEFAULT
 

Typedef Documentation

◆ B2DPolygonVector

typedef ::std::vector< B2DPolygon > basegfx::B2DPolygonVector

Definition at line 262 of file b2dpolygon.hxx.

◆ B2DPolyPolygonVector

Definition at line 151 of file b2dpolypolygon.hxx.

◆ B2DRectangle

Alias name for interface clarity (not everybody is aware of the identity)

Definition at line 30 of file b2drectangle.hxx.

◆ B2DTrapezoidVector

typedef ::std::vector< B2DTrapezoid > basegfx::B2DTrapezoidVector

Definition at line 73 of file b2dtrapezoid.hxx.

◆ B2IRectangle

Alias name for interface clarity (not everybody is aware of the identity)

Definition at line 30 of file b2irectangle.hxx.

◆ BColorModifierSharedPtr

typedef to allow working with shared instances of BColorModifier for the whole mechanism

Definition at line 406 of file bcolormodifier.hxx.

◆ Impl3DHomMatrix_Base

Definition at line 27 of file b3dhommatrix.cxx.

◆ SystemDependentData_SharedPtr

Definition at line 42 of file b2dpolygon.hxx.

◆ SystemDependentData_WeakPtr

Definition at line 21 of file systemdependentdata.hxx.

Enumeration Type Documentation

◆ Axis2D

enum class basegfx::Axis2D
strong
Enumerator

Definition at line 25 of file common.hxx.

◆ B2DLineJoin

enum class basegfx::B2DLineJoin
strong

Descriptor for possible line joins between two line segments.

Note: WriteLineInfo/ReadLineInfo stream these values for svm file format

Enumerator
NONE 
Bevel 
Miter 
Round 

Definition at line 57 of file b2enums.hxx.

◆ B2VectorContinuity

enum class basegfx::B2VectorContinuity
strong

Descriptor for the mathematical continuity of two 2D Vectors.

Enumerator
NONE 

none

C1 

mathematically negative oriented

C2 

mathematically neutral, thus parallel

Definition at line 40 of file b2enums.hxx.

◆ B2VectorOrientation

enum class basegfx::B2VectorOrientation
strong

Descriptor for the mathematical orientations of two 2D Vectors.

Enumerator
Positive 

mathematically positive oriented

Negative 

mathematically negative oriented

Neutral 

mathematically neutral, thus parallel

Definition at line 26 of file b2enums.hxx.

Function Documentation

◆ absolute()

B2DTuple basegfx::absolute ( const B2DTuple rTup)
inline

◆ areParallel() [1/2]

BASEGFX_DLLPUBLIC bool basegfx::areParallel ( const B2DVector rVecA,
const B2DVector rVecB 
)

Test two vectors which need not to be normalized for parallelism.

Parameters
rVecAThe first 2D Vector
rVecBThe second 2D Vector
Returns
bool if the two values are parallel. Also true if one of the vectors is empty.

Definition at line 111 of file b2dvector.cxx.

References basegfx::fTools::equal(), basegfx::Tuple2D< TYPE >::getX(), and basegfx::Tuple2D< TYPE >::getY().

Referenced by getContinuity(), and basegfx::utils::isPointOnLine().

◆ areParallel() [2/2]

BASEGFX_DLLPUBLIC bool basegfx::areParallel ( const B3DVector rVecA,
const B3DVector rVecB 
)

Test two vectors which need not to be normalized for parallelism.

Parameters
rVecAThe first 3D Vector
rVecBThe second 3D Vector
Returns
bool if the two values are parallel. Also true if one of the vectors is empty.

Definition at line 72 of file b3dvector.cxx.

References basegfx::fTools::equal(), basegfx::Tuple3D< TYPE >::getX(), basegfx::Tuple3D< TYPE >::getY(), and basegfx::Tuple3D< TYPE >::getZ().

◆ average() [1/2]

B2DTuple basegfx::average ( const B2DTuple rOld1,
const B2DTuple rOld2 
)
inline

◆ average() [2/2]

B3DTuple basegfx::average ( const B3DTuple rOld1,
const B3DTuple rOld2 
)
inline

◆ computeSetDifference() [1/2]

BASEGFX_DLLPUBLIC std::vector< B2DRange > & basegfx::computeSetDifference ( std::vector< B2DRange > &  o_rResult,
const B2DRange rFirst,
const B2DRange rSecond 
)

Compute the set difference of the two given ranges.

This method calculates the symmetric difference (aka XOR) between the two given ranges, and returning the resulting ranges. Thus, the result will contain all areas where one, but not both ranges lie.

Parameters
o_rResultResult vector. The up to four difference ranges are returned within this vector
rFirstThe first range
rSecondThe second range
Returns
the input vector

Definition at line 109 of file b2xrange.cxx.

◆ computeSetDifference() [2/2]

BASEGFX_DLLPUBLIC std::vector< B2IRange > & basegfx::computeSetDifference ( std::vector< B2IRange > &  o_rResult,
const B2IRange rFirst,
const B2IRange rSecond 
)

Compute the set difference of the two given ranges.

This method calculates the symmetric difference (aka XOR) between the two given ranges, and returning the resulting ranges. Thus, the result will contain all areas where one, but not both ranges lie.

Parameters
o_rResultResult vector. The up to four difference ranges are returned within this vector
rFirstThe first range
rSecondThe second range
Returns
the input vector

Definition at line 100 of file b2xrange.cxx.

◆ copySign()

double basegfx::copySign ( double  fValue,
double  fSignCarrier 
)
inline

return fValue with the sign of fSignCarrier, thus evtl.

changed

Definition at line 120 of file ftools.hxx.

◆ createWaveLinePolygon()

BASEGFX_DLLPUBLIC B2DPolygon basegfx::createWaveLinePolygon ( basegfx::B2DRectangle const &  rRectangle)

◆ cross()

B3DVector basegfx::cross ( const B3DVector rVecA,
const B3DVector rVecB 
)
inline

Calculate the Cross Product of two 3D Vectors.

Parameters
rVecAA first 3D Vector.
rVecBA second 3D Vector.
Returns
The Cross Product of both 3D Vectors

Definition at line 248 of file b3dvector.hxx.

References basegfx::Tuple3D< TYPE >::getX(), basegfx::Tuple3D< TYPE >::getY(), and basegfx::Tuple3D< TYPE >::getZ().

Referenced by basegfx::B3DVector::getPerpendicular().

◆ deg2rad()

template<int DegMultiple = 1>
constexpr double basegfx::deg2rad ( double  v)
constexpr

Convert value from degrees to radians.

Definition at line 82 of file ftools.hxx.

References v.

Referenced by basegfx::B2DCubicBezier::adaptiveSubdivideByAngle(), and basegfx::utils::importFromSvgD().

◆ fround() [1/4]

BASEGFX_DLLPUBLIC B2IRange basegfx::fround ( const B2DRange rRange)

◆ fround() [2/4]

BASEGFX_DLLPUBLIC B2ITuple basegfx::fround ( const B2DTuple rTup)

Round double to nearest integer for 2D tuple.

Returns
the nearest integer for this tuple

Definition at line 36 of file b2dtuple.cxx.

References fround(), basegfx::Tuple2D< TYPE >::getX(), and basegfx::Tuple2D< TYPE >::getY().

◆ fround() [3/4]

BASEGFX_DLLPUBLIC B3ITuple basegfx::fround ( const B3DTuple rTup)

Round double to nearest integer for 3D tuple.

Returns
the nearest integer for this tuple

Definition at line 31 of file b3dtuple.cxx.

References fround(), basegfx::Tuple3D< TYPE >::getX(), basegfx::Tuple3D< TYPE >::getY(), and basegfx::Tuple3D< TYPE >::getZ().

◆ fround() [4/4]

sal_Int32 basegfx::fround ( double  fVal)
inline

Round double to nearest integer.

Returns
the nearest integer

Definition at line 38 of file ftools.hxx.

◆ fround64()

sal_Int64 basegfx::fround64 ( double  fVal)
inline

Round double to nearest integer.

Returns
the nearest 64 bit integer

Definition at line 55 of file ftools.hxx.

◆ getContinuity()

BASEGFX_DLLPUBLIC B2VectorContinuity basegfx::getContinuity ( const B2DVector rBackVector,
const B2DVector rForwardVector 
)

Test continuity between given vectors.

The two given vectors are assumed to describe control points on a common point. Calculate if there is a continuity between them.

Definition at line 161 of file b2dvector.cxx.

References areParallel(), C1, C2, basegfx::fTools::equal(), basegfx::Tuple2D< TYPE >::equalZero(), basegfx::Tuple2D< TYPE >::getX(), basegfx::Tuple2D< TYPE >::getY(), NONE, and basegfx::B2DVector::scalar().

Referenced by basegfx::B2DPolygon::getContinuityInPoint().

◆ getNormalizedPerpendicular()

BASEGFX_DLLPUBLIC B2DVector basegfx::getNormalizedPerpendicular ( const B2DVector rVec)

Calculate a perpendicular 2D Vector to the given one, normalize the given one as preparation.

Parameters
rVecThe source 2D Vector
Returns
A normalized 2D Vector perpendicular to the one given in parameter rVec

Definition at line 144 of file b2dvector.cxx.

References basegfx::Tuple2D< TYPE >::getX(), basegfx::Tuple2D< TYPE >::getY(), basegfx::B2DVector::normalize(), basegfx::Tuple2D< TYPE >::setX(), and basegfx::Tuple2D< TYPE >::setY().

Referenced by basegfx::utils::createWaveline(), basegfx::utils::growInNormalDirection(), and basegfx::utils::setContinuityInPoint().

◆ getOrientation()

BASEGFX_DLLPUBLIC B2VectorOrientation basegfx::getOrientation ( const B2DVector rVecA,
const B2DVector rVecB 
)

Calculate the orientation to another 2D Vector.

Parameters
rVecAThe first 2D Vector
rVecBThe second 2D Vector
Returns
The mathematical Orientation of the two involved 2D Vectors

Definition at line 119 of file b2dvector.cxx.

References basegfx::fTools::equalZero(), basegfx::Tuple2D< TYPE >::getX(), basegfx::Tuple2D< TYPE >::getY(), Negative, Neutral, and Positive.

◆ getPerpendicular()

BASEGFX_DLLPUBLIC B2DVector basegfx::getPerpendicular ( const B2DVector rNormalizedVec)

Calculate a perpendicular 2D Vector to the given one.

Parameters
rVecThe source 2D Vector
Attention: \n This only works if the given 2D Vector is normalized.
Returns
A 2D Vector perpendicular to the one given in parameter rVec

Definition at line 138 of file b2dvector.cxx.

References basegfx::Tuple2D< TYPE >::getX(), and basegfx::Tuple2D< TYPE >::getY().

Referenced by basegfx::utils::createAreaGeometry(), and basegfx::utils::isInEpsilonRange().

◆ init1DGradientInfo()

static ODFGradientInfo basegfx::init1DGradientInfo ( const B2DRange rTargetRange,
sal_uInt32  nSteps,
double  fBorder,
double  fAngle,
bool  bAxial 
)
static

◆ initEllipticalGradientInfo()

static ODFGradientInfo basegfx::initEllipticalGradientInfo ( const B2DRange rTargetRange,
const B2DVector rOffset,
sal_uInt32  nSteps,
double  fBorder,
double  fAngle,
bool  bCircular 
)
static

◆ initRectGradientInfo()

static ODFGradientInfo basegfx::initRectGradientInfo ( const B2DRange rTargetRange,
const B2DVector rOffset,
sal_uInt32  nSteps,
double  fBorder,
double  fAngle,
bool  bSquare 
)
static

◆ interpolate() [1/2]

B2DTuple basegfx::interpolate ( const B2DTuple rOld1,
const B2DTuple rOld2,
double  t 
)
inline

◆ interpolate() [2/2]

B3DTuple basegfx::interpolate ( const B3DTuple rOld1,
const B3DTuple rOld2,
double  t 
)
inline

◆ normalizeToRange()

BASEGFX_DLLPUBLIC double basegfx::normalizeToRange ( double  v,
const double  fRange 
)

RotateFlyFrame3: Normalize to range defined by [0.0 ... fRange[, independent if v is positive or negative.

Examples:

normalizeToRange(0.5, -1.0) = 0.0 normalizeToRange(0.5, 0.0) = 0.0 normalizeToRange(0.5, 1.0) = 0.5 normalizeToRange(-0.5, 1.0) = 0.5 normalizeToRange(-0.3, 1.0) = 0.7 normalizeToRange(-0.7, 1.0) = 0.3 normalizeToRange(3.5, 1.0) = 0.5 normalizeToRange(3.3, 1.0) = 0.3 normalizeToRange(3.7, 1.0) = 0.7 normalizeToRange(-3.5, 1.0) = 0.5 normalizeToRange(-3.3, 1.0) = 0.7 normalizeToRange(-3.7, 1.0) = 0.3

Definition at line 100 of file ftools.cxx.

References basegfx::fTools::less(), basegfx::fTools::lessOrEqual(), basegfx::fTools::moreOrEqual(), and v.

◆ operator*() [1/21]

B2DSize basegfx::operator* ( B2DHomMatrix const &  rMatrix,
B2DSize const &  rSize 
)
inline

Definition at line 91 of file b2dsize.hxx.

◆ operator*() [2/21]

B2DPoint basegfx::operator* ( const ::basegfx::B2DHomMatrix rMat,
const B2DPoint rPoint 
)

Definition at line 43 of file b2dpoint.cxx.

◆ operator*() [3/21]

B2DRange basegfx::operator* ( const ::basegfx::B2DHomMatrix rMat,
const B2DRange rB2DRange 
)

Definition at line 72 of file b2drange.cxx.

◆ operator*() [4/21]

B3DPoint basegfx::operator* ( const ::basegfx::B3DHomMatrix rMat,
const B3DPoint rPoint 
)

Definition at line 68 of file b3dpoint.cxx.

◆ operator*() [5/21]

B3DRange basegfx::operator* ( const ::basegfx::B3DHomMatrix rMat,
const B3DRange rB3DRange 
)

Definition at line 55 of file b3drange.cxx.

◆ operator*() [6/21]

B3DVector basegfx::operator* ( const ::basegfx::B3DHomMatrix rMat,
const B3DVector rVec 
)

Definition at line 65 of file b3dvector.cxx.

◆ operator*() [7/21]

BASEGFX_DLLPUBLIC B2DPoint basegfx::operator* ( const B2DHomMatrix rMat,
const B2DPoint rPoint 
)

Transform B2DPoint by given transformation matrix.

Since this is a Point, translational components of the matrix are used.

References point(), and stream.

◆ operator*() [8/21]

B2DRange basegfx::operator* ( const B2DHomMatrix rMat,
const B2DRange rB2DRange 
)

Transform B2DRange by given transformation matrix (see operator*=())

◆ operator*() [9/21]

BASEGFX_DLLPUBLIC B2DVector basegfx::operator* ( const B2DHomMatrix rMat,
const B2DVector rVec 
)

Transform vector by given transformation matrix.

Since this is a vector, translational components of the matrix are disregarded.

Definition at line 154 of file b2dvector.cxx.

◆ operator*() [10/21]

B2DHomMatrix basegfx::operator* ( const B2DHomMatrix rMatA,
const B2DHomMatrix rMatB 
)
inline

Definition at line 141 of file b2dhommatrix.hxx.

◆ operator*() [11/21]

B2DTuple basegfx::operator* ( const B2DTuple rTup,
double  t 
)
inline

Definition at line 125 of file b2dtuple.hxx.

References t.

◆ operator*() [12/21]

BASEGFX_DLLPUBLIC B3DPoint basegfx::operator* ( const B3DHomMatrix rMat,
const B3DPoint rPoint 
)

Transform B3DPoint by given transformation matrix.

Since this is a Point, translational components of the matrix are used.

◆ operator*() [13/21]

B3DRange basegfx::operator* ( const B3DHomMatrix rMat,
const B3DRange rB2DRange 
)

Transform B3DRange by given transformation matrix (see operator*=())

◆ operator*() [14/21]

BASEGFX_DLLPUBLIC B3DVector basegfx::operator* ( const B3DHomMatrix rMat,
const B3DVector rVec 
)

Transform vector by given transformation matrix.

Since this is a vector, translational components of the matrix are disregarded.

◆ operator*() [15/21]

B3DHomMatrix basegfx::operator* ( const B3DHomMatrix rMatA,
const B3DHomMatrix rMatB 
)
inline

Definition at line 119 of file b3dhommatrix.hxx.

◆ operator*() [16/21]

B3DTuple basegfx::operator* ( const B3DTuple rTup,
double  t 
)
inline

Definition at line 218 of file b3dtuple.hxx.

References t.

◆ operator*() [17/21]

B3DTuple basegfx::operator* ( const B3DTuple rTupA,
const B3DTuple rTupB 
)
inline

Definition at line 211 of file b3dtuple.hxx.

◆ operator*() [18/21]

template<typename TYPE >
Size2D< TYPE > basegfx::operator* ( const Size2D< TYPE > &  rSizeA,
const Size2D< TYPE > &  rSizeB 
)
inline

Definition at line 100 of file Size2D.hxx.

◆ operator*() [19/21]

template<typename TYPE >
Tuple2D< TYPE > basegfx::operator* ( const Tuple2D< TYPE > &  rTupA,
const Tuple2D< TYPE > &  rTupB 
)
inline

Definition at line 174 of file Tuple2D.hxx.

◆ operator*() [20/21]

B2DTuple basegfx::operator* ( double  t,
const B2DTuple rTup 
)
inline

Definition at line 132 of file b2dtuple.hxx.

References t.

◆ operator*() [21/21]

B2ITuple basegfx::operator* ( sal_Int32  t,
const B2ITuple rTup 
)
inline

Definition at line 86 of file b2ituple.hxx.

References t.

◆ operator+() [1/4]

B2ITuple basegfx::operator+ ( const B2ITuple rTupA,
const B2ITuple rTupB 
)
inline

Definition at line 72 of file b2ituple.hxx.

◆ operator+() [2/4]

B3DTuple basegfx::operator+ ( const B3DTuple rTupA,
const B3DTuple rTupB 
)
inline

Definition at line 197 of file b3dtuple.hxx.

◆ operator+() [3/4]

template<typename TYPE >
Size2D< TYPE > basegfx::operator+ ( const Size2D< TYPE > &  rSizeA,
const Size2D< TYPE > &  rSizeB 
)
inline

Definition at line 92 of file Size2D.hxx.

◆ operator+() [4/4]

template<typename TYPE >
Tuple2D< TYPE > basegfx::operator+ ( const Tuple2D< TYPE > &  rTupA,
const Tuple2D< TYPE > &  rTupB 
)
inline

Definition at line 166 of file Tuple2D.hxx.

◆ operator-() [1/4]

B2ITuple basegfx::operator- ( const B2ITuple rTupA,
const B2ITuple rTupB 
)
inline

Definition at line 79 of file b2ituple.hxx.

◆ operator-() [2/4]

B3DTuple basegfx::operator- ( const B3DTuple rTupA,
const B3DTuple rTupB 
)
inline

Definition at line 204 of file b3dtuple.hxx.

◆ operator-() [3/4]

template<typename TYPE >
Size2D< TYPE > basegfx::operator- ( const Size2D< TYPE > &  rSizeA,
const Size2D< TYPE > &  rSizeB 
)
inline

Definition at line 84 of file Size2D.hxx.

◆ operator-() [4/4]

template<typename TYPE >
Tuple2D< TYPE > basegfx::operator- ( const Tuple2D< TYPE > &  rTupA,
const Tuple2D< TYPE > &  rTupB 
)
inline

Definition at line 158 of file Tuple2D.hxx.

◆ operator/() [1/4]

B2DTuple basegfx::operator/ ( const B2DTuple rTup,
double  t 
)
inline

Definition at line 139 of file b2dtuple.hxx.

References t.

◆ operator/() [2/4]

B3DTuple basegfx::operator/ ( const B3DTuple rTup,
double  t 
)
inline

Definition at line 225 of file b3dtuple.hxx.

References t.

◆ operator/() [3/4]

template<typename TYPE >
Size2D< TYPE > basegfx::operator/ ( const Size2D< TYPE > &  rSizeA,
const Size2D< TYPE > &  rSizeB 
)
inline

Definition at line 108 of file Size2D.hxx.

◆ operator/() [4/4]

template<typename TYPE >
Tuple2D< TYPE > basegfx::operator/ ( const Tuple2D< TYPE > &  rTupA,
const Tuple2D< TYPE > &  rTupB 
)
inline

Definition at line 182 of file Tuple2D.hxx.

◆ operator<<() [1/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
B2DHomMatrix const &  matrix 
)

Definition at line 141 of file b2dhommatrix.hxx.

◆ operator<<() [2/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
BColor const &  color 
)

Definition at line 40 of file bcolor.hxx.

References SAL_WARN_UNUSED.

◆ operator<<() [3/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
const B1DRange range 
)
inline

Write to char stream.

Definition at line 1 of file b1drange.hxx.

◆ operator<<() [4/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
const B2DPoint point 
)
inline

Definition at line 134 of file b2dpoint.hxx.

◆ operator<<() [5/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
const B2DPolygon poly 
)
inline

Definition at line 262 of file b2dpolygon.hxx.

◆ operator<<() [6/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
const B2DPolyPolygon poly 
)
inline

Definition at line 151 of file b2dpolypolygon.hxx.

◆ operator<<() [7/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
const B2DRange range 
)
inline

Write to char stream.

Definition at line 160 of file b2drange.hxx.

References stream.

◆ operator<<() [8/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
const B2DSize size 
)
inline

Definition at line 1 of file b2dsize.hxx.

◆ operator<<() [9/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
const B2IRange range 
)
inline

Write to char stream.

Definition at line 123 of file b2irange.hxx.

References stream.

◆ operator<<() [10/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
const B2ISize size 
)
inline

Definition at line 1 of file b2isize.hxx.

◆ operator<<() [11/11]

template<typename charT , typename traits >
std::basic_ostream< charT, traits > & basegfx::operator<< ( std::basic_ostream< charT, traits > &  stream,
const basegfx::B2IVector vector 
)
inline

Definition at line 39 of file b2ivector.hxx.

◆ pruneScaleValue()

double basegfx::pruneScaleValue ( double  fVal)
inline

Prune a small epsilon range around zero.

Use this method e.g. for calculating scale values. There, it is usually advisable not to set a scaling to 0.0, because that yields singular transformation matrices.

Parameters
fValAn arbitrary, but finite and valid number
Returns
either fVal, or a small value slightly above (when fVal>0) or below (when fVal<0) zero.

Definition at line 72 of file ftools.hxx.

◆ rad2deg()

template<int DegMultiple = 1>
constexpr double basegfx::rad2deg ( double  v)
constexpr

Convert value radians to degrees.

Definition at line 91 of file ftools.hxx.

References v.

◆ snapToNearestMultiple()

BASEGFX_DLLPUBLIC double basegfx::snapToNearestMultiple ( double  v,
const double  fStep 
)

Snap v to nearest multiple of fStep, from negative and positive side.

Examples:

snapToNearestMultiple(-0.1, 0.5) = 0.0 snapToNearestMultiple(0.1, 0.5) = 0.0 snapToNearestMultiple(0.25, 0.5) = 0.0 snapToNearestMultiple(0.26, 0.5) = 0.5

Definition at line 24 of file ftools.cxx.

References basegfx::fTools::equal(), basegfx::fTools::equalZero(), and v.

◆ snapToRange()

double basegfx::snapToRange ( double  v,
double  fLow,
double  fHigh 
)

Snap v to the range [fLow .

. fHigh] using modulo

Definition at line 74 of file ftools.cxx.

References basegfx::fTools::equal(), snapToZeroRange(), and v.

◆ snapToZeroRange()

BASEGFX_DLLPUBLIC double basegfx::snapToZeroRange ( double  v,
double  fWidth 
)

Snap v to the range [0.0 .

. fWidth] using modulo

Definition at line 47 of file ftools.cxx.

References basegfx::fTools::equalZero(), and v.

Referenced by snapToRange().

◆ UNLESS_MERGELIBS()

class basegfx::UNLESS_MERGELIBS ( BASEGFX_DLLPUBLIC  )

Gradient definition as used in ODF 1.2.

This struct collects all data necessary for rendering ODF 1.2-compatible gradients. Use the createXXXODFGradientInfo() methods below for initializing from ODF attributes.

transformation mapping from [0,1]^2 texture coordinate space to [0,1]^2 shape coordinate space

transformation mapping from [0,1]^2 shape coordinate space to [0,1]^2 texture coordinate space. This is the transformation commonly used to create gradients from a scanline rasterizer (put shape u/v coordinates into it, get texture s/t coordinates out of it)

Aspect ratio of the gradient. Only used in drawinglayer for generating nested gradient polygons currently. Already catered for in the transformations above.

Requested gradient steps to render. See the implementations of the getXXXGradientAlpha() methods below, the semantic differs slightly for the different gradient types.

transformation mapping from [0,1]^2 texture coordinate space to [0,1]^2 shape coordinate space

transformation mapping from [0,1]^2 shape coordinate space to [0,1]^2 texture coordinate space. This is the transformation commonly used to create gradients from a scanline rasterizer (put shape u/v coordinates into it, get texture s/t coordinates out of it)

Aspect ratio of the gradient. Only used in drawinglayer for generating nested gradient polygons currently. Already catered for in the transformations above.

Requested gradient steps to render. See the implementations of the getXXXGradientAlpha() methods below, the semantic differs slightly for the different gradient types.

Definition at line 1 of file b2dtrapezoid.hxx.

Variable Documentation

◆ DEFAULT

o3tl::cow_wrapper<ImplB2DPolygon> basegfx::DEFAULT
static

Definition at line 1078 of file b2dpolygon.cxx.

◆ RowSize

constexpr int basegfx::RowSize = 3
constexpr