summaryrefslogtreecommitdiff
path: root/basebmp/inc/basebmp
diff options
context:
space:
mode:
Diffstat (limited to 'basebmp/inc/basebmp')
-rw-r--r--basebmp/inc/basebmp/accessor.hxx14
-rw-r--r--basebmp/inc/basebmp/accessoradapters.hxx108
-rw-r--r--basebmp/inc/basebmp/accessorfunctors.hxx30
-rw-r--r--basebmp/inc/basebmp/accessortraits.hxx12
-rw-r--r--basebmp/inc/basebmp/bitmapdevice.hxx122
-rw-r--r--basebmp/inc/basebmp/clippedlinerenderer.hxx40
-rw-r--r--basebmp/inc/basebmp/color.hxx6
-rw-r--r--basebmp/inc/basebmp/colorblendaccessoradapter.hxx16
-rw-r--r--basebmp/inc/basebmp/colormisc.hxx14
-rw-r--r--basebmp/inc/basebmp/colortraits.hxx28
-rwxr-xr-xbasebmp/inc/basebmp/compositeiterator.hxx72
-rw-r--r--basebmp/inc/basebmp/debug.hxx14
-rw-r--r--basebmp/inc/basebmp/drawmodes.hxx4
-rw-r--r--basebmp/inc/basebmp/endian.hxx2
-rw-r--r--basebmp/inc/basebmp/fillimage.hxx12
-rw-r--r--basebmp/inc/basebmp/genericcolorimageaccessor.hxx8
-rw-r--r--basebmp/inc/basebmp/greylevelformats.hxx24
-rw-r--r--basebmp/inc/basebmp/iteratortraits.hxx8
-rw-r--r--basebmp/inc/basebmp/linerenderer.hxx20
-rw-r--r--basebmp/inc/basebmp/metafunctions.hxx38
-rw-r--r--basebmp/inc/basebmp/nonstandarditerator.hxx2
-rw-r--r--basebmp/inc/basebmp/packedpixeliterator.hxx88
-rw-r--r--basebmp/inc/basebmp/paletteformats.hxx12
-rw-r--r--basebmp/inc/basebmp/paletteimageaccessor.hxx26
-rw-r--r--basebmp/inc/basebmp/pixelformatadapters.hxx8
-rw-r--r--basebmp/inc/basebmp/pixeliterator.hxx10
-rw-r--r--basebmp/inc/basebmp/polypolygonrenderer.hxx56
-rw-r--r--basebmp/inc/basebmp/rgb24pixelformats.hxx14
-rw-r--r--basebmp/inc/basebmp/rgbmaskpixelformats.hxx32
-rw-r--r--basebmp/inc/basebmp/scaleimage.hxx28
-rw-r--r--basebmp/inc/basebmp/scanlineformats.hxx2
-rw-r--r--basebmp/inc/basebmp/stridedarrayiterator.hxx2
-rw-r--r--basebmp/inc/basebmp/tools.hxx10
-rw-r--r--basebmp/inc/basebmp/truecolormaskaccessor.hxx54
34 files changed, 468 insertions, 468 deletions
diff --git a/basebmp/inc/basebmp/accessor.hxx b/basebmp/inc/basebmp/accessor.hxx
index b98f05e78f6c..dc86f44056cb 100644
--- a/basebmp/inc/basebmp/accessor.hxx
+++ b/basebmp/inc/basebmp/accessor.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -47,7 +47,7 @@ public:
template< class Iterator >
value_type operator()(Iterator const& i) const
- {
+ {
return *i;
}
@@ -61,7 +61,7 @@ public:
template< typename V, class Iterator >
void set(V const& value, Iterator const& i) const
- {
+ {
*i = vigra::detail::RequiresExplicitCast<value_type>::cast(value);
}
@@ -88,8 +88,8 @@ public:
template< class Iterator >
value_type operator()(Iterator const& i) const
- {
- return i.get();
+ {
+ return i.get();
}
template< class Iterator, class Difference >
@@ -102,14 +102,14 @@ public:
template< typename V, class Iterator >
void set(V const& value, Iterator const& i) const
- {
+ {
i.set( vigra::detail::RequiresExplicitCast<value_type>::cast(value) );
}
template< typename V, class Iterator, class Difference >
void set(V const& value, Iterator const& i, Difference const& diff) const
{
- i.set( vigra::detail::RequiresExplicitCast<value_type>::cast(value),
+ i.set( vigra::detail::RequiresExplicitCast<value_type>::cast(value),
diff );
}
};
diff --git a/basebmp/inc/basebmp/accessoradapters.hxx b/basebmp/inc/basebmp/accessoradapters.hxx
index 40b4faed4bae..d45544cc1869 100644
--- a/basebmp/inc/basebmp/accessoradapters.hxx
+++ b/basebmp/inc/basebmp/accessoradapters.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -39,7 +39,7 @@ namespace basebmp
@tpl WrappedAccessor
Wrapped type must provide the usual get and set accessor methods,
with the usual signatures (see StandardAccessor for a conforming
- example).
+ example).
@tpl GetterFunctor
An Adaptable Unary Function (i.e. providing result_type and
@@ -49,8 +49,8 @@ namespace basebmp
An Adaptable Unary Function (i.e. providing result_type and
argument_type typedefs)
*/
-template< class WrappedAccessor,
- typename GetterFunctor,
+template< class WrappedAccessor,
+ typename GetterFunctor,
typename SetterFunctor > class UnaryFunctionAccessorAdapter
{
public:
@@ -74,12 +74,12 @@ public:
maAccessor(),
maGetterFunctor(),
maSetterFunctor()
- {}
+ {}
- template< class A > explicit
+ template< class A > explicit
UnaryFunctionAccessorAdapter( UnaryFunctionAccessorAdapter< A,
GetterFunctor,
- SetterFunctor > const& rSrc ) :
+ SetterFunctor > const& rSrc ) :
maAccessor( rSrc.maAccessor ),
maGetterFunctor( rSrc.maGetterFunctor ),
maSetterFunctor( rSrc.maSetterFunctor )
@@ -90,7 +90,7 @@ public:
maGetterFunctor(),
maSetterFunctor()
{}
-
+
template< class T > UnaryFunctionAccessorAdapter( T accessor,
GetterFunctor getterFunctor,
SetterFunctor setterFunctor) :
@@ -98,7 +98,7 @@ public:
maGetterFunctor( getterFunctor ),
maSetterFunctor( setterFunctor )
{}
-
+
// -------------------------------------------------------
WrappedAccessor const& getWrappedAccessor() const { return maAccessor; }
@@ -107,11 +107,11 @@ public:
// -------------------------------------------------------
value_type getter(typename GetterFunctor::argument_type v) const
- {
+ {
return maGetterFunctor(v);
}
typename SetterFunctor::result_type setter(argument_type v) const
- {
+ {
return maSetterFunctor(v);
}
@@ -119,7 +119,7 @@ public:
template< class Iterator >
value_type operator()(Iterator const& i) const
- {
+ {
return maGetterFunctor( maAccessor(i) );
}
@@ -133,8 +133,8 @@ public:
template< typename V, class Iterator >
void set(V const& value, Iterator const& i) const
- {
- maAccessor.set(
+ {
+ maAccessor.set(
maSetterFunctor(
vigra::detail::RequiresExplicitCast<argument_type>::cast(value) ),
i );
@@ -143,7 +143,7 @@ public:
template< typename V, class Iterator, class Difference >
void set(V const& value, Iterator const& i, Difference const& diff) const
{
- maAccessor.set(
+ maAccessor.set(
maSetterFunctor(
vigra::detail::RequiresExplicitCast<argument_type>::cast(value) ),
i,
@@ -168,7 +168,7 @@ public:
An adaptable binary function (i.e. providing nested typedefs for
result_type and first and second argument type)
*/
-template< class WrappedAccessor,
+template< class WrappedAccessor,
typename SetterFunctor > class BinarySetterFunctionAccessorAdapter
{
public:
@@ -188,12 +188,12 @@ public:
BinarySetterFunctionAccessorAdapter() :
maAccessor(),
maFunctor()
- {}
+ {}
- template< class A > explicit
- BinarySetterFunctionAccessorAdapter(
+ template< class A > explicit
+ BinarySetterFunctionAccessorAdapter(
BinarySetterFunctionAccessorAdapter< A,
- SetterFunctor > const& rSrc ) :
+ SetterFunctor > const& rSrc ) :
maAccessor( rSrc.maAccessor ),
maFunctor( rSrc.maFunctor )
{}
@@ -202,13 +202,13 @@ public:
maAccessor( accessor ),
maFunctor()
{}
-
+
template< class T > BinarySetterFunctionAccessorAdapter( T accessor,
SetterFunctor functor ) :
maAccessor( accessor ),
maFunctor( functor )
{}
-
+
// -------------------------------------------------------
WrappedAccessor const& getWrappedAccessor() const { return maAccessor; }
@@ -216,10 +216,10 @@ public:
// -------------------------------------------------------
- typename SetterFunctor::result_type setter(
+ typename SetterFunctor::result_type setter(
typename SetterFunctor::first_argument_type v1,
argument_type v2 ) const
- {
+ {
return maSetterFunctor(v1,v2);
}
@@ -227,7 +227,7 @@ public:
template< class Iterator >
value_type operator()(Iterator const& i) const
- {
+ {
return maAccessor(i);
}
@@ -241,9 +241,9 @@ public:
template< typename V, class Iterator >
void set(V const& value, Iterator const& i) const
- {
- maAccessor.set(
- maFunctor(maAccessor(i),
+ {
+ maAccessor.set(
+ maFunctor(maAccessor(i),
vigra::detail::RequiresExplicitCast<argument_type>::cast(value)),
i );
}
@@ -252,7 +252,7 @@ public:
void set(V const& value, Iterator const& i, Difference const& diff) const
{
maAccessor.set(
- maFunctor(maAccessor(i,diff),
+ maFunctor(maAccessor(i,diff),
vigra::detail::RequiresExplicitCast<argument_type>::cast(value)),
i,
diff );
@@ -283,8 +283,8 @@ public:
An adaptable ternary function (i.e. providing nested typedefs for
result_type and first, second and third argument type)
*/
-template< class WrappedAccessor1,
- class WrappedAccessor2,
+template< class WrappedAccessor1,
+ class WrappedAccessor2,
typename Functor > class TernarySetterFunctionAccessorAdapter
{
public:
@@ -315,16 +315,16 @@ public:
{}
template< class A1, class A2 > explicit
- TernarySetterFunctionAccessorAdapter(
+ TernarySetterFunctionAccessorAdapter(
TernarySetterFunctionAccessorAdapter< A1,
A2,
- Functor > const& rSrc ) :
+ Functor > const& rSrc ) :
ma1stAccessor( rSrc.ma1stAccessor ),
ma2ndAccessor( rSrc.ma2ndAccessor ),
maFunctor( rSrc.maFunctor )
{}
- template< class T1, class T2 >
+ template< class T1, class T2 >
TernarySetterFunctionAccessorAdapter( T1 accessor1,
T2 accessor2 ) :
ma1stAccessor( accessor1 ),
@@ -332,7 +332,7 @@ public:
maFunctor()
{}
- template< class T1, class T2 >
+ template< class T1, class T2 >
TernarySetterFunctionAccessorAdapter( T1 accessor1,
T2 accessor2,
Functor func ) :
@@ -340,7 +340,7 @@ public:
ma2ndAccessor( accessor2 ),
maFunctor( func )
{}
-
+
// -------------------------------------------------------
WrappedAccessor1 const& get1stWrappedAccessor() const { return ma1stAccessor; }
@@ -351,11 +351,11 @@ public:
// -------------------------------------------------------
- typename Functor::result_type setter(
+ typename Functor::result_type setter(
typename Functor::first_argument_type v1,
typename Functor::second_argument_type v2,
argument_type v3 ) const
- {
+ {
return maSetterFunctor(v1,v2,v3);
}
@@ -363,7 +363,7 @@ public:
template< class Iterator >
value_type operator()(Iterator const& i) const
- {
+ {
return ma1stAccessor(i.first());
}
@@ -377,9 +377,9 @@ public:
template< typename V, class Iterator >
void set(V const& value, Iterator const& i) const
- {
+ {
ma1stAccessor.set(
- maFunctor(ma1stAccessor(i.first()),
+ maFunctor(ma1stAccessor(i.first()),
ma2ndAccessor(i.second()),
vigra::detail::RequiresExplicitCast<argument_type>::cast(value)),
i.first() );
@@ -389,7 +389,7 @@ public:
void set(V const& value, Iterator const& i, Difference const& diff) const
{
ma1stAccessor.set(
- maFunctor(ma1stAccessor(i.first(), diff),
+ maFunctor(ma1stAccessor(i.first(), diff),
ma2ndAccessor(i.second(),diff),
vigra::detail::RequiresExplicitCast<argument_type>::cast(value)),
i.first(),
@@ -397,7 +397,7 @@ public:
}
};
-
+
//-----------------------------------------------------------------------------
/** Access two distinct images simultaneously
@@ -420,7 +420,7 @@ public:
example). Furthermore, the type must provide a nested typedef
value_type.
*/
-template< class WrappedAccessor1,
+template< class WrappedAccessor1,
class WrappedAccessor2 > class JoinImageAccessorAdapter
{
public:
@@ -451,14 +451,14 @@ public:
{}
template< class A1, class A2 > explicit
- JoinImageAccessorAdapter(
+ JoinImageAccessorAdapter(
JoinImageAccessorAdapter< A1,
- A2 > const& rSrc ) :
+ A2 > const& rSrc ) :
ma1stAccessor( rSrc.ma1stAccessor ),
ma2ndAccessor( rSrc.ma2ndAccessor )
{}
- template< class T1, class T2 >
+ template< class T1, class T2 >
JoinImageAccessorAdapter( T1 accessor1,
T2 accessor2 ) :
ma1stAccessor( accessor1 ),
@@ -477,7 +477,7 @@ public:
template< class Iterator >
value_type operator()(Iterator const& i) const
- {
+ {
return std::make_pair(ma1stAccessor(i.first()),
ma2ndAccessor(i.second()));
}
@@ -493,12 +493,12 @@ public:
template< typename V, class Iterator >
void set(V const& value, Iterator const& i) const
- {
- ma1stAccessor.set(
+ {
+ ma1stAccessor.set(
vigra::detail::RequiresExplicitCast<typename WrappedAccessor1::value_type>::cast(
value.first),
i.first() );
- ma2ndAccessor.set(
+ ma2ndAccessor.set(
vigra::detail::RequiresExplicitCast<typename WrappedAccessor2::value_type>::cast(
value.second),
i.second() );
@@ -507,19 +507,19 @@ public:
template< typename V, class Iterator, class Difference >
void set(V const& value, Iterator const& i, Difference const& diff) const
{
- ma1stAccessor.set(
+ ma1stAccessor.set(
vigra::detail::RequiresExplicitCast<typename WrappedAccessor1::value_type>::cast(
value.first),
i.first(),
diff );
- ma2ndAccessor.set(
+ ma2ndAccessor.set(
vigra::detail::RequiresExplicitCast<typename WrappedAccessor2::value_type>::cast(
value.second),
i.second(),
diff );
}
-};
+};
} // namespace basebmp
diff --git a/basebmp/inc/basebmp/accessorfunctors.hxx b/basebmp/inc/basebmp/accessorfunctors.hxx
index fdb9b75aa64f..e0ce7df801a5 100644
--- a/basebmp/inc/basebmp/accessorfunctors.hxx
+++ b/basebmp/inc/basebmp/accessorfunctors.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -49,7 +49,7 @@ template< typename T > struct XorFunctor : public std::binary_function<T,T,T>
//-----------------------------------------------------------------------------
/// Base class, passing on the arg types
-template< typename T, typename M > struct MaskFunctorBase :
+template< typename T, typename M > struct MaskFunctorBase :
public TernaryFunctorBase<T,M,T,T> {};
@@ -60,8 +60,8 @@ template< typename T, typename M > struct MaskFunctorBase :
transparency, i.e. the original value will display. And vice
versa.
*/
-template< typename T,
- typename M,
+template< typename T,
+ typename M,
bool polarity > struct GenericOutputMaskFunctor : public MaskFunctorBase<T,M>
{
/// Ternary mask operation - selects v1 for !m == polarity, v2 otherwise
@@ -74,14 +74,14 @@ template< typename T,
/** Let a mask bit decide between two values (specialization for
integer mask types)
*/
-template< typename T,
+template< typename T,
typename M,
bool polarity > struct IntegerOutputMaskFunctor;
-template< typename T,
+template< typename T,
typename M > struct IntegerOutputMaskFunctor<T,M,true> : public MaskFunctorBase<T,M>
{
/** Mask v with state of m
-
+
@return v2, if m != 0, v1 otherwise.
*/
T operator()( T v1, M m, T v2 ) const
@@ -93,11 +93,11 @@ template< typename T,
return v1*(M)(1-mask) + v2*mask;
}
};
-template< typename T,
+template< typename T,
typename M > struct IntegerOutputMaskFunctor<T,M,false> : public MaskFunctorBase<T,M>
{
/** Mask v with state of m
-
+
@return v2, if m != 0, v1 otherwise.
*/
T operator()( T v1, M m, T v2 ) const
@@ -114,7 +114,7 @@ template< typename T,
binary-valued mask types)
*/
template< typename T, typename M, bool polarity > struct FastIntegerOutputMaskFunctor;
-template< typename T, typename M > struct FastIntegerOutputMaskFunctor<T,M,true> :
+template< typename T, typename M > struct FastIntegerOutputMaskFunctor<T,M,true> :
public MaskFunctorBase<T,M>
{
/// Specialization, only valid if mask can only attain 0 or 1
@@ -125,7 +125,7 @@ template< typename T, typename M > struct FastIntegerOutputMaskFunctor<T,M,true>
return v1*(M)(1-m) + v2*m;
}
};
-template< typename T, typename M > struct FastIntegerOutputMaskFunctor<T,M,false> :
+template< typename T, typename M > struct FastIntegerOutputMaskFunctor<T,M,false> :
public MaskFunctorBase<T,M>
{
/// Specialization, only valid if mask can only attain 0 or 1
@@ -166,14 +166,14 @@ private:
public:
BinaryFunctorSplittingWrapper() : maFunctor() {}
- template< class A > explicit
- BinaryFunctorSplittingWrapper(
+ template< class A > explicit
+ BinaryFunctorSplittingWrapper(
BinaryFunctorSplittingWrapper<A> const& src ) : maFunctor(src.maFunctor) {}
- template< class F > explicit
+ template< class F > explicit
BinaryFunctorSplittingWrapper( F const& func ) : maFunctor(func) {}
- typename Functor::result_type operator()(
+ typename Functor::result_type operator()(
typename Functor::first_argument_type v1,
std::pair< typename Functor::third_argument_type,
typename Functor::second_argument_type > const& v2 ) const
diff --git a/basebmp/inc/basebmp/accessortraits.hxx b/basebmp/inc/basebmp/accessortraits.hxx
index 0cb0d1f8d37d..ea586868caaf 100644
--- a/basebmp/inc/basebmp/accessortraits.hxx
+++ b/basebmp/inc/basebmp/accessortraits.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -60,13 +60,13 @@ template< typename T, typename M, bool polarity > struct outputMaskFunctorSelect
Specialize this metafunction for your case, and pass FastMask to
the outputMaskFunctorSelector.
*/
-template< class Accessor,
- class MaskAccessor,
+template< class Accessor,
+ class MaskAccessor,
class Iterator,
class MaskIterator,
bool polarity > struct maskedAccessorSelector
{
- typedef TernarySetterFunctionAccessorAdapter<
+ typedef TernarySetterFunctionAccessorAdapter<
Accessor,
MaskAccessor,
typename outputMaskFunctorSelector<
@@ -96,7 +96,7 @@ template< class Accessor > struct AccessorTraits
typedef Accessor raw_accessor;
/// Retrieve wrapped accessor for XOR setter access
- typedef BinarySetterFunctionAccessorAdapter<
+ typedef BinarySetterFunctionAccessorAdapter<
Accessor,
XorFunctor< value_type > > xor_accessor;
@@ -112,7 +112,7 @@ template< class Accessor > struct AccessorTraits
partial specializations that take an optimized functor for
certain mask accessors.
*/
- template< class MaskAccessor,
+ template< class MaskAccessor,
class Iterator,
class MaskIterator,
bool polarity > struct masked_accessor :
diff --git a/basebmp/inc/basebmp/bitmapdevice.hxx b/basebmp/inc/basebmp/bitmapdevice.hxx
index b1c513444fe6..08f179004017 100644
--- a/basebmp/inc/basebmp/bitmapdevice.hxx
+++ b/basebmp/inc/basebmp/bitmapdevice.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -59,7 +59,7 @@ typedef boost::shared_ptr< const std::vector<Color> > PaletteMemorySharedVecto
struct ImplBitmapDevice;
-/** Definition of BitmapDevice interface
+/** Definition of BitmapDevice interface
Use the createBitmapDevice() factory method to create instances.
@@ -143,7 +143,7 @@ public:
Draw mode to use when changing the pixel value
*/
void setPixel( const basegfx::B2IPoint& rPt,
- Color pixelColor,
+ Color pixelColor,
DrawMode drawMode );
/** Set given pixel to specified color
@@ -161,9 +161,9 @@ public:
Clip mask to use. If the clip mask is 1 at the given pixel
position, no change will take place.
*/
- void setPixel( const basegfx::B2IPoint& rPt,
- Color pixelColor,
- DrawMode drawMode,
+ void setPixel( const basegfx::B2IPoint& rPt,
+ Color pixelColor,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip );
/** Get color value at given pixel
@@ -183,7 +183,7 @@ public:
@param rPt1
Start point of the line
- @param rPt2
+ @param rPt2
End point of the line. If the analytical line from rP1 to rPt2
(with the actual pixel positions assumed to be the center of
the pixel) is exactly in the middle between two pixel, this
@@ -195,9 +195,9 @@ public:
@param drawMode
Draw mode to use when changing the pixel value
*/
- void drawLine( const basegfx::B2IPoint& rPt1,
- const basegfx::B2IPoint& rPt2,
- Color lineColor,
+ void drawLine( const basegfx::B2IPoint& rPt1,
+ const basegfx::B2IPoint& rPt2,
+ Color lineColor,
DrawMode drawMode );
/** Draw a line
@@ -205,7 +205,7 @@ public:
@param rPt1
Start point of the line
- @param rPt2
+ @param rPt2
End point of the line. If the analytical line from rP1 to rPt2
(with the actual pixel positions assumed to be the center of
the pixel) is exactly in the middle between two pixel, this
@@ -221,10 +221,10 @@ public:
Clip mask to use. Pixel where the corresponding clip mask
pixel is 1 will not be modified.
*/
- void drawLine( const basegfx::B2IPoint& rPt1,
- const basegfx::B2IPoint& rPt2,
- Color lineColor,
- DrawMode drawMode,
+ void drawLine( const basegfx::B2IPoint& rPt1,
+ const basegfx::B2IPoint& rPt2,
+ Color lineColor,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip );
/** Draw a polygon
@@ -240,8 +240,8 @@ public:
@param drawMode
Draw mode to use when changing pixel values
*/
- void drawPolygon( const basegfx::B2DPolygon& rPoly,
- Color lineColor,
+ void drawPolygon( const basegfx::B2DPolygon& rPoly,
+ Color lineColor,
DrawMode drawMode );
/** Draw a polygon
@@ -261,9 +261,9 @@ public:
Clip mask to use. Pixel where the corresponding clip mask
pixel is 1 will not be modified.
*/
- void drawPolygon( const basegfx::B2DPolygon& rPoly,
- Color lineColor,
- DrawMode drawMode,
+ void drawPolygon( const basegfx::B2DPolygon& rPoly,
+ Color lineColor,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip );
/** Fill a poly-polygon
@@ -284,8 +284,8 @@ public:
@param drawMode
Draw mode to use when changing pixel values
*/
- void fillPolyPolygon( const basegfx::B2DPolyPolygon& rPoly,
- Color fillColor,
+ void fillPolyPolygon( const basegfx::B2DPolyPolygon& rPoly,
+ Color fillColor,
DrawMode drawMode );
/** Fill a poly-polygon
@@ -310,9 +310,9 @@ public:
Clip mask to use. Pixel where the corresponding clip mask
pixel is 1 will not be modified.
*/
- void fillPolyPolygon( const basegfx::B2DPolyPolygon& rPoly,
- Color fillColor,
- DrawMode drawMode,
+ void fillPolyPolygon( const basegfx::B2DPolyPolygon& rPoly,
+ Color fillColor,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip );
/** Draw another bitmap into this device
@@ -341,7 +341,7 @@ public:
*/
void drawBitmap( const BitmapDeviceSharedPtr& rSrcBitmap,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IRange& rDstRect,
+ const basegfx::B2IRange& rDstRect,
DrawMode drawMode );
/** Draw another bitmap into this device
@@ -374,8 +374,8 @@ public:
*/
void drawBitmap( const BitmapDeviceSharedPtr& rSrcBitmap,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IRange& rDstRect,
- DrawMode drawMode,
+ const basegfx::B2IRange& rDstRect,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip );
/** Draw a color with an alpha-modulation bitmap into this device
@@ -444,9 +444,9 @@ public:
void drawMaskedColor( Color aSrcColor,
const BitmapDeviceSharedPtr& rAlphaMask,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IPoint& rDstPoint,
+ const basegfx::B2IPoint& rDstPoint,
const BitmapDeviceSharedPtr& rClip );
-
+
/** Draw another bitmap through a mask into this device
This method renders a source bitmap into this device, much
@@ -485,7 +485,7 @@ public:
void drawMaskedBitmap( const BitmapDeviceSharedPtr& rSrcBitmap,
const BitmapDeviceSharedPtr& rMask,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IRange& rDstRect,
+ const basegfx::B2IRange& rDstRect,
DrawMode drawMode );
/** Draw another bitmap through a mask into this device
@@ -530,8 +530,8 @@ public:
void drawMaskedBitmap( const BitmapDeviceSharedPtr& rSrcBitmap,
const BitmapDeviceSharedPtr& rMask,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IRange& rDstRect,
- DrawMode drawMode,
+ const basegfx::B2IRange& rDstRect,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip );
protected:
@@ -553,58 +553,58 @@ private:
const basegfx::B2IRange& rBounds ) = 0;
virtual void setPixel_i( const basegfx::B2IPoint& rPt,
- Color lineColor,
+ Color lineColor,
DrawMode drawMode ) = 0;
- virtual void setPixel_i( const basegfx::B2IPoint& rPt,
- Color lineColor,
- DrawMode drawMode,
+ virtual void setPixel_i( const basegfx::B2IPoint& rPt,
+ Color lineColor,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip ) = 0;
virtual Color getPixel_i( const basegfx::B2IPoint& rPt ) = 0;
virtual sal_uInt32 getPixelData_i( const basegfx::B2IPoint& rPt ) = 0;
- virtual void drawLine_i( const basegfx::B2IPoint& rPt1,
+ virtual void drawLine_i( const basegfx::B2IPoint& rPt1,
const basegfx::B2IPoint& rPt2,
const basegfx::B2IRange& rBounds,
- Color lineColor,
+ Color lineColor,
DrawMode drawMode ) = 0;
- virtual void drawLine_i( const basegfx::B2IPoint& rPt1,
- const basegfx::B2IPoint& rPt2,
+ virtual void drawLine_i( const basegfx::B2IPoint& rPt1,
+ const basegfx::B2IPoint& rPt2,
const basegfx::B2IRange& rBounds,
- Color lineColor,
- DrawMode drawMode,
+ Color lineColor,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip ) = 0;
- virtual void drawPolygon_i( const basegfx::B2DPolygon& rPoly,
+ virtual void drawPolygon_i( const basegfx::B2DPolygon& rPoly,
const basegfx::B2IRange& rBounds,
- Color lineColor,
+ Color lineColor,
DrawMode drawMode ) = 0;
- virtual void drawPolygon_i( const basegfx::B2DPolygon& rPoly,
+ virtual void drawPolygon_i( const basegfx::B2DPolygon& rPoly,
const basegfx::B2IRange& rBounds,
- Color lineColor,
- DrawMode drawMode,
+ Color lineColor,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip ) = 0;
- virtual void fillPolyPolygon_i( const basegfx::B2DPolyPolygon& rPoly,
- Color fillColor,
+ virtual void fillPolyPolygon_i( const basegfx::B2DPolyPolygon& rPoly,
+ Color fillColor,
DrawMode drawMode,
const basegfx::B2IRange& rBounds ) = 0;
- virtual void fillPolyPolygon_i( const basegfx::B2DPolyPolygon& rPoly,
- Color fillColor,
+ virtual void fillPolyPolygon_i( const basegfx::B2DPolyPolygon& rPoly,
+ Color fillColor,
DrawMode drawMode,
- const basegfx::B2IRange& rBounds,
+ const basegfx::B2IRange& rBounds,
const BitmapDeviceSharedPtr& rClip ) = 0;
// must work with *this == rSrcBitmap!
virtual void drawBitmap_i( const BitmapDeviceSharedPtr& rSrcBitmap,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IRange& rDstRect,
+ const basegfx::B2IRange& rDstRect,
DrawMode drawMode ) = 0;
virtual void drawBitmap_i( const BitmapDeviceSharedPtr& rSrcBitmap,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IRange& rDstRect,
- DrawMode drawMode,
+ const basegfx::B2IRange& rDstRect,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip ) = 0;
// must work with *this == rSrcBitmap!
@@ -615,20 +615,20 @@ private:
virtual void drawMaskedColor_i( Color rSrcColor,
const BitmapDeviceSharedPtr& rAlphaMask,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IPoint& rDstPoint,
+ const basegfx::B2IPoint& rDstPoint,
const BitmapDeviceSharedPtr& rClip ) = 0;
-
+
// must work with *this == rSrcBitmap!
virtual void drawMaskedBitmap_i( const BitmapDeviceSharedPtr& rSrcBitmap,
const BitmapDeviceSharedPtr& rMask,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IRange& rDstRect,
+ const basegfx::B2IRange& rDstRect,
DrawMode drawMode ) = 0;
virtual void drawMaskedBitmap_i( const BitmapDeviceSharedPtr& rSrcBitmap,
const BitmapDeviceSharedPtr& rMask,
const basegfx::B2IRange& rSrcRect,
- const basegfx::B2IRange& rDstRect,
- DrawMode drawMode,
+ const basegfx::B2IRange& rDstRect,
+ DrawMode drawMode,
const BitmapDeviceSharedPtr& rClip ) = 0;
BitmapDeviceSharedPtr getGenericRenderer() const;
diff --git a/basebmp/inc/basebmp/clippedlinerenderer.hxx b/basebmp/inc/basebmp/clippedlinerenderer.hxx
index 03b2bc860cbd..310c64543953 100644
--- a/basebmp/inc/basebmp/clippedlinerenderer.hxx
+++ b/basebmp/inc/basebmp/clippedlinerenderer.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -41,7 +41,7 @@ namespace basebmp
// factored-out bresenham setup code, which is used from two different
// places in renderClippedLine() below. Admittedly messy for the long
// parameter list...
-inline bool prepareClip( sal_Int32 a1,
+inline bool prepareClip( sal_Int32 a1,
sal_Int32 a2,
sal_Int32 b1,
sal_Int32 da,
@@ -50,7 +50,7 @@ inline bool prepareClip( sal_Int32 a1,
sal_Int32& o_bs,
int sa,
int sb,
- sal_Int32& io_rem,
+ sal_Int32& io_rem,
int& o_n,
sal_uInt32 clipCode1,
sal_uInt32 clipCount1,
@@ -97,7 +97,7 @@ inline bool prepareClip( sal_Int32 a1,
if( clipCode1 & (aMinFlag|aMaxFlag) )
{
cb = (ca + da - !bRoundTowardsPt2) / (2*da);
-
+
if( sb >= 0 )
{
o_bs = b1 + cb;
@@ -110,7 +110,7 @@ inline bool prepareClip( sal_Int32 a1,
if( o_bs < bMin )
return false;
}
-
+
io_rem += ca - 2*da*cb;
}
else
@@ -128,7 +128,7 @@ inline bool prepareClip( sal_Int32 a1,
if( o_as < aMin )
return false;
}
-
+
io_rem += 2*db*ca - cb;
}
}
@@ -146,7 +146,7 @@ inline bool prepareClip( sal_Int32 a1,
cb = 2*da*((clipCode2 & bMinFlag) ? b1 - bMin : bMax - b1);
clipCode2 &= (cb + da < ca + bRoundTowardsPt2) ? ~(aMinFlag|aMaxFlag) : ~(bMinFlag|bMaxFlag);
}
-
+
if( clipCode2 & (aMinFlag|aMaxFlag) )
o_n = (clipCode2 & aMinFlag) ? o_as - aMin : aMax - o_as;
else
@@ -186,7 +186,7 @@ inline bool prepareClip( sal_Int32 a1,
@param end
right-bottom image iterator
-
+
@param acc
Image accessor
@@ -196,20 +196,20 @@ inline bool prepareClip( sal_Int32 a1,
pixel, the pixel closer to pt1 will be chosen. Giving true here
makes renderClippedLine() choose pt2 in those cases.
*/
-template< class Iterator, class Accessor >
+template< class Iterator, class Accessor >
void renderClippedLine( basegfx::B2IPoint aPt1,
basegfx::B2IPoint aPt2,
const basegfx::B2IRange& rClipRect,
typename Accessor::value_type color,
- Iterator begin,
- Accessor acc,
+ Iterator begin,
+ Accessor acc,
bool bRoundTowardsPt2=false )
{
// Algorithm according to Steven Eker's 'Pixel-perfect line clipping',
// Graphics Gems V, pp. 314-322
- sal_uInt32 clipCode1 = basegfx::tools::getCohenSutherlandClipFlags(aPt1,
+ sal_uInt32 clipCode1 = basegfx::tools::getCohenSutherlandClipFlags(aPt1,
rClipRect);
- sal_uInt32 clipCode2 = basegfx::tools::getCohenSutherlandClipFlags(aPt2,
+ sal_uInt32 clipCode2 = basegfx::tools::getCohenSutherlandClipFlags(aPt2,
rClipRect);
if( clipCode1 & clipCode2 )
@@ -218,7 +218,7 @@ void renderClippedLine( basegfx::B2IPoint aPt1,
sal_uInt32 clipCount1 = basegfx::tools::getNumberOfClipPlanes(clipCode1);
sal_uInt32 clipCount2 = basegfx::tools::getNumberOfClipPlanes(clipCode2);
- if( (clipCode1 != 0 && clipCode2 == 0)
+ if( (clipCode1 != 0 && clipCode2 == 0)
|| (clipCount1 == 2 && clipCount2 == 1) )
{
std::swap(clipCount2,clipCount1);
@@ -240,7 +240,7 @@ void renderClippedLine( basegfx::B2IPoint aPt1,
adx *= -1;
sx = -1;
}
-
+
// TODO(E1): This might overflow
sal_Int32 ady = y2 - y1;
int sy = 1;
@@ -249,7 +249,7 @@ void renderClippedLine( basegfx::B2IPoint aPt1,
ady *= -1;
sy = -1;
}
-
+
int n = 0;
sal_Int32 xs = x1;
sal_Int32 ys = y1;
@@ -268,7 +268,7 @@ void renderClippedLine( basegfx::B2IPoint aPt1,
bRoundTowardsPt2 ));
Iterator currIter( begin + vigra::Diff2D(0,ys) );
- typename vigra::IteratorTraits<Iterator>::row_iterator
+ typename vigra::IteratorTraits<Iterator>::row_iterator
rowIter( currIter.rowIterator() + xs );
adx *= 2;
@@ -307,7 +307,7 @@ void renderClippedLine( basegfx::B2IPoint aPt1,
{
acc.set(color, rowIter);
- if( --n < 0 )
+ if( --n < 0 )
break;
if( rem >= 0 )
@@ -344,7 +344,7 @@ void renderClippedLine( basegfx::B2IPoint aPt1,
bRoundTowardsPt2 ));
Iterator currIter( begin + vigra::Diff2D(xs,0) );
- typename vigra::IteratorTraits<Iterator>::column_iterator
+ typename vigra::IteratorTraits<Iterator>::column_iterator
colIter( currIter.columnIterator() + ys );
adx *= 2;
@@ -364,7 +364,7 @@ void renderClippedLine( basegfx::B2IPoint aPt1,
xs += sx;
ys += sy;
rem -= ady;
-
+
currIter.x += sx;
colIter = currIter.columnIterator() + ys;
}
diff --git a/basebmp/inc/basebmp/color.hxx b/basebmp/inc/basebmp/color.hxx
index e9aab93a715c..a38e255a4566 100644
--- a/basebmp/inc/basebmp/color.hxx
+++ b/basebmp/inc/basebmp/color.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -37,7 +37,7 @@ namespace basebmp
class Color
{
private:
- sal_uInt32 mnColor;
+ sal_uInt32 mnColor;
public:
typedef sal_uInt32 value_type;
@@ -54,7 +54,7 @@ public:
void setBlue( sal_uInt8 nBlue ) { mnColor &= ~0x000000FFUL; mnColor |= nBlue; }
void setGrey( sal_uInt8 nGreyVal ) { mnColor = (sal_uInt32)nGreyVal << 16 | (sal_uInt32)nGreyVal << 8 | nGreyVal; }
-
+
sal_uInt8 getRed() const { return 0xFF & (sal_uInt8)(mnColor >> 16); }
sal_uInt8 getGreen() const { return 0xFF & (sal_uInt8)(mnColor >> 8); }
sal_uInt8 getBlue() const { return 0xFF & (sal_uInt8)mnColor; }
diff --git a/basebmp/inc/basebmp/colorblendaccessoradapter.hxx b/basebmp/inc/basebmp/colorblendaccessoradapter.hxx
index 03263c2c6062..18b62a7223f4 100644
--- a/basebmp/inc/basebmp/colorblendaccessoradapter.hxx
+++ b/basebmp/inc/basebmp/colorblendaccessoradapter.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -43,7 +43,7 @@ namespace basebmp
when blitting through a mask) - there really isn't no other
sensible default behaviour for these methods.
*/
-template< class WrappedAccessor,
+template< class WrappedAccessor,
typename AlphaType,
bool polarity > class ConstantColorBlendSetterAccessorAdapter
{
@@ -53,7 +53,7 @@ public:
typedef typename WrappedAccessor::value_type color_type;
private:
- typename ColorTraits< color_type >::
+ typename ColorTraits< color_type >::
template blend_functor<alpha_type,polarity>::type maFunctor;
WrappedAccessor maWrappee;
color_type maBlendColor;
@@ -106,14 +106,14 @@ public:
// -------------------------------------------------------
/// @return constant value, regardless of iterator content
- template< typename IteratorType > value_type operator()(IteratorType const& ) const
- {
+ template< typename IteratorType > value_type operator()(IteratorType const& ) const
+ {
return maGetterValue;
}
/// @return constant value, regardless of iterator content
template< typename IteratorType, class Difference >
value_type operator()(IteratorType const& , Difference const& ) const
- {
+ {
return maGetterValue;
}
@@ -121,7 +121,7 @@ public:
template< typename V, typename IteratorType >
void set(V const& value, IteratorType const& i) const
- {
+ {
maWrappee.set(
maFunctor(
vigra::detail::RequiresExplicitCast<alpha_type>::cast(value),
@@ -142,7 +142,7 @@ public:
diff );
}
};
-
+
} // namespace basebmp
#endif /* INCLUDED_BASEBMP_COLORBLENDACCESSORADAPTER_HXX */
diff --git a/basebmp/inc/basebmp/colormisc.hxx b/basebmp/inc/basebmp/colormisc.hxx
index 0974ebaa44a4..635a732bc773 100644
--- a/basebmp/inc/basebmp/colormisc.hxx
+++ b/basebmp/inc/basebmp/colormisc.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -127,18 +127,18 @@ template<> struct ColorTraits< Color >
template< typename AlphaType, bool polarity > struct blend_functor;
/// Calculate normalized distance between color c1 and c2
- static inline double distance( const Color& c1,
- const Color& c2 )
- {
+ static inline double distance( const Color& c1,
+ const Color& c2 )
+ {
return (c1 - c2).magnitude();
}
- static inline component_type toGreyscale( const Color& c )
+ static inline component_type toGreyscale( const Color& c )
{
return c.getGreyscale();
}
- static inline Color fromGreyscale( component_type c )
+ static inline Color fromGreyscale( component_type c )
{
return Color(c,c,c);
}
@@ -175,7 +175,7 @@ struct NumericTraits<basebmp::Color>
typedef VigraTrueType isSigned;
typedef VigraTrueType isOrdered;
typedef VigraFalseType isComplex;
-
+
static Type zero() { return Type(); }
static Type one() { return Type(0x01010101); }
static Type nonZero() { return Type(0x01010101); }
diff --git a/basebmp/inc/basebmp/colortraits.hxx b/basebmp/inc/basebmp/colortraits.hxx
index 9c30b8f082c0..aa5e57d2a265 100644
--- a/basebmp/inc/basebmp/colortraits.hxx
+++ b/basebmp/inc/basebmp/colortraits.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -43,10 +43,10 @@ namespace basebmp
When true, 0 means fully transparent, and 1 fully opaque. And vice
versa.
*/
-template< typename ValueType,
+template< typename ValueType,
typename AlphaType,
bool polarity > struct BlendFunctor;
-template< typename ValueType,
+template< typename ValueType,
typename AlphaType > struct BlendFunctor<ValueType,AlphaType,true>
: public TernaryFunctorBase<AlphaType,ValueType,ValueType,ValueType>
{
@@ -59,7 +59,7 @@ template< typename ValueType,
return (vigra::NumericTraits<AlphaType>::one()-fAlpha)*v1 + fAlpha*v2;
}
};
-template< typename ValueType,
+template< typename ValueType,
typename AlphaType > struct BlendFunctor<ValueType,AlphaType,false>
: public TernaryFunctorBase<AlphaType,ValueType,ValueType,ValueType>
{
@@ -78,12 +78,12 @@ template< typename ValueType,
@tpl polarity
When true, 0 means fully transparent, and 1 fully opaque. And vice
- versa.
+ versa.
*/
-template< typename ValueType,
+template< typename ValueType,
typename AlphaType,
bool polarity > struct IntegerBlendFunctor;
-template< typename ValueType,
+template< typename ValueType,
typename AlphaType > struct IntegerBlendFunctor<ValueType,AlphaType,true>
: public TernaryFunctorBase<AlphaType,ValueType,ValueType,ValueType>
{
@@ -96,7 +96,7 @@ template< typename ValueType,
vigra::NumericTraits<AlphaType>::max();
}
};
-template< typename ValueType,
+template< typename ValueType,
typename AlphaType > struct IntegerBlendFunctor<ValueType,AlphaType,false>
: public TernaryFunctorBase<AlphaType,ValueType,ValueType,ValueType>
{
@@ -104,7 +104,7 @@ template< typename ValueType,
ValueType v1,
ValueType v2 ) const
{
- return (alpha*v1 +
+ return (alpha*v1 +
vigra::NumericTraits<AlphaType>::toPromote(
vigra::NumericTraits<AlphaType>::max()-alpha)*v2) /
vigra::NumericTraits<AlphaType>::max();
@@ -128,18 +128,18 @@ template< typename ColorType > struct ColorTraits
typedef ColorType component_type;
/// Calculate normalized distance between color c1 and c2
- static inline vigra::NormTraits<ColorType> distance( ColorType c1,
- ColorType c2 )
- {
+ static inline vigra::NormTraits<ColorType> distance( ColorType c1,
+ ColorType c2 )
+ {
return vigra::norm(c1 - c2);
}
- static inline component_type toGreyscale( ColorType c )
+ static inline component_type toGreyscale( ColorType c )
{
return c;
}
- static inline ColorType fromGreyscale( component_type c )
+ static inline ColorType fromGreyscale( component_type c )
{
return c;
}
diff --git a/basebmp/inc/basebmp/compositeiterator.hxx b/basebmp/inc/basebmp/compositeiterator.hxx
index 70f2acebb043..ed56ebd3579d 100755
--- a/basebmp/inc/basebmp/compositeiterator.hxx
+++ b/basebmp/inc/basebmp/compositeiterator.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -78,16 +78,16 @@ namespace detail
{ return *mpVal1 - *rhs.mpVal1; }
private:
- T1* mpVal1;
- T2* mpVal2;
+ T1* mpVal1;
+ T2* mpVal2;
};
- template< typename Iterator1,
- typename Iterator2,
- typename ValueType,
+ template< typename Iterator1,
+ typename Iterator2,
+ typename ValueType,
typename DifferenceType,
typename IteratorCategory,
- class Derived >
+ class Derived >
class CompositeIteratorBase : public NonStandardIterator
{
public:
@@ -109,12 +109,12 @@ namespace detail
public:
CompositeIteratorBase() :
- maIter1(),
+ maIter1(),
maIter2()
{}
CompositeIteratorBase( const iterator1_type& rIter1, const iterator2_type& rIter2 ) :
- maIter1( rIter1 ),
+ maIter1( rIter1 ),
maIter2( rIter2 )
{}
@@ -224,7 +224,7 @@ namespace detail
};
}
-/** Provide the composition of two 1D image iterators
+/** Provide the composition of two 1D image iterators
Use this template to compose two iterators into one (e.g. image
and mask). Operations are transitive, e.g. operator== only returns
@@ -234,31 +234,31 @@ namespace detail
avoid funny effects, iterator ranges given by a CompositeIterator
should consist of wrapped iterators of similar range
*/
-template< typename Iterator1,
+template< typename Iterator1,
typename Iterator2,
- typename ValueType,
+ typename ValueType,
typename DifferenceType,
- typename IteratorCategory >
-class CompositeIterator1D :
- public detail::CompositeIteratorBase< Iterator1,
- Iterator2,
+ typename IteratorCategory >
+class CompositeIterator1D :
+ public detail::CompositeIteratorBase< Iterator1,
+ Iterator2,
ValueType,
DifferenceType,
IteratorCategory,
- CompositeIterator1D<Iterator1,
+ CompositeIterator1D<Iterator1,
Iterator2,
- ValueType,
+ ValueType,
DifferenceType,
IteratorCategory> >
{
- typedef detail::CompositeIteratorBase< Iterator1,
- Iterator2,
+ typedef detail::CompositeIteratorBase< Iterator1,
+ Iterator2,
ValueType,
DifferenceType,
IteratorCategory,
- CompositeIterator1D<Iterator1,
+ CompositeIterator1D<Iterator1,
Iterator2,
- ValueType,
+ ValueType,
DifferenceType,
IteratorCategory> > base_type;
public:
@@ -266,13 +266,13 @@ public:
base_type()
{}
- CompositeIterator1D( const Iterator1& rIter1,
+ CompositeIterator1D( const Iterator1& rIter1,
const Iterator2& rIter2 ) :
base_type( rIter1, rIter2 )
{}
};
-/** Provide the composition of two 2D image iterators
+/** Provide the composition of two 2D image iterators
Use this template to compose two iterators into one (e.g. image
and mask). Operations are transitive, e.g. operator== only returns
@@ -282,23 +282,23 @@ public:
avoid funny effects, iterator ranges given by a CompositeIterator
should consist of wrapped iterators of similar range
*/
-template< typename Iterator1, typename Iterator2 > class CompositeIterator2D :
- public detail::CompositeIteratorBase< Iterator1,
- Iterator2,
+template< typename Iterator1, typename Iterator2 > class CompositeIterator2D :
+ public detail::CompositeIteratorBase< Iterator1,
+ Iterator2,
std::pair<
- typename vigra::IteratorTraits<Iterator1>::value_type,
+ typename vigra::IteratorTraits<Iterator1>::value_type,
typename vigra::IteratorTraits<Iterator2>::value_type >,
- typename vigra::IteratorTraits<Iterator1>::difference_type,
- typename vigra::IteratorTraits<Iterator1>::iterator_category,
+ typename vigra::IteratorTraits<Iterator1>::difference_type,
+ typename vigra::IteratorTraits<Iterator1>::iterator_category,
CompositeIterator2D<Iterator1, Iterator2> >
{
- typedef detail::CompositeIteratorBase< Iterator1,
- Iterator2,
+ typedef detail::CompositeIteratorBase< Iterator1,
+ Iterator2,
std::pair<
- typename vigra::IteratorTraits<Iterator1>::value_type,
+ typename vigra::IteratorTraits<Iterator1>::value_type,
typename vigra::IteratorTraits<Iterator2>::value_type >,
- typename vigra::IteratorTraits<Iterator1>::difference_type,
- typename vigra::IteratorTraits<Iterator1>::iterator_category,
+ typename vigra::IteratorTraits<Iterator1>::difference_type,
+ typename vigra::IteratorTraits<Iterator1>::iterator_category,
CompositeIterator2D<Iterator1, Iterator2> > base_type;
public:
typedef CompositeIterator1D< typename Iterator1::row_iterator,
@@ -361,7 +361,7 @@ public:
this->maIter2.columnIterator());
}
};
-
+
} // namespace basebmp
#endif /* INCLUDED_BASEBMP_COMPOSITEITERATOR_HXX */
diff --git a/basebmp/inc/basebmp/debug.hxx b/basebmp/inc/basebmp/debug.hxx
index a01d69326307..21fad45c6a6e 100644
--- a/basebmp/inc/basebmp/debug.hxx
+++ b/basebmp/inc/basebmp/debug.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -36,13 +36,13 @@ namespace basebmp
class BitmapDevice;
/** Dump content of BitmapDevice to given output stream.
-
- @param rDevice
+
+ @param rDevice
Device whose content should be dumped.
-
- @param rOutputStream
- Stream to write output to.
- */
+
+ @param rOutputStream
+ Stream to write output to.
+ */
void debugDump( const boost::shared_ptr< BitmapDevice >& rDevice,
::std::ostream& rOutputStream );
}
diff --git a/basebmp/inc/basebmp/drawmodes.hxx b/basebmp/inc/basebmp/drawmodes.hxx
index 6cdf34fd808a..aed821ce23cc 100644
--- a/basebmp/inc/basebmp/drawmodes.hxx
+++ b/basebmp/inc/basebmp/drawmodes.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -32,7 +32,7 @@
namespace basebmp
{
- enum DrawMode
+ enum DrawMode
{
/** Default draw mode, which simply renders pixel in the
requested color
diff --git a/basebmp/inc/basebmp/endian.hxx b/basebmp/inc/basebmp/endian.hxx
index fb76ad1b306e..a11761857475 100644
--- a/basebmp/inc/basebmp/endian.hxx
+++ b/basebmp/inc/basebmp/endian.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/basebmp/inc/basebmp/fillimage.hxx b/basebmp/inc/basebmp/fillimage.hxx
index 344ee20e6ce5..a1e708fbb7e2 100644
--- a/basebmp/inc/basebmp/fillimage.hxx
+++ b/basebmp/inc/basebmp/fillimage.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -35,8 +35,8 @@ namespace basebmp
{
template< class DestIterator, class DestAccessor, typename T >
-void fillImage( DestIterator begin,
- DestIterator end,
+void fillImage( DestIterator begin,
+ DestIterator end,
DestAccessor ad,
T fillVal )
{
@@ -49,9 +49,9 @@ void fillImage( DestIterator begin,
rowIter( begin.rowIterator() );
const typename vigra::IteratorTraits<DestIterator>::row_iterator
rowEnd( rowIter + width );
-
- // TODO(P2): Provide specialized span fill methods on the
- // iterator/accessor
+
+ // TODO(P2): Provide specialized span fill methods on the
+ // iterator/accessor
while( rowIter != rowEnd )
ad.set(fillVal, rowIter++);
}
diff --git a/basebmp/inc/basebmp/genericcolorimageaccessor.hxx b/basebmp/inc/basebmp/genericcolorimageaccessor.hxx
index eaf8e2b34bfa..c6fb797d8815 100644
--- a/basebmp/inc/basebmp/genericcolorimageaccessor.hxx
+++ b/basebmp/inc/basebmp/genericcolorimageaccessor.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -51,17 +51,17 @@ namespace basebmp
meDrawMode(DrawMode_PAINT)
{}
- GenericColorImageAccessor( BitmapDeviceSharedPtr const& rTarget,
+ GenericColorImageAccessor( BitmapDeviceSharedPtr const& rTarget,
DrawMode eDrawMode ) :
mpDevice(rTarget),
meDrawMode(eDrawMode)
{}
- template< typename Iterator >
+ template< typename Iterator >
Color operator()( Iterator const& i ) const
{ return mpDevice->getPixel( basegfx::B2IPoint( i->x,i->y ) ); }
- template< typename Iterator, typename Difference >
+ template< typename Iterator, typename Difference >
Color operator()( Iterator const& i, Difference const& diff) const
{ return mpDevice->getPixel( basegfx::B2IPoint( i[diff]->x,
i[diff]->y ) ); }
diff --git a/basebmp/inc/basebmp/greylevelformats.hxx b/basebmp/inc/basebmp/greylevelformats.hxx
index 0adbcbb53c30..ba0c82bffc09 100644
--- a/basebmp/inc/basebmp/greylevelformats.hxx
+++ b/basebmp/inc/basebmp/greylevelformats.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -44,29 +44,29 @@
namespace basebmp
{
-template< typename PixelType,
+template< typename PixelType,
typename ColorType,
- int UsedRange > struct GreylevelGetter :
- public std::unary_function<PixelType, ColorType>
+ int UsedRange > struct GreylevelGetter :
+ public std::unary_function<PixelType, ColorType>
{
ColorType operator()( PixelType const& c ) const
- {
+ {
return ColorTraits<ColorType>::fromGreyscale(
vigra::NumericTraits<PixelType>::toPromote(c) *
vigra::NumericTraits<PixelType>::maxConst / UsedRange );
}
};
-template< typename PixelType,
+template< typename PixelType,
typename ColorType,
- int UsedRange > struct GreylevelSetter :
- public std::unary_function<ColorType, PixelType>
+ int UsedRange > struct GreylevelSetter :
+ public std::unary_function<ColorType, PixelType>
{
PixelType operator()( ColorType const& c ) const
{
return vigra::NumericTraits<PixelType>::toPromote(
- ColorTraits<ColorType>::toGreyscale(c)) *
- UsedRange /
+ ColorTraits<ColorType>::toGreyscale(c)) *
+ UsedRange /
vigra::NumericTraits<PixelType>::maxConst;
}
};
@@ -95,7 +95,7 @@ template< class Iterator,
template< int BitsPerPixel,
bool MsbFirst > struct PixelFormatTraitsTemplate_PackedGreylevel :
- public PixelFormatTraitsTemplate_Greylevel<
+ public PixelFormatTraitsTemplate_Greylevel<
PackedPixelIterator< sal_uInt8,
BitsPerPixel,
true >,
@@ -123,7 +123,7 @@ BASEBMP_SPECIALIZE_ACCESSORTRAITS(PixelFormatTraits_GREY4_MSB::getter_type,
PixelFormatTraits_GREY4_MSB::setter_type);
// 8bpp
-typedef PixelFormatTraitsTemplate_Greylevel<
+typedef PixelFormatTraitsTemplate_Greylevel<
PixelIterator< sal_uInt8 >,
StandardAccessor< sal_uInt8 >,
255 > PixelFormatTraits_GREY8;
diff --git a/basebmp/inc/basebmp/iteratortraits.hxx b/basebmp/inc/basebmp/iteratortraits.hxx
index 716081f62c53..28dcacc1a470 100644
--- a/basebmp/inc/basebmp/iteratortraits.hxx
+++ b/basebmp/inc/basebmp/iteratortraits.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -37,17 +37,17 @@ namespace basebmp
template< class Iterator > struct IteratorTraits
{
/// VigraTrueType, if iterator does not provide *operator()/operator[] methods
- typedef typename vigra::IsDerivedFrom<Iterator,NonStandardIterator>::result
+ typedef typename vigra::IsDerivedFrom<Iterator,NonStandardIterator>::result
isNonStandardIterator;
/// Retrieve default accessor for this iterator (and given value type)
template< typename ValueType > struct defaultAccessor : public
- // select according to non-standardness of iterator type
+ // select according to non-standardness of iterator type
vigra::If< isNonStandardIterator,
NonStandardAccessor< ValueType >,
StandardAccessor< ValueType > >
{};
-
+
};
} // namespace basebmp
diff --git a/basebmp/inc/basebmp/linerenderer.hxx b/basebmp/inc/basebmp/linerenderer.hxx
index 7c5f09dbb2d1..4eb36a023f3a 100644
--- a/basebmp/inc/basebmp/linerenderer.hxx
+++ b/basebmp/inc/basebmp/linerenderer.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -60,7 +60,7 @@ namespace basebmp
@param end
right-bottom image iterator
-
+
@param acc
Image accessor
@@ -70,12 +70,12 @@ namespace basebmp
pixel, the pixel closer to pt1 will be chosen. Giving true here
makes renderClippedLine() choose pt2 in those cases.
*/
-template< class Iterator, class Accessor >
+template< class Iterator, class Accessor >
void renderLine( const basegfx::B2IPoint& rPt1,
const basegfx::B2IPoint& rPt2,
typename Accessor::value_type color,
- Iterator begin,
- Accessor acc,
+ Iterator begin,
+ Accessor acc,
bool bRoundTowardsPt2=false )
{
// code inspired by Paul Heckbert's Digital Line Drawing
@@ -114,7 +114,7 @@ void renderLine( const basegfx::B2IPoint& rPt1,
ady *= 2;
Iterator currIter( begin + vigra::Diff2D(0,ys) );
- typename vigra::IteratorTraits<Iterator>::row_iterator
+ typename vigra::IteratorTraits<Iterator>::row_iterator
rowIter( currIter.rowIterator() + xs );
while(true)
{
@@ -123,7 +123,7 @@ void renderLine( const basegfx::B2IPoint& rPt1,
if( xs == x2 )
return;
- if( rem >= 0 )
+ if( rem >= 0 )
{
ys += sy;
xs += sx;
@@ -148,7 +148,7 @@ void renderLine( const basegfx::B2IPoint& rPt1,
ady *= 2;
Iterator currIter( begin + vigra::Diff2D(xs,0) );
- typename vigra::IteratorTraits<Iterator>::column_iterator
+ typename vigra::IteratorTraits<Iterator>::column_iterator
colIter( currIter.columnIterator() + ys );
while(true)
{
@@ -156,8 +156,8 @@ void renderLine( const basegfx::B2IPoint& rPt1,
if( ys == y2 )
return;
-
- if( rem >= 0 )
+
+ if( rem >= 0 )
{
xs += sx;
ys += sy;
diff --git a/basebmp/inc/basebmp/metafunctions.hxx b/basebmp/inc/basebmp/metafunctions.hxx
index 7eafac284f56..ae7a9c6ae850 100644
--- a/basebmp/inc/basebmp/metafunctions.hxx
+++ b/basebmp/inc/basebmp/metafunctions.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -35,12 +35,12 @@
namespace basebmp
{
-// TODO(Q3): move to generic place (o3tl?)
+// TODO(Q3): move to generic place (o3tl?)
/** template meta function: add const qualifier to 2nd type, if given
1st type has it
*/
-template<typename A, typename B> struct clone_const
+template<typename A, typename B> struct clone_const
{
typedef B type;
};
@@ -52,7 +52,7 @@ template<typename A, typename B> struct clone_const<const A,B>
/** template meta function: add const qualifier to plain type (if not
already there)
*/
-template <typename T> struct add_const
+template <typename T> struct add_const
{
typedef const T type;
};
@@ -62,7 +62,7 @@ template <typename T> struct add_const<const T>
};
/// template meta function: remove const qualifier from plain type
-template <typename T> struct remove_const
+template <typename T> struct remove_const
{
typedef T type;
};
@@ -134,10 +134,10 @@ inline bool is_negative( int x )
template< typename T, typename trueCase, typename falseCase >
struct ifScalarIntegral
{
- typedef
- typename vigra::If<
+ typedef
+ typename vigra::If<
typename vigra::NumericTraits< T >::isIntegral,
- typename vigra::If<
+ typename vigra::If<
typename vigra::NumericTraits< T >::isScalar,
trueCase,
falseCase >::type,
@@ -148,11 +148,11 @@ struct ifScalarIntegral
template< typename T, typename trueCase, typename falseCase >
struct ifScalarNonIntegral
{
- typedef
- typename vigra::If<
+ typedef
+ typename vigra::If<
typename vigra::NumericTraits< T >::isIntegral,
falseCase,
- typename vigra::If<
+ typename vigra::If<
typename vigra::NumericTraits< T >::isScalar,
trueCase,
falseCase >::type >::type type;
@@ -162,11 +162,11 @@ struct ifScalarNonIntegral
template< typename T1, typename T2, typename trueCase, typename falseCase >
struct ifBothScalarIntegral
{
- typedef
- typename ifScalarIntegral<
- T1,
- typename ifScalarIntegral<
- T2,
+ typedef
+ typename ifScalarIntegral<
+ T1,
+ typename ifScalarIntegral<
+ T2,
trueCase,
falseCase >::type,
falseCase >::type type;
@@ -190,7 +190,7 @@ template<> struct numberOfTrailingZeros<0>
//--------------------------------------------------------------
-/// Count number of one bits
+/// Count number of one bits
template< unsigned int val > struct bitcount
{
enum { next = val >> 1 };
@@ -204,13 +204,13 @@ template<> struct bitcount<0>
//--------------------------------------------------------------
-/// Shift left for positive shift value, and right otherwise
+/// Shift left for positive shift value, and right otherwise
template< typename T > inline T shiftLeft( T v, int shift )
{
return shift > 0 ? v << shift : v >> (-shift);
}
-/// Shift right for positive shift value, and left otherwise
+/// Shift right for positive shift value, and left otherwise
template< typename T > inline T shiftRight( T v, int shift )
{
return shift > 0 ? v >> shift : v << (-shift);
diff --git a/basebmp/inc/basebmp/nonstandarditerator.hxx b/basebmp/inc/basebmp/nonstandarditerator.hxx
index c9069da18826..b5b2dfebda7f 100644
--- a/basebmp/inc/basebmp/nonstandarditerator.hxx
+++ b/basebmp/inc/basebmp/nonstandarditerator.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/basebmp/inc/basebmp/packedpixeliterator.hxx b/basebmp/inc/basebmp/packedpixeliterator.hxx
index 0a48ce2024ff..24d5ec9bf025 100644
--- a/basebmp/inc/basebmp/packedpixeliterator.hxx
+++ b/basebmp/inc/basebmp/packedpixeliterator.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -41,10 +41,10 @@ namespace basebmp
{
/// Get bitmask for data at given intra-word position, for given bit depth
-template< typename value_type,
- int bits_per_pixel,
- bool MsbFirst,
- typename difference_type >
+template< typename value_type,
+ int bits_per_pixel,
+ bool MsbFirst,
+ typename difference_type >
inline value_type get_mask( difference_type d )
{
BOOST_STATIC_ASSERT(bits_per_pixel > 0);
@@ -55,20 +55,20 @@ inline value_type get_mask( difference_type d )
const unsigned int nIntraWordPositions( sizeof(value_type)*8 / bits_per_pixel );
// create bits_per_pixel 1s shift to intra-word position
- return ((~(~0 << bits_per_pixel)) << bits_per_pixel*(MsbFirst ?
- (nIntraWordPositions-1 - (d % nIntraWordPositions)) :
+ return ((~(~0 << bits_per_pixel)) << bits_per_pixel*(MsbFirst ?
+ (nIntraWordPositions-1 - (d % nIntraWordPositions)) :
(d % nIntraWordPositions)));
}
template< int num_intraword_positions, int bits_per_pixel, bool MsbFirst, typename difference_type > inline difference_type get_shift( difference_type remainder )
{
- return bits_per_pixel*(MsbFirst ?
+ return bits_per_pixel*(MsbFirst ?
(num_intraword_positions - 1 - remainder) :
remainder);
}
-template< typename Valuetype,
- int bits_per_pixel,
+template< typename Valuetype,
+ int bits_per_pixel,
bool MsbFirst > class PackedPixelColumnIterator : public NonStandardIterator
{
public:
@@ -238,8 +238,8 @@ public:
}
};
-template< typename Valuetype,
- int bits_per_pixel,
+template< typename Valuetype,
+ int bits_per_pixel,
bool MsbFirst > class PackedPixelRowIterator : public NonStandardIterator
{
public:
@@ -279,12 +279,12 @@ private:
remainder_ = newValue % num_intraword_positions;
const mask_type shifted_mask(
- MsbFirst ?
- unsigned_cast<mask_type>(mask_) >> bits_per_pixel :
+ MsbFirst ?
+ unsigned_cast<mask_type>(mask_) >> bits_per_pixel :
mask_ << bits_per_pixel );
// data_offset is 0 for shifted mask, and 1 for wrapped-around mask
- mask_ = (1-data_offset)*shifted_mask + data_offset*(MsbFirst ?
+ mask_ = (1-data_offset)*shifted_mask + data_offset*(MsbFirst ?
bit_mask << bits_per_pixel*(num_intraword_positions-1) :
bit_mask);
}
@@ -307,12 +307,12 @@ private:
remainder_ = newRemainder + isNegative*num_intraword_positions;
const mask_type shifted_mask(
- MsbFirst ?
+ MsbFirst ?
mask_ << bits_per_pixel :
unsigned_cast<mask_type>(mask_) >> bits_per_pixel );
// data_offset is 0 for shifted mask, and 1 for wrapped-around mask
- mask_ = (1-data_offset)*shifted_mask + data_offset*(MsbFirst ?
+ mask_ = (1-data_offset)*shifted_mask + data_offset*(MsbFirst ?
bit_mask :
bit_mask << bits_per_pixel*(num_intraword_positions-1));
}
@@ -324,8 +324,8 @@ private:
bool less( PackedPixelRowIterator const & rhs ) const
{
- return data_ == rhs.data_ ?
- (remainder_ < rhs.remainder_) :
+ return data_ == rhs.data_ ?
+ (remainder_ < rhs.remainder_) :
(data_ < rhs.data_);
}
@@ -448,9 +448,9 @@ public:
value_type get() const
{
- return unsigned_cast<value_type>(*data_ & mask_) >>
- get_shift<num_intraword_positions,
- bits_per_pixel,
+ return unsigned_cast<value_type>(*data_ & mask_) >>
+ get_shift<num_intraword_positions,
+ bits_per_pixel,
MsbFirst>(remainder_);
}
@@ -463,9 +463,9 @@ public:
void set( value_type v ) const
{
- const value_type pixel_value(
- (v <<
- get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder_))
+ const value_type pixel_value(
+ (v <<
+ get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder_))
& mask_ );
*data_ = (*data_ & ~mask_) | pixel_value;
}
@@ -484,8 +484,8 @@ public:
one pixel into an machine data type (like one bit per pixel, eight
of which packed into one char)
*/
-template< typename Valuetype,
- int bits_per_pixel,
+template< typename Valuetype,
+ int bits_per_pixel,
bool MsbFirst > class PackedPixelIterator : public NonStandardIterator
{
public:
@@ -494,10 +494,10 @@ public:
typedef vigra::Diff2D difference_type;
typedef image_traverser_tag iterator_category;
typedef PackedPixelRowIterator<value_type,
- bits_per_pixel,
+ bits_per_pixel,
MsbFirst> row_iterator;
typedef PackedPixelColumnIterator<value_type,
- bits_per_pixel,
+ bits_per_pixel,
MsbFirst> column_iterator;
typedef value_type* pointer;
@@ -518,12 +518,12 @@ public:
private:
pointer current() const
- {
+ {
return y() + (x / num_intraword_positions);
}
pointer current(int dx, int dy) const
- {
+ {
return y(dy) + ((x+dx)/num_intraword_positions);
}
@@ -605,27 +605,27 @@ public:
{
const int remainder( x % num_intraword_positions );
- return (unsigned_cast<value_type>(*current() &
+ return (unsigned_cast<value_type>(*current() &
get_mask<value_type, bits_per_pixel, MsbFirst>(remainder))
- >> get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder));
+ >> get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder));
}
value_type get(difference_type const & d) const
{
const int remainder( x(d.x) % num_intraword_positions );
- return (unsigned_cast<value_type>(*current(d.x,d.y) &
+ return (unsigned_cast<value_type>(*current(d.x,d.y) &
get_mask<value_type, bits_per_pixel, MsbFirst>(remainder))
- >> get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder));
+ >> get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder));
}
void set( value_type v ) const
{
const int remainder( x % num_intraword_positions );
const int mask( get_mask<value_type, bits_per_pixel, MsbFirst>(remainder) );
- const value_type pixel_value(
- (v <<
- get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder))
+ const value_type pixel_value(
+ (v <<
+ get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder))
& mask );
pointer p = current();
*p = (*p & ~mask) | pixel_value;
@@ -635,9 +635,9 @@ public:
{
const int remainder( (x + d.x) % num_intraword_positions );
const int mask( get_mask<value_type, bits_per_pixel, MsbFirst>(remainder) );
- const value_type pixel_value(
+ const value_type pixel_value(
(v <<
- get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder))
+ get_shift<num_intraword_positions, bits_per_pixel, MsbFirst>(remainder))
& mask );
pointer p = current(d.x,d.y);
*p = (*p & ~mask) | pixel_value;
@@ -649,11 +649,11 @@ public:
// partial specialization for the accessor traits masked_accessor
// selector metafunction - can employ fast mask functor for the 1bpp
// case.
-template< class Accessor,
- class MaskAccessor,
+template< class Accessor,
+ class MaskAccessor,
class Iterator,
bool polarity,
- bool MsbFirst > struct maskedAccessorSelector< Accessor,
+ bool MsbFirst > struct maskedAccessorSelector< Accessor,
MaskAccessor,
Iterator,
PackedPixelIterator< typename MaskAccessor::value_type,
@@ -661,7 +661,7 @@ template< class Accessor,
MsbFirst >,
polarity >
{
- typedef TernarySetterFunctionAccessorAdapter<
+ typedef TernarySetterFunctionAccessorAdapter<
Accessor,
MaskAccessor,
typename outputMaskFunctorSelector<
diff --git a/basebmp/inc/basebmp/paletteformats.hxx b/basebmp/inc/basebmp/paletteformats.hxx
index d3de0ea18dd7..29129ba45ee3 100644
--- a/basebmp/inc/basebmp/paletteformats.hxx
+++ b/basebmp/inc/basebmp/paletteformats.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -48,7 +48,7 @@ namespace basebmp
//-----------------------------------------------------------------------------
/** Lookup index value for given color value in a PaletteImageAccessor
- */
+ */
template< class Accessor > struct ColorLookup
{
typename Accessor::data_type operator()( const Accessor& acc,
@@ -61,7 +61,7 @@ template< class Accessor > struct ColorLookup
//-----------------------------------------------------------------------------
// partial specialization of AccessorTraits for PaletteAccessor
-template< class Accessor, typename ColorType > struct AccessorTraits<
+template< class Accessor, typename ColorType > struct AccessorTraits<
PaletteImageAccessor< Accessor, ColorType > >
{
/// value type of described accessor
@@ -85,7 +85,7 @@ template< class Accessor, typename ColorType > struct AccessorTraits<
* want to wrap a masked_accessor with a PaletteAccessor, not the
* other way around.
*/
- template< class MaskAccessor,
+ template< class MaskAccessor,
class Iterator,
class MaskIterator > struct masked_accessor
{
@@ -116,7 +116,7 @@ template< class Iterator,
template< int BitsPerPixel,
bool MsbFirst > struct PixelFormatTraitsTemplate_PackedPalette :
- public PixelFormatTraitsTemplate_Palette<
+ public PixelFormatTraitsTemplate_Palette<
PackedPixelIterator< sal_uInt8,
BitsPerPixel,
MsbFirst >,
@@ -138,7 +138,7 @@ typedef PixelFormatTraitsTemplate_PackedPalette<4, true> PixelFormatTraits_PAL4
typedef PixelFormatTraitsTemplate_PackedPalette<4, false> PixelFormatTraits_PAL4_LSB;
// 8bpp
-typedef PixelFormatTraitsTemplate_Palette<
+typedef PixelFormatTraitsTemplate_Palette<
PixelIterator< sal_uInt8 >,
StandardAccessor< sal_uInt8 > > PixelFormatTraits_PAL8;
diff --git a/basebmp/inc/basebmp/paletteimageaccessor.hxx b/basebmp/inc/basebmp/paletteimageaccessor.hxx
index 79bbb9aae9b7..9e7033c5f086 100644
--- a/basebmp/inc/basebmp/paletteimageaccessor.hxx
+++ b/basebmp/inc/basebmp/paletteimageaccessor.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -61,26 +61,26 @@ private:
template<class A, typename C> friend class PaletteImageAccessor;
#endif
- Accessor maAccessor;
+ Accessor maAccessor;
const value_type* mpPalette;
std::size_t mnNumEntries;
public:
- PaletteImageAccessor() :
+ PaletteImageAccessor() :
maAccessor(),
mpPalette(0),
mnNumEntries(0)
{}
- template< class A > explicit
- PaletteImageAccessor( PaletteImageAccessor<A,ColorType> const& rSrc ) :
+ template< class A > explicit
+ PaletteImageAccessor( PaletteImageAccessor<A,ColorType> const& rSrc ) :
maAccessor( rSrc.maAccessor ),
mpPalette( rSrc.mpPalette ),
mnNumEntries( rSrc.mnNumEntries )
{}
PaletteImageAccessor( const value_type* pPalette,
- std::size_t numEntries ) :
+ std::size_t numEntries ) :
maAccessor(),
mpPalette(pPalette),
mnNumEntries(numEntries)
@@ -88,7 +88,7 @@ public:
template< class T > PaletteImageAccessor( T accessor,
const value_type* pPalette,
- std::size_t numEntries ) :
+ std::size_t numEntries ) :
maAccessor(accessor),
mpPalette(pPalette),
mnNumEntries(numEntries)
@@ -114,7 +114,7 @@ public:
while( curr_entry != palette_end )
{
if( ColorTraits<value_type>::distance(*curr_entry,
- *best_entry)
+ *best_entry)
> ColorTraits<value_type>::distance(*curr_entry,
v) )
{
@@ -130,22 +130,22 @@ public:
// -------------------------------------------------------
template< class Iterator >
- value_type operator()(Iterator const& i) const
- {
- return mpPalette[ maAccessor(i) ];
+ value_type operator()(Iterator const& i) const
+ {
+ return mpPalette[ maAccessor(i) ];
}
template< class Iterator, class Difference >
value_type operator()(Iterator const& i, Difference const& diff) const
{
- return mpPalette[ maAccessor(i,diff) ];
+ return mpPalette[ maAccessor(i,diff) ];
}
// -------------------------------------------------------
template< typename V, class Iterator >
void set(V const& value, Iterator const& i) const
- {
+ {
maAccessor.set(
lookup(
vigra::detail::RequiresExplicitCast<value_type>::cast(value) ),
diff --git a/basebmp/inc/basebmp/pixelformatadapters.hxx b/basebmp/inc/basebmp/pixelformatadapters.hxx
index 2acd90b5bea8..d765ed4b29d5 100644
--- a/basebmp/inc/basebmp/pixelformatadapters.hxx
+++ b/basebmp/inc/basebmp/pixelformatadapters.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -52,12 +52,12 @@ namespace basebmp
to other templates, which in turn can invoke the nested meta
function.
*/
-template< typename Getter,
+template< typename Getter,
typename Setter > struct AccessorSelector
{
template< typename Accessor > struct wrap_accessor
{
- typedef UnaryFunctionAccessorAdapter< Accessor,
+ typedef UnaryFunctionAccessorAdapter< Accessor,
Getter,
Setter > type;
};
@@ -66,7 +66,7 @@ template< typename Getter,
//-----------------------------------------------------------------------------
/** Convert color value to pixel data type
- */
+ */
template< class Accessor, typename DataType > struct ColorConvert
{
DataType operator()( const Accessor& acc,
diff --git a/basebmp/inc/basebmp/pixeliterator.hxx b/basebmp/inc/basebmp/pixeliterator.hxx
index 84b99942927b..05ce99f51c42 100644
--- a/basebmp/inc/basebmp/pixeliterator.hxx
+++ b/basebmp/inc/basebmp/pixeliterator.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -228,13 +228,13 @@ private:
}
pointer current() const
- {
- return y() + x;
+ {
+ return y() + x;
}
pointer current(int dx, int dy) const
- {
- return y(dy) + x+dx;
+ {
+ return y(dy) + x+dx;
}
public:
diff --git a/basebmp/inc/basebmp/polypolygonrenderer.hxx b/basebmp/inc/basebmp/polypolygonrenderer.hxx
index 7cfacad510e5..7c81c167f47b 100644
--- a/basebmp/inc/basebmp/polypolygonrenderer.hxx
+++ b/basebmp/inc/basebmp/polypolygonrenderer.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -66,28 +66,28 @@ namespace basebmp
sal_Int64 mnX;
sal_Int64 mnXDelta;
- bool mbDownwards; // needed for nonzero winding rule
+ bool mbDownwards; // needed for nonzero winding rule
// fills
- Vertex() :
- mnYCounter(0),
+ Vertex() :
+ mnYCounter(0),
mnX(0),
mnXDelta(0),
mbDownwards(true)
{}
- Vertex( basegfx::B2DPoint const& rPt1,
- basegfx::B2DPoint const& rPt2,
- bool bDownwards ) :
- mnYCounter( basegfx::fround(rPt2.getY()) -
- basegfx::fround(rPt1.getY()) ),
+ Vertex( basegfx::B2DPoint const& rPt1,
+ basegfx::B2DPoint const& rPt2,
+ bool bDownwards ) :
+ mnYCounter( basegfx::fround(rPt2.getY()) -
+ basegfx::fround(rPt1.getY()) ),
mnX( toFractional( basegfx::fround(rPt1.getX()) )),
mnXDelta( toFractional(
- ((rPt2.getX() - rPt1.getX()) /
+ ((rPt2.getX() - rPt1.getX()) /
(double)mnYCounter) )),
mbDownwards(bDownwards)
{}
};
-
+
typedef std::vector< std::vector<Vertex> > VectorOfVectorOfVertices;
typedef std::vector< Vertex* > VectorOfVertexPtr;
@@ -138,12 +138,12 @@ namespace basebmp
@param rClipRect
Clipping rectangle, relative to the begin iterator. No pixel outside
this clip rect will be modified.
-
+
@param rPoly
Polygon to fill
*/
template< class DestIterator, class DestAccessor, typename T >
- void renderClippedPolyPolygon( DestIterator begin,
+ void renderClippedPolyPolygon( DestIterator begin,
DestAccessor ad,
T fillColor,
const basegfx::B2IRange& rClipRect,
@@ -159,8 +159,8 @@ namespace basebmp
basegfx::B2DRange const aPolyBounds( basegfx::tools::getRange(rPoly) );
- const sal_Int32 nMinY( basegfx::fround(aPolyBounds.getMinY()) );
- const sal_Int32 nMaxY(
+ const sal_Int32 nMinY( basegfx::fround(aPolyBounds.getMinY()) );
+ const sal_Int32 nMaxY(
std::min(
nClipY2-1,
basegfx::fround(aPolyBounds.getMaxY())));
@@ -191,7 +191,7 @@ namespace basebmp
// current scanline - initially, points to first scanline
// within the clip rect, or to the polygon's first scanline
// (whichever is greater)
- DestIterator aScanline( begin +
+ DestIterator aScanline( begin +
vigra::Diff2D(
0,
std::max(nMinY,
@@ -212,14 +212,14 @@ namespace basebmp
detail::VectorOfVectorOfVertices::value_type::iterator const end=aGET[y-nMinY].end();
while( vertex != end )
{
- // find insertion pos by binary search, and put ptr
- // into active edge vector
+ // find insertion pos by binary search, and put ptr
+ // into active edge vector
pAET->insert( std::lower_bound( pAET->begin(),
pAET->end(),
&(*vertex),
aComp ),
&(*vertex) );
-
+
++vertex;
}
}
@@ -227,7 +227,7 @@ namespace basebmp
// with less than two active edges, no fill visible
if( pAET->size() >= 2 )
{
- typename vigra::IteratorTraits<DestIterator>::row_iterator
+ typename vigra::IteratorTraits<DestIterator>::row_iterator
rowIter( aScanline.rowIterator() );
// process each span in current scanline, with
@@ -248,9 +248,9 @@ namespace basebmp
// calc fill status for both rules. might save a
// few percent runtime to specialize here...
- const bool bEvenOddFill(
+ const bool bEvenOddFill(
eFillRule == basegfx::FillRule_EVEN_ODD && !(nCrossedEdges & 0x01) );
- const bool bNonZeroWindingFill(
+ const bool bNonZeroWindingFill(
eFillRule == basegfx::FillRule_NONZERO_WINDING_NUMBER && nWindingNumber != 0 );
// is span visible?
@@ -260,18 +260,18 @@ namespace basebmp
rV2.mnX > nClipX1_frac )
{
// clip span to horizontal bounds
- sal_Int32 const nStartX(
+ sal_Int32 const nStartX(
std::max( nClipX1,
std::min( nClipX2-1,
detail::toRoundedInteger(rV1.mnX) )));
- sal_Int32 const nEndX(
+ sal_Int32 const nEndX(
std::max( nClipX1,
std::min( nClipX2,
detail::toRoundedInteger(rV2.mnX) )));
- typename vigra::IteratorTraits<DestIterator>::row_iterator
+ typename vigra::IteratorTraits<DestIterator>::row_iterator
currPix( rowIter + nStartX);
- typename vigra::IteratorTraits<DestIterator>::row_iterator
+ typename vigra::IteratorTraits<DestIterator>::row_iterator
rowEnd( rowIter + nEndX );
// TODO(P2): Provide specialized span fill methods on the
@@ -283,7 +283,7 @@ namespace basebmp
// step vertices
rV1.mnX += rV1.mnXDelta;
--rV1.mnYCounter;
-
+
++nCrossedEdges;
}
@@ -352,7 +352,7 @@ namespace basebmp
if( !bFallbackTaken && (*currVertex)->mnYCounter > 0 )
pAETOther->push_back( *currVertex );
}
-
+
std::swap( pAET, pAETOther );
}
diff --git a/basebmp/inc/basebmp/rgb24pixelformats.hxx b/basebmp/inc/basebmp/rgb24pixelformats.hxx
index 788144a50b8d..17a0b5f641b3 100644
--- a/basebmp/inc/basebmp/rgb24pixelformats.hxx
+++ b/basebmp/inc/basebmp/rgb24pixelformats.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -40,17 +40,17 @@
namespace basebmp
{
-template< typename PixelType, typename ColorType > struct RGBValueGetter :
- public std::unary_function<PixelType, ColorType>
+template< typename PixelType, typename ColorType > struct RGBValueGetter :
+ public std::unary_function<PixelType, ColorType>
{
ColorType operator()( PixelType const& c ) const
- {
- return ColorType(c.red(),c.green(),c.blue());
+ {
+ return ColorType(c.red(),c.green(),c.blue());
}
};
-template< typename PixelType, typename ColorType > struct RGBValueSetter :
- public std::unary_function<ColorType, PixelType>
+template< typename PixelType, typename ColorType > struct RGBValueSetter :
+ public std::unary_function<ColorType, PixelType>
{
PixelType operator()( ColorType const& c ) const
{
diff --git a/basebmp/inc/basebmp/rgbmaskpixelformats.hxx b/basebmp/inc/basebmp/rgbmaskpixelformats.hxx
index d42125239529..b68630ee9600 100644
--- a/basebmp/inc/basebmp/rgbmaskpixelformats.hxx
+++ b/basebmp/inc/basebmp/rgbmaskpixelformats.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -67,8 +67,8 @@ namespace basebmp
@tpl SwapBytes
When true, the final pixel values will be byte-swapped before
passed on.
- */
-template< typename PixelType,
+ */
+template< typename PixelType,
typename ColorType,
unsigned int RedMask,
unsigned int GreenMask,
@@ -81,7 +81,7 @@ template< typename PixelType,
typedef typename ColorTraits<ColorType>::component_type component_type;
// calc corrective shifts for all three channels in advance
- enum {
+ enum {
red_shift = numberOfTrailingZeros<RedMask>::value,
green_shift = numberOfTrailingZeros<GreenMask>::value,
blue_shift = numberOfTrailingZeros<BlueMask>::value,
@@ -92,19 +92,19 @@ template< typename PixelType,
};
};
-template< typename PixelType,
+template< typename PixelType,
typename ColorType,
unsigned int RedMask,
unsigned int GreenMask,
unsigned int BlueMask,
- bool SwapBytes > struct RGBMaskGetter :
+ bool SwapBytes > struct RGBMaskGetter :
public RGBMaskFunctorBase<PixelType,
ColorType,
RedMask,
GreenMask,
BlueMask,
SwapBytes>,
- public std::unary_function<PixelType, ColorType>
+ public std::unary_function<PixelType, ColorType>
{
typedef RGBMaskFunctorBase<PixelType,
ColorType,
@@ -114,7 +114,7 @@ template< typename PixelType,
SwapBytes> base_type;
ColorType operator()( PixelType v ) const
- {
+ {
v = SwapBytes ? byteSwap(v) : v;
const typename base_type::unsigned_pixel_type red (v & RedMask);
@@ -124,7 +124,7 @@ template< typename PixelType,
// shift color nibbles to right-aligend position. ORing it
// channel value shifted twice the number of channel bits, to
// spread the value into the component_type range
- ColorType res( (shiftRight(red,
+ ColorType res( (shiftRight(red,
base_type::red_shift-8*
(signed)sizeof(typename base_type::component_type)+
base_type::red_bits)) |
@@ -132,7 +132,7 @@ template< typename PixelType,
base_type::red_shift-8*
(signed)sizeof(typename base_type::component_type)+
2*base_type::red_bits)),
-
+
(shiftRight(green,
base_type::green_shift-8*
(signed)sizeof(typename base_type::component_type)+
@@ -141,7 +141,7 @@ template< typename PixelType,
base_type::green_shift-8*
(signed)sizeof(typename base_type::component_type)+
2*base_type::green_bits)),
-
+
(shiftRight(blue,
base_type::blue_shift-8*
(signed)sizeof(typename base_type::component_type)+
@@ -154,19 +154,19 @@ template< typename PixelType,
}
};
-template< typename PixelType,
+template< typename PixelType,
typename ColorType,
unsigned int RedMask,
unsigned int GreenMask,
unsigned int BlueMask,
- bool SwapBytes > struct RGBMaskSetter :
+ bool SwapBytes > struct RGBMaskSetter :
public RGBMaskFunctorBase<PixelType,
ColorType,
RedMask,
GreenMask,
BlueMask,
SwapBytes>,
- public std::unary_function<ColorType, PixelType>
+ public std::unary_function<ColorType, PixelType>
{
typedef RGBMaskFunctorBase<PixelType,
ColorType,
@@ -181,7 +181,7 @@ template< typename PixelType,
const typename base_type::unsigned_pixel_type green(c.getGreen());
const typename base_type::unsigned_pixel_type blue (c.getBlue());
- typename base_type::unsigned_pixel_type res(
+ typename base_type::unsigned_pixel_type res(
(shiftLeft(red,
base_type::red_shift-8*
(signed)sizeof(typename base_type::component_type)+
@@ -201,7 +201,7 @@ template< typename PixelType,
//-----------------------------------------------------------------------------
-template< typename PixelType,
+template< typename PixelType,
unsigned int RedMask,
unsigned int GreenMask,
unsigned int BlueMask,
diff --git a/basebmp/inc/basebmp/scaleimage.hxx b/basebmp/inc/basebmp/scaleimage.hxx
index cb83e1353d5c..4f4847c88908 100644
--- a/basebmp/inc/basebmp/scaleimage.hxx
+++ b/basebmp/inc/basebmp/scaleimage.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -43,8 +43,8 @@ template< class SourceIter, class SourceAcc,
void scaleLine( SourceIter s_begin,
SourceIter s_end,
SourceAcc s_acc,
- DestIter d_begin,
- DestIter d_end,
+ DestIter d_begin,
+ DestIter d_end,
DestAcc d_acc )
{
const int src_width = s_end - s_begin;
@@ -57,7 +57,7 @@ void scaleLine( SourceIter s_begin,
// shrink
int rem = 0;
while( s_begin != s_end )
- {
+ {
if( rem >= 0 )
{
d_acc.set( s_acc(s_begin), d_begin );
@@ -67,7 +67,7 @@ void scaleLine( SourceIter s_begin,
}
rem += dest_width;
- ++s_begin;
+ ++s_begin;
}
}
else
@@ -80,10 +80,10 @@ void scaleLine( SourceIter s_begin,
{
rem -= dest_width;
++s_begin;
- }
+ }
d_acc.set( s_acc(s_begin), d_begin );
-
+
rem += src_width;
++d_begin;
}
@@ -122,8 +122,8 @@ template< class SourceIter, class SourceAcc,
void scaleImage( SourceIter s_begin,
SourceIter s_end,
SourceAcc s_acc,
- DestIter d_begin,
- DestIter d_end,
+ DestIter d_begin,
+ DestIter d_end,
DestAcc d_acc,
bool bMustCopy=false )
{
@@ -133,8 +133,8 @@ void scaleImage( SourceIter s_begin,
const int dest_width ( d_end.x - d_begin.x );
const int dest_height( d_end.y - d_begin.y );
- if( !bMustCopy &&
- src_width == dest_width &&
+ if( !bMustCopy &&
+ src_width == dest_width &&
src_height == dest_height )
{
// no scaling involved, can simply copy
@@ -146,7 +146,7 @@ void scaleImage( SourceIter s_begin,
typedef vigra::BasicImage<typename SourceAcc::value_type> TmpImage;
typedef typename TmpImage::traverser TmpImageIter;
- TmpImage tmp_image(src_width,
+ TmpImage tmp_image(src_width,
dest_height);
TmpImageIter t_begin = tmp_image.upperLeft();
@@ -156,7 +156,7 @@ void scaleImage( SourceIter s_begin,
typename SourceIter::column_iterator s_cbegin = s_begin.columnIterator();
typename TmpImageIter::column_iterator t_cbegin = t_begin.columnIterator();
- scaleLine(s_cbegin, s_cbegin+src_height, s_acc,
+ scaleLine(s_cbegin, s_cbegin+src_height, s_acc,
t_cbegin, t_cbegin+dest_height, tmp_image.accessor());
}
@@ -168,7 +168,7 @@ void scaleImage( SourceIter s_begin,
typename DestIter::row_iterator d_rbegin = d_begin.rowIterator();
typename TmpImageIter::row_iterator t_rbegin = t_begin.rowIterator();
- scaleLine(t_rbegin, t_rbegin+src_width, tmp_image.accessor(),
+ scaleLine(t_rbegin, t_rbegin+src_width, tmp_image.accessor(),
d_rbegin, d_rbegin+dest_width, d_acc);
}
}
diff --git a/basebmp/inc/basebmp/scanlineformats.hxx b/basebmp/inc/basebmp/scanlineformats.hxx
index d83aea688a37..8d7cafb962cb 100644
--- a/basebmp/inc/basebmp/scanlineformats.hxx
+++ b/basebmp/inc/basebmp/scanlineformats.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/basebmp/inc/basebmp/stridedarrayiterator.hxx b/basebmp/inc/basebmp/stridedarrayiterator.hxx
index 8139cc8a8bc9..6b6157c9b681 100644
--- a/basebmp/inc/basebmp/stridedarrayiterator.hxx
+++ b/basebmp/inc/basebmp/stridedarrayiterator.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/basebmp/inc/basebmp/tools.hxx b/basebmp/inc/basebmp/tools.hxx
index d7ca0423ac1f..78ab3dfab023 100644
--- a/basebmp/inc/basebmp/tools.hxx
+++ b/basebmp/inc/basebmp/tools.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -43,7 +43,7 @@ namespace basebmp
template< class Iterator, class Accessor >
inline vigra::triple<Iterator,Iterator,Accessor>
- destIterRange(Iterator const& begin,
+ destIterRange(Iterator const& begin,
Accessor const& accessor,
const basegfx::B2IRange& rRange)
{
@@ -55,7 +55,7 @@ namespace basebmp
template< class Iterator, class Accessor >
inline vigra::triple<Iterator,Iterator,Accessor>
- srcIterRange(Iterator const& begin,
+ srcIterRange(Iterator const& begin,
Accessor const& accessor,
const basegfx::B2IRange& rRange)
{
@@ -67,7 +67,7 @@ namespace basebmp
template< class Iterator, class Accessor >
inline vigra::pair<Iterator,Accessor>
- srcIter(Iterator const& begin,
+ srcIter(Iterator const& begin,
Accessor const& accessor,
const basegfx::B2IPoint& rPt)
{
@@ -78,7 +78,7 @@ namespace basebmp
template< class Iterator, class Accessor >
inline vigra::pair<Iterator,Accessor>
- destIter(Iterator const& begin,
+ destIter(Iterator const& begin,
Accessor const& accessor,
const basegfx::B2IPoint& rPt)
{
diff --git a/basebmp/inc/basebmp/truecolormaskaccessor.hxx b/basebmp/inc/basebmp/truecolormaskaccessor.hxx
index d4e3ff33f30e..4f7b59a6b05b 100644
--- a/basebmp/inc/basebmp/truecolormaskaccessor.hxx
+++ b/basebmp/inc/basebmp/truecolormaskaccessor.hxx
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -39,15 +39,15 @@
namespace basebmp
{
-namespace
+namespace
{
- /// Shift left for positive shift value, and right otherwise
+ /// Shift left for positive shift value, and right otherwise
template< typename T > inline T shiftLeft( T v, int shift )
{
return shift > 0 ? v << shift : v >> (-shift);
}
- /// Shift right for positive shift value, and left otherwise
+ /// Shift right for positive shift value, and left otherwise
template< typename T > inline T shiftRight( T v, int shift )
{
return shift > 0 ? v >> shift : v << (-shift);
@@ -75,7 +75,7 @@ namespace
When true, the final pixel values will be byte-swapped before
passed to/from the iterator.
*/
-template< class Accessor,
+template< class Accessor,
typename ColorType,
int RedMask,
int GreenMask,
@@ -94,11 +94,11 @@ private:
template<class A, typename C, int R, int G, int B, bool S> friend class TrueColorMaskAccessor;
#endif
- Accessor maAccessor;
+ Accessor maAccessor;
public:
// calc corrective shifts for all three channels in advance
- enum {
+ enum {
red_shift = numberOfTrailingZeros<RedMask>::value,
green_shift = numberOfTrailingZeros<GreenMask>::value,
blue_shift = numberOfTrailingZeros<BlueMask>::value,
@@ -114,13 +114,13 @@ public:
maAccessor()
{}
- template< class A > explicit
+ template< class A > explicit
TrueColorMaskAccessor( TrueColorMaskAccessor< A,
ColorType,
RedMask,
GreenMask,
BlueMask,
- SwapBytes > const& rSrc ) :
+ SwapBytes > const& rSrc ) :
maAccessor( rSrc.maAccessor )
{}
@@ -143,16 +143,16 @@ public:
const unsigned_data_type green(v & GreenMask);
const unsigned_data_type blue (v & BlueMask);
- value_type res( (shiftRight(red,
+ value_type res( (shiftRight(red,
red_shift-8*sizeof(component_type)+red_bits)) |
(shiftRight(red,
red_shift-8*sizeof(component_type)+2*red_bits)),
-
+
(shiftRight(green,
green_shift-8*sizeof(component_type)+green_bits)) |
(shiftRight(green,
green_shift-8*sizeof(component_type)+2*green_bits)),
-
+
(shiftRight(blue,
blue_shift-8*sizeof(component_type)+blue_bits)) |
(shiftRight(blue,
@@ -166,7 +166,7 @@ public:
const unsigned_data_type green(v.getGreen());
const unsigned_data_type blue (v.getBlue());
- unsigned_data_type res(
+ unsigned_data_type res(
(shiftLeft(red,
red_shift-8*sizeof(component_type)+red_bits) & RedMask) |
(shiftLeft(green,
@@ -180,10 +180,10 @@ public:
// -------------------------------------------------------
template< class Iterator >
- value_type operator()(Iterator const& i) const
- {
- return toValue(
- unsigned_cast<data_type>( maAccessor(i)) );
+ value_type operator()(Iterator const& i) const
+ {
+ return toValue(
+ unsigned_cast<data_type>( maAccessor(i)) );
}
template< class Iterator, class Difference >
@@ -197,7 +197,7 @@ public:
template< typename V, class Iterator >
void set(V const& value, Iterator const& i) const
- {
+ {
maAccessor.set(
toPacked(
vigra::detail::RequiresExplicitCast<value_type>::cast(
@@ -208,10 +208,10 @@ public:
template< typename V, class Iterator, class Difference >
void set(V const& value, Iterator const& i, Difference const& diff) const
{
- maAccessor.set(
+ maAccessor.set(
toPacked(
vigra::detail::RequiresExplicitCast<value_type>::cast(
- value)),
+ value)),
i,
diff );
}
@@ -220,7 +220,7 @@ public:
//-----------------------------------------------------------------------------
/** Convert Color to packed true color value for TrueColorMaskAccessor
- */
+ */
template< class Accessor > struct ColorConvert
{
typename Accessor::data_type operator()( const Accessor& acc,
@@ -233,13 +233,13 @@ template< class Accessor > struct ColorConvert
//-----------------------------------------------------------------------------
// partial specialization for TrueColorMaskAccessor
-template< class Accessor,
+template< class Accessor,
typename ColorType,
int RedMask,
int GreenMask,
int BlueMask,
- bool SwapBytes > struct AccessorTraits<
- TrueColorMaskAccessor< Accessor,
+ bool SwapBytes > struct AccessorTraits<
+ TrueColorMaskAccessor< Accessor,
ColorType,
RedMask,
GreenMask,
@@ -247,7 +247,7 @@ template< class Accessor,
SwapBytes > >
{
/// value type of described accessor
- typedef typename TrueColorMaskAccessor< Accessor,
+ typedef typename TrueColorMaskAccessor< Accessor,
ColorType,
RedMask,
GreenMask,
@@ -255,7 +255,7 @@ template< class Accessor,
SwapBytes >::value_type value_type;
/// Retrieve stand-alone color lookup function for given Accessor type
- typedef ColorConvert< TrueColorMaskAccessor< Accessor,
+ typedef ColorConvert< TrueColorMaskAccessor< Accessor,
ColorType,
RedMask,
GreenMask,
@@ -277,7 +277,7 @@ template< class Accessor,
* want to wrap a masked_accessor with a TrueColorMaskAccessor,
* not the other way around.
*/
- template< class MaskAccessor,
+ template< class MaskAccessor,
class Iterator,
class MaskIterator > struct masked_accessor
{