39 std::array<std::array<double, 3>, 2> mfValues {
40 std::array<double, 3>{ 1.0, 0.0, 0.0 },
41 std::array<double, 3>{ 0.0, 1.0, 0.0 } };
49 constexpr B2DHomMatrix(
double f_0x0,
double f_0x1,
double f_0x2,
double f_1x0,
double f_1x1,
double f_1x2)
51 mfValues[0][0] = f_0x0;
52 mfValues[0][1] = f_0x1;
53 mfValues[0][2] = f_0x2;
54 mfValues[1][0] = f_1x0;
55 mfValues[1][1] = f_1x1;
56 mfValues[1][2] = f_1x2;
74 double a()
const {
return get(0,0); }
76 double b()
const {
return get(1,0); }
78 double c()
const {
return get(0,1); }
80 double d()
const {
return get(1,1); }
82 double e()
const {
return get(0,2); }
84 double f()
const {
return get(1,2); }
86 double get(sal_uInt16 nRow, sal_uInt16 nColumn)
const
88 return mfValues[nRow][nColumn];
91 void set(sal_uInt16 nRow, sal_uInt16 nColumn,
double fValue)
93 mfValues[nRow][nColumn] = fValue;
99 void set3x2(
double f_0x0,
double f_0x1,
double f_0x2,
double f_1x0,
double f_1x1,
double f_1x2);
102 bool isIdentity()
const;
105 bool isInvertible()
const;
108 void rotate(
double fRadiant);
110 void translate(
double fX,
double fY);
111 void translate(
const B2DTuple& rTuple);
113 void scale(
double fX,
double fY);
117 void shearX(
double fSx);
118 void shearY(
double fSy);
136 void computeAdjoint(
double (&dst)[6])
const;
137 double computeDeterminant(
double (&dst)[6])
const;
148 template<
typename charT,
typename traits>
150 std::basic_ostream<charT, traits> & stream, B2DHomMatrix
const & matrix)
153 <<
'[' <<
matrix.get(0, 0) <<
' ' <<
matrix.get(0, 1) <<
' '
#define BASEGFX_DLLPUBLIC
constexpr B2DHomMatrix(double f_0x0, double f_0x1, double f_0x2, double f_1x0, double f_1x1, double f_1x2)
constructor to allow setting all needed values for a 3x2 matrix at once.
void set(sal_uInt16 nRow, sal_uInt16 nColumn, double fValue)
static B2DHomMatrix abcdef(double da, double db, double dc, double dd, double de, double df)
Convenience creator for declaration of the matrix that is commonly used by web standards (SVG,...
double get(sal_uInt16 nRow, sal_uInt16 nColumn) const
constexpr B2DHomMatrix()=default
Base class for all Points/Vectors with two double values.
Reference< XOutputStream > stream
def rotate(shapename, deg)
std::basic_ostream< charT, traits > & operator<<(std::basic_ostream< charT, traits > &stream, BColor const &color)
B2DPoint operator*(const ::basegfx::B2DHomMatrix &rMat, const B2DPoint &rPoint)
rtl::OString decompose(rtl::OString const &type, sal_Int32 *rank=nullptr, std::vector< rtl::OString > *arguments=nullptr)
css::uno::Reference< css::linguistic2::XProofreadingIterator > get(css::uno::Reference< css::uno::XComponentContext > const &context)
SmFace & operator*=(SmFace &rFace, const Fraction &rFrac)
bool operator!=(const XclExpString &rLeft, const XclExpString &rRight)
bool operator==(const XclFontData &rLeft, const XclFontData &rRight)