33 bool bDirectionForward,
35 mpParametricPoly( rPolygon ),
36 maStaticTransformation(),
37 mbForwardParameterSweep( true ),
38 mbSubtractPolygon( false ),
39 mbScaleIsotrophically( rTransitionInfo.mbScaleIsotrophically ),
43 "ClippingFunctor::ClippingFunctor(): Invalid parametric polygon" );
78 if (rTransitionInfo.
mnScaleX != 1.0 ||
88 if( !bDirectionForward )
98 "TransitionFactory::TransitionFactory(): Unexpected reverse method" );
140 const ::basegfx::B2DSize& rTargetSize )
151 if (aClipPoly.
count() == 0)
170 if(aBackgroundRange.
isInside(aClipPolyRange))
173 aClipPoly = ::basegfx::utils::correctOrientations(aClipPoly);
189 const double nScale( ::std::max( rTargetSize.getWidth(),
190 rTargetSize.getHeight() ) );
191 aMatrix.
scale( nScale, nScale );
192 aMatrix.
translate( -(nScale - rTargetSize.getWidth())/2.0,
193 -(nScale - rTargetSize.getHeight())/2.0 );
197 aMatrix.
scale( rTargetSize.getWidth(),
198 rTargetSize.getHeight() );
void rotate(double fRadiant)
void translate(double fX, double fY)
void scale(double fX, double fY)
void insert(sal_uInt32 nIndex, const B2DPolygon &rPolygon, sal_uInt32 nCount=1)
void append(const B2DPolygon &rPolygon, sal_uInt32 nCount=1)
void transform(const basegfx::B2DHomMatrix &rMatrix)
B2DRange getB2DRange() const
bool isInside(const Tuple2D< TYPE > &rTuple) const
const bool mbScaleIsotrophically
ClippingFunctor(const ParametricPolyPolygonSharedPtr &rPolygon, const TransitionInfo &rTransitionInfo, bool bDirectionForward, bool bModeIn)
::basegfx::B2DHomMatrix maStaticTransformation
bool mbForwardParameterSweep
::basegfx::B2DPolyPolygon operator()(double nValue, const ::basegfx::B2DSize &rTargetSize)
Generate clip polygon.
#define ENSURE_OR_THROW(c, m)
B2DHomMatrix createScaleTranslateB2DHomMatrix(double fScaleX, double fScaleY, double fTranslateX, double fTranslateY)
B2DPolygon createPolygonFromRect(const B2DRectangle &rRect, double fRadiusX, double fRadiusY)
B2DHomMatrix createRotateAroundPoint(double fPointX, double fPointY, double fRadiant)
B2DPolyPolygon solvePolygonOperationDiff(const B2DPolyPolygon &rCandidateA, const B2DPolyPolygon &rCandidateB)
constexpr double deg2rad(double v)
::std::shared_ptr< ParametricPolyPolygon > ParametricPolyPolygonSharedPtr
@ Rotate180
Reverse by rotating polygon 180 degrees.
@ FlipX
Reverse by flipping polygon at the y (!) axis.
@ FlipY
Reverse by flipping polygon at the x (!) axis.
@ SubtractAndInvert
Combination of ReverseMethod::InvertSweep and ReverseMethod::SubtractPolygon.
@ Ignore
Ignore direction attribute altogether (if it has no sensible meaning for this transition)
bool mbOutInvertsSweep
When true, transition 'out' effects are realized by inverting the parameter sweep direction (1->0 ins...
double mnScaleX
X scaling of clip polygon (negative values mirror)
double mnRotationAngle
Rotation angle of clip polygon.
double mnScaleY
Y scaling of clip polygon (negative values mirror)
ReverseMethod meReverseMethod
Indicating the method to use when transition should be 'reversed'.