Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
161fb178
Kaydet (Commit)
161fb178
authored
Nis 09, 2012
tarafından
Julien Nabet
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Remove canvas::tools::calcRectToRectTransform
üst
26398f9d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
1 addition
and
84 deletions
+1
-84
canvastools.hxx
canvas/inc/canvas/canvastools.hxx
+1
-44
canvastools.cxx
canvas/source/tools/canvastools.cxx
+0
-39
unusedcode.easy
unusedcode.easy
+0
-1
No files found.
canvas/inc/canvas/canvastools.hxx
Dosyayı görüntüle @
161fb178
...
...
@@ -225,60 +225,17 @@ namespace canvas
@param i_Transformation
Transformation to apply to the input rectangle
@see calcRectToRectTransform()
@return a reference to the resulting rectangle
*/
CANVASTOOLS_DLLPUBLIC
::
basegfx
::
B2DRange
&
calcTransformedRectBounds
(
::
basegfx
::
B2DRange
&
o_Rect
,
const
::
basegfx
::
B2DRange
&
i_Rect
,
const
::
basegfx
::
B2DHomMatrix
&
i_Transformation
);
/** Calc a transform that maps one rectangle on top of
another.
The method is a kissing cousin to
calcTransformedRectBounds(). It can be used to modify the
given transformation matrix, such that it transforms the
given input rectangle to the given output rectangle,
changing only translation and scale (if necessary). Thus,
if you've calculated an output rectangle via
calcTransformedRectBounds(), you can move and scale that
rectangle as you like, and have this method calculate the
required total transformation for it.
@param o_transform
Output parameter, to receive the resulting transformation
matrix.
@param i_destRect
Input parameter, specifies the requested destination
rectangle. The resulting transformation will exactly map
the source rectangle to the destination rectangle.
@param i_srcRect
Input parameter, specifies the original source
rectangle. The resulting transformation will exactly map
the source rectangle to the destination rectangle.
@param i_transformation
The original transformation matrix. This is changed with
translations and scalings (if necessary), to exactly map
the source rectangle to the destination rectangle.
@return a reference to the resulting transformation matrix
@see calcTransformedRectBounds()
*/
CANVASTOOLS_DLLPUBLIC
::
basegfx
::
B2DHomMatrix
&
calcRectToRectTransform
(
::
basegfx
::
B2DHomMatrix
&
o_transform
,
const
::
basegfx
::
B2DRange
&
i_destRect
,
const
::
basegfx
::
B2DRange
&
i_srcRect
,
const
::
basegfx
::
B2DHomMatrix
&
i_transformation
);
/** Calc a transform that maps the upper, left corner of a
rectangle to the origin.
The method is a specialized version of
calcRectToRectTransform(), mapping the input rectangle's
calcRectToRectTransform()
(Removed now)
, mapping the input rectangle's
the upper, left corner to the origin, and leaving the size
untouched.
...
...
canvas/source/tools/canvastools.cxx
Dosyayı görüntüle @
161fb178
...
...
@@ -688,45 +688,6 @@ namespace canvas
return
outRect
;
}
::
basegfx
::
B2DHomMatrix
&
calcRectToRectTransform
(
::
basegfx
::
B2DHomMatrix
&
o_transform
,
const
::
basegfx
::
B2DRange
&
destRect
,
const
::
basegfx
::
B2DRange
&
srcRect
,
const
::
basegfx
::
B2DHomMatrix
&
transformation
)
{
if
(
srcRect
.
isEmpty
()
||
destRect
.
isEmpty
()
)
{
return
o_transform
=
transformation
;
}
// transform inputRect by transformation
::
basegfx
::
B2DRectangle
aTransformedRect
;
calcTransformedRectBounds
(
aTransformedRect
,
srcRect
,
transformation
);
// now move resulting left,top point of bounds to (0,0)
basegfx
::
B2DHomMatrix
aCorrectedTransform
(
basegfx
::
tools
::
createTranslateB2DHomMatrix
(
-
aTransformedRect
.
getMinX
(),
-
aTransformedRect
.
getMinY
()));
// scale to match outRect
const
double
xDenom
(
aTransformedRect
.
getWidth
()
);
const
double
yDenom
(
aTransformedRect
.
getHeight
()
);
if
(
xDenom
!=
0.0
&&
yDenom
!=
0.0
)
aCorrectedTransform
.
scale
(
destRect
.
getWidth
()
/
xDenom
,
destRect
.
getHeight
()
/
yDenom
);
// TODO(E2): error handling
// translate to final position
aCorrectedTransform
.
translate
(
destRect
.
getMinX
(),
destRect
.
getMinY
()
);
::
basegfx
::
B2DHomMatrix
transform
(
transformation
);
o_transform
=
aCorrectedTransform
*
transform
;
return
o_transform
;
}
bool
isInside
(
const
::
basegfx
::
B2DRange
&
rContainedRect
,
const
::
basegfx
::
B2DRange
&
rTransformRect
,
const
::
basegfx
::
B2DHomMatrix
&
rTransformation
)
...
...
unusedcode.easy
Dosyayı görüntüle @
161fb178
...
...
@@ -734,7 +734,6 @@ canvas::ParametricPolyPolygon::ParametricPolyPolygon(com::sun::star::uno::Refere
canvas::PropertySetHelper::PropertySetHelper(std::__debug::vector<canvas::tools::ValueMap<canvas::PropertySetHelper::Callbacks>::MapEntry, std::allocator<canvas::tools::ValueMap<canvas::PropertySetHelper::Callbacks>::MapEntry> > const&)
canvas::createSurfaceProxyManager(boost::shared_ptr<canvas::IRenderModule> const&)
canvas::tools::ElapsedTime::getTimeBase() const
canvas::tools::calcRectToRectTransform(basegfx::B2DHomMatrix&, basegfx::B2DRange const&, basegfx::B2DRange const&, basegfx::B2DHomMatrix const&)
canvas::tools::clipBlit(basegfx::B2IRange&, basegfx::B2IPoint&, basegfx::B2IRange const&, basegfx::B2IRange const&)
cmis::Content::exchangeIdentity(com::sun::star::uno::Reference<com::sun::star::ucb::XContentIdentifier> const&)
cmis::Content::queryChildren(std::__debug::list<rtl::Reference<cmis::Content>, std::allocator<rtl::Reference<cmis::Content> > >&)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment