LibreOffice Module vcl (master) 1
|
#include <bitmap.hxx>
Public Types | |
typedef vcl::ScopedBitmapAccess< BitmapReadAccess, Bitmap, &Bitmap::AcquireReadAccess > | ScopedReadAccess |
typedef vcl::ScopedBitmapAccess< BitmapInfoAccess, Bitmap, &Bitmap::AcquireInfoAccess > | ScopedInfoAccess |
Public Member Functions | |
Bitmap () | |
Bitmap (const Bitmap &rBitmap) | |
Bitmap (const Size &rSizePixel, vcl::PixelFormat ePixelFormat, const BitmapPalette *pPal=nullptr) | |
Bitmap (std::shared_ptr< SalBitmap > xSalBitmap) | |
virtual | ~Bitmap () |
Bitmap & | operator= (const Bitmap &rBitmap) |
Bitmap & | operator= (Bitmap &&rBitmap) noexcept |
bool | operator== (const Bitmap &rBitmap) const |
bool | operator!= (const Bitmap &rBitmap) const |
bool | IsEmpty () const |
void | SetEmpty () |
const MapMode & | GetPrefMapMode () const |
void | SetPrefMapMode (const MapMode &rMapMode) |
const Size & | GetPrefSize () const |
void | SetPrefSize (const Size &rSize) |
Size | GetSizePixel () const |
vcl::PixelFormat | getPixelFormat () const |
sal_Int64 | GetSizeBytes () const |
bool | HasGreyPalette8Bit () const |
bool | HasGreyPaletteAny () const |
bool | GetSystemData (BitmapSystemData &rData) const |
get system dependent bitmap data More... | |
BitmapChecksum | GetChecksum () const |
Bitmap | CreateDisplayBitmap (OutputDevice *pDisplay) const |
bool | Convert (BmpConversion eConversion) |
Convert bitmap format. More... | |
bool | Dither () |
Apply a Floyd dither algorithm to the bitmap. More... | |
bool | Crop (const tools::Rectangle &rRectPixel) |
Crop the bitmap. More... | |
bool | Expand (sal_Int32 nDX, sal_Int32 nDY, const Color *pInitColor=nullptr) |
Expand the bitmap by pixel padding. More... | |
bool | CopyPixel (const tools::Rectangle &rRectDst, const tools::Rectangle &rRectSrc, const Bitmap *pBmpSrc=nullptr) |
Copy a rectangular area from another bitmap. More... | |
bool | CopyPixel_AlphaOptimized (const tools::Rectangle &rRectDst, const tools::Rectangle &rRectSrc, const Bitmap *pBmpSrc) |
bool | CombineOr (const Bitmap &rMask) |
Perform boolean OR operation with another bitmap. More... | |
bool | Blend (const AlphaMask &rAlpha, const Color &rBackgroundColor) |
Alpha-blend the given bitmap against a specified uniform background color. More... | |
bool | Erase (const Color &rFillColor) |
Fill the entire bitmap with the given color. More... | |
bool | Invert () |
Perform the Invert operation on every pixel. More... | |
bool | Mirror (BmpMirrorFlags nMirrorFlags) |
Mirror the bitmap. More... | |
bool | Scale (const Size &rNewSize, BmpScaleFlag nScaleFlag=BmpScaleFlag::Default) |
Scale the bitmap. More... | |
bool | Scale (const double &rScaleX, const double &rScaleY, BmpScaleFlag nScaleFlag=BmpScaleFlag::Default) |
Scale the bitmap. More... | |
void | AdaptBitCount (Bitmap &rNew) const |
bool | Rotate (Degree10 nAngle10, const Color &rFillColor) |
Rotate bitmap by the specified angle. More... | |
Bitmap | CreateMask (const Color &rTransColor) const |
Create on-off mask from bitmap. More... | |
Bitmap | CreateMask (const Color &rTransColor, sal_uInt8 nTol) const |
Create on-off mask from bitmap. More... | |
AlphaMask | CreateAlphaMask (const Color &rTransColor) const |
Create on-off alpha mask from bitmap. More... | |
AlphaMask | CreateAlphaMask (const Color &rTransColor, sal_uInt8 nTol) const |
Create on-off alpha mask from bitmap. More... | |
vcl::Region | CreateRegion (const Color &rColor, const tools::Rectangle &rRect) const |
Create region of similar colors in a given rectangle. More... | |
bool | Replace (const AlphaMask &rAlpha, const Color &rMergeColor) |
Merge bitmap with given background color according to specified alpha mask. More... | |
bool | Replace (const Color &rSearchColor, const Color &rReplaceColor, sal_uInt8 nTol=0) |
Replace all pixel having the search color with the specified color. More... | |
bool | Replace (const Color *pSearchColors, const Color *rReplaceColors, size_t nColorCount, sal_uInt8 const *pTols) |
Replace all pixel having one the search colors with the corresponding replace color. More... | |
void | Vectorize (GDIMetaFile &rMtf, sal_uInt8 cReduce, const Link< tools::Long, void > *pProgress) |
Convert the bitmap to a meta file. More... | |
bool | Adjust (short nLuminancePercent, short nContrastPercent=0, short nChannelRPercent=0, short nChannelGPercent=0, short nChannelBPercent=0, double fGamma=1.0, bool bInvert=false, bool msoBrightness=false) |
Change various global color characteristics. More... | |
void | RemoveBlendedStartColor (const Color &rColor, const AlphaMask &rAlphaMask) |
Remove existing blending against COL_WHITE based on given AlphaMask. More... | |
const basegfx::SystemDependentDataHolder * | accessSystemDependentDataHolder () const |
SAL_DLLPRIVATE void | ReassignWithSize (const Bitmap &rBitmap) |
ReassignWithSize and recalculate bitmap. More... | |
SAL_DLLPRIVATE void | ImplMakeUnique () |
const std::shared_ptr< SalBitmap > & | ImplGetSalBitmap () const |
SAL_DLLPRIVATE void | ImplSetSalBitmap (const std::shared_ptr< SalBitmap > &xImpBmp) |
SAL_DLLPRIVATE bool | ImplMakeGreyscales () |
BitmapInfoAccess * | AcquireInfoAccess () |
BitmapReadAccess * | AcquireReadAccess () |
BitmapWriteAccess * | AcquireWriteAccess () |
Static Public Member Functions | |
static const BitmapPalette & | GetGreyPalette (int nEntries) |
static bool | HasFastScale () |
Returns true if bitmap scaling is considered to be fast. More... | |
static void | ReleaseAccess (BitmapInfoAccess *pAccess) |
Private Member Functions | |
SAL_DLLPRIVATE bool | ImplConvertUp (vcl::PixelFormat ePixelFormat, Color const *pExtColor=nullptr) |
SAL_DLLPRIVATE bool | ImplConvertDown8BPP (Color const *pExtColor=nullptr) |
Private Attributes | |
std::shared_ptr< SalBitmap > | mxSalBmp |
MapMode | maPrefMapMode |
Size | maPrefSize |
Definition at line 105 of file include/vcl/bitmap.hxx.
typedef vcl::ScopedBitmapAccess<BitmapInfoAccess, Bitmap, &Bitmap::AcquireInfoAccess> Bitmap::ScopedInfoAccess |
Definition at line 583 of file include/vcl/bitmap.hxx.
typedef vcl::ScopedBitmapAccess<BitmapReadAccess, Bitmap, &Bitmap::AcquireReadAccess> Bitmap::ScopedReadAccess |
Definition at line 582 of file include/vcl/bitmap.hxx.
Bitmap::Bitmap | ( | ) |
Definition at line 60 of file bitmap/bitmap.cxx.
Referenced by CreateMask().
Bitmap::Bitmap | ( | const Bitmap & | rBitmap | ) |
Definition at line 64 of file bitmap/bitmap.cxx.
Bitmap::Bitmap | ( | const Size & | rSizePixel, |
vcl::PixelFormat | ePixelFormat, | ||
const BitmapPalette * | pPal = nullptr |
||
) |
Definition at line 78 of file bitmap/bitmap.cxx.
References COL_BLACK(), COL_BLUE(), COL_BROWN(), COL_CYAN(), COL_GRAY(), COL_GREEN(), COL_LIGHTBLUE(), COL_LIGHTCYAN(), COL_LIGHTGRAY(), COL_LIGHTGREEN(), COL_LIGHTMAGENTA(), COL_LIGHTRED(), COL_MAGENTA(), COL_RED(), COL_WHITE(), COL_YELLOW(), SalInstance::CreateSalBitmap(), Size::Height(), ImplGetSVData(), vcl::isPalettePixelFormat(), ImplSVData::mpDefInst, mxSalBmp, vcl::N8_BPP, and Size::Width().
|
explicit |
Definition at line 71 of file bitmap/bitmap.cxx.
References MapPixel.
|
virtual |
Definition at line 149 of file bitmap/bitmap.cxx.
const basegfx::SystemDependentDataHolder * Bitmap::accessSystemDependentDataHolder | ( | ) | const |
Definition at line 1706 of file bitmap/bitmap.cxx.
References mxSalBmp.
BitmapInfoAccess * Bitmap::AcquireInfoAccess | ( | ) |
Definition at line 363 of file bitmap/bitmap.cxx.
BitmapReadAccess * Bitmap::AcquireReadAccess | ( | ) |
Definition at line 375 of file bitmap/bitmap.cxx.
Referenced by AlphaMask::AcquireAlphaReadAccess(), vcl::bitmap::CanvasCairoExtractBitmapData(), vcl::bitmap::CanvasExtractBitmapData(), vcl::bitmap::CanvasTransformBitmap(), BitmapMosaicFilter::execute(), and BitmapEx::GetContour().
BitmapWriteAccess * Bitmap::AcquireWriteAccess | ( | ) |
Definition at line 387 of file bitmap/bitmap.cxx.
Referenced by AlphaMask::AcquireAlphaWriteAccess(), vcl::unotools::bitmapExFromXBitmap(), and BitmapMosaicFilter::execute().
void Bitmap::AdaptBitCount | ( | Bitmap & | rNew | ) | const |
Definition at line 1358 of file bitmap/bitmap.cxx.
References Convert(), getPixelFormat(), HasGreyPaletteAny(), vcl::INVALID, vcl::N24_BPP, N24Bit, vcl::N32_BPP, N32Bit, vcl::N8_BPP, N8BitColors, N8BitGreys, and SAL_WARN.
Referenced by BitmapScaleSuperFilter::execute(), and BitmapInterpolateScaleFilter::execute().
bool Bitmap::Adjust | ( | short | nLuminancePercent, |
short | nContrastPercent = 0 , |
||
short | nChannelRPercent = 0 , |
||
short | nChannelGPercent = 0 , |
||
short | nChannelBPercent = 0 , |
||
double | fGamma = 1.0 , |
||
bool | bInvert = false , |
||
bool | msoBrightness = false |
||
) |
Change various global color characteristics.
nLuminancePercent | Percent of luminance change, valid range [-100,100]. Values outside this range are clipped to the valid range. |
nContrastPercent | Percent of contrast change, valid range [-100,100]. Values outside this range are clipped to the valid range. |
nChannelRPercent | Percent of red channel change, valid range [-100,100]. Values outside this range are clipped to the valid range. |
nChannelGPercent | Percent of green channel change, valid range [-100,100]. Values outside this range are clipped to the valid range. |
nChannelBPercent | Percent of blue channel change, valid range [-100,100]. Values outside this range are clipped to the valid range. |
fGamma | Exponent of the gamma function applied to the bitmap. The value 1.0 results in no change, the valid range is (0.0,10.0]. Values outside this range are regarded as 1.0. |
bInvert | If true, invert the channel values with the logical 'not' operator |
msoBrightness | Use the same formula for brightness as used by MSOffice. |
Definition at line 1496 of file bitmap/bitmap.cxx.
References FRound(), GAMMA, Color::GetBlue(), Color::GetGreen(), Color::GetRed(), i, MinMax(), N24BitTcBgr, N24BitTcRgb, nCount, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), Color::SetBlue(), Color::SetGreen(), and Color::SetRed().
Referenced by BitmapEx::Adjust(), and Image::Draw().
Alpha-blend the given bitmap against a specified uniform background color.
rAlpha | Alpha mask to blend with |
rBackgroundColor | Background color to use for every pixel during alpha blending |
Definition at line 1128 of file bitmappaint.cxx.
References Convert(), getPixelFormat(), vcl::isPalettePixelFormat(), Color::Merge(), and N24Bit.
Referenced by Printer::DrawDeviceBitmapEx().
bool Bitmap::CombineOr | ( | const Bitmap & | rMask | ) |
Perform boolean OR operation with another bitmap.
rMask | The mask bitmap in the selected combine operation |
Definition at line 1090 of file bitmappaint.cxx.
References COL_BLACK(), COL_WHITE(), BitmapInfoAccess::GetBestMatchingColor(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), BitmapInfoAccess::Height(), and BitmapInfoAccess::Width().
Referenced by BitmapEx::CombineMaskOr().
bool Bitmap::Convert | ( | BmpConversion | eConversion | ) |
Convert bitmap format.
eConversion | The format this bitmap should be converted to. |
Definition at line 857 of file bitmap/bitmap.cxx.
References BMP_COL_TRANS, BitmapFilter::Filter(), BitmapEx::GetBitmap(), getPixelFormat(), HasGreyPalette8Bit(), ImplConvertDown8BPP(), ImplConvertUp(), ImplGetSVData(), ImplMakeGreyscales(), ImplSetSalBitmap(), mxSalBmp, N1BitThreshold, vcl::N24_BPP, N24Bit, vcl::N32_BPP, N32Bit, vcl::N8_BPP, N8BitColors, N8BitGreys, N8BitNoConversion, N8BitTrans, nBitCount, vcl::pixelFormatBitCount(), and SAL_INFO.
Referenced by AdaptBitCount(), AlphaMask::AlphaMask(), Blend(), BitmapEx::Convert(), CopyPixel(), DetectEdges(), OutputDevice::DrawBitmap(), Printer::DrawDeviceMask(), BitmapPopArtFilter::execute(), OutputDevice::GetBitmapEx(), AlphaMask::operator=(), AlphaMask::ReleaseAccess(), JPEGWriter::Write(), and vcl::PDFWriterImpl::writeBitmapObject().
bool Bitmap::CopyPixel | ( | const tools::Rectangle & | rRectDst, |
const tools::Rectangle & | rRectSrc, | ||
const Bitmap * | pBmpSrc = nullptr |
||
) |
Copy a rectangular area from another bitmap.
rRectDst | Destination rectangle in this bitmap. This is clipped to the bitmap dimensions. |
rRectSrc | Source rectangle in pBmpSrc. This is clipped to the source bitmap dimensions. Note further that no scaling takes place during this copy operation, i.e. only the minimum of source and destination rectangle's width and height are used. |
pBmpSrc | The source bitmap to copy from. If this argument is NULL, or equal to the object this method is called on, copying takes place within the same bitmap. |
Definition at line 445 of file bitmap/bitmap.cxx.
References Convert(), tools::Rectangle::GetHeight(), BitmapReadAccess::GetIndexFromData(), BitmapInfoAccess::GetPaletteColor(), BitmapInfoAccess::GetPaletteEntryCount(), getPixelFormat(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), GetSizePixel(), tools::Rectangle::GetWidth(), BitmapInfoAccess::HasPalette(), i, tools::Rectangle::Intersection(), tools::Rectangle::IsEmpty(), tools::Rectangle::Left(), mxSalBmp, N24Bit, N8BitColors, nCount, vcl::pixelFormatBitCount(), vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and tools::Rectangle::Top().
Referenced by BitmapEx::CopyPixel().
bool Bitmap::CopyPixel_AlphaOptimized | ( | const tools::Rectangle & | rRectDst, |
const tools::Rectangle & | rRectSrc, | ||
const Bitmap * | pBmpSrc | ||
) |
Definition at line 649 of file bitmap/bitmap.cxx.
References tools::Rectangle::GetHeight(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), GetSizePixel(), tools::Rectangle::GetWidth(), tools::Rectangle::Intersection(), tools::Rectangle::IsEmpty(), tools::Rectangle::Left(), mxSalBmp, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and tools::Rectangle::Top().
Referenced by BitmapEx::CopyPixel().
Create on-off alpha mask from bitmap.
This method creates a bitmask from the bitmap, where every pixel that equals rTransColor is set transparent, the rest opaque.
rTransColor | Color value where the bitmask should be transparent |
Definition at line 626 of file bitmappaint.cxx.
References COL_ALPHA_OPAQUE(), COL_ALPHA_TRANSPARENT(), BitmapInfoAccess::GetBestMatchingColor(), BitmapColor::GetIndex(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), BitmapInfoAccess::GetScanlineFormat(), GetSizePixel(), BitmapInfoAccess::Height(), maPrefMapMode, maPrefSize, N1BitMsbPal, N8BitPal, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and BitmapInfoAccess::Width().
Referenced by BitmapEx::BitmapEx(), unographic::Graphic::colorChange(), and CreateAlphaMask().
Create on-off alpha mask from bitmap.
This method creates a bitmask from the bitmap, where every pixel that equals rTransColor is set transparent, the rest opaque.
rTransColor | Color value where the bitmask should be transparent |
nTol | Tolerance value. Specifies the maximal difference between rTransColor and the individual pixel values, such that the corresponding pixel is still regarded as transparent. |
Definition at line 701 of file bitmappaint.cxx.
References COL_ALPHA_OPAQUE(), COL_ALPHA_TRANSPARENT(), CreateAlphaMask(), Color::GetBlue(), Color::GetGreen(), BitmapReadAccess::GetIndexFromData(), BitmapInfoAccess::GetPaletteColor(), BitmapReadAccess::GetPixelFromData(), Color::GetRed(), BitmapReadAccess::GetScanline(), GetSizePixel(), BitmapInfoAccess::HasPalette(), BitmapInfoAccess::Height(), maPrefMapMode, maPrefSize, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and BitmapInfoAccess::Width().
Bitmap Bitmap::CreateDisplayBitmap | ( | OutputDevice * | pDisplay | ) | const |
Definition at line 835 of file bitmap/bitmap.cxx.
References OutputDevice::GetGraphics(), ImplGetSVData(), ImplSetSalBitmap(), and mxSalBmp.
Referenced by OutputDevice::DrawBitmapWallpaper().
Create on-off mask from bitmap.
This method creates a bitmask from the bitmap, where every pixel that equals rTransColor is set transparent, the rest opaque.
rTransColor | Color value where the bitmask should be transparent |
Definition at line 443 of file bitmappaint.cxx.
References Bitmap(), COL_BLACK(), COL_WHITE(), BitmapInfoAccess::GetBestMatchingColor(), GetGreyPalette(), BitmapColor::GetIndex(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), BitmapInfoAccess::GetScanlineFormat(), BitmapInfoAccess::GetScanlineSize(), GetSizePixel(), BitmapInfoAccess::Height(), maPrefMapMode, maPrefSize, N1BitMsbPal, vcl::N8_BPP, N8BitPal, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and BitmapInfoAccess::Width().
Referenced by BitmapEx::CombineMaskOr(), CreateMask(), and OutputDevice::DrawDeviceMask().
Create on-off mask from bitmap.
This method creates a bitmask from the bitmap, where every pixel that equals rTransColor is set transparent, the rest opaque.
rTransColor | Color value where the bitmask should be transparent |
nTol | Tolerance value. Specifies the maximal difference between rTransColor and the individual pixel values, such that the corresponding pixel is still regarded as transparent. |
Definition at line 532 of file bitmappaint.cxx.
References Bitmap(), COL_BLACK(), COL_WHITE(), CreateMask(), Color::GetBlue(), Color::GetGreen(), GetGreyPalette(), BitmapReadAccess::GetIndexFromData(), BitmapInfoAccess::GetPaletteColor(), BitmapReadAccess::GetPixelFromData(), Color::GetRed(), BitmapReadAccess::GetScanline(), GetSizePixel(), BitmapInfoAccess::HasPalette(), BitmapInfoAccess::Height(), maPrefMapMode, maPrefSize, vcl::N8_BPP, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and BitmapInfoAccess::Width().
vcl::Region Bitmap::CreateRegion | ( | const Color & | rColor, |
const tools::Rectangle & | rRect | ||
) | const |
Create region of similar colors in a given rectangle.
rColor | All pixel which have this color are included in the calculated region |
rRect | The rectangle within which matching pixel are looked for. This rectangle is always clipped to the bitmap dimensions. |
Definition at line 794 of file bitmappaint.cxx.
References a, tools::Rectangle::Bottom(), BitmapInfoAccess::GetBestMatchingColor(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), GetSizePixel(), tools::Rectangle::Intersection(), tools::Rectangle::Left(), tools::Rectangle::Normalize(), vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), tools::Rectangle::Right(), tools::Rectangle::SetBottom(), tools::Rectangle::SetLeft(), tools::Rectangle::SetRight(), tools::Rectangle::SetTop(), tools::Rectangle::Top(), and vcl::Region::Union().
Referenced by Printer::DrawDeviceMask(), and ImplWheelWindow::ImplSetRegion().
bool Bitmap::Crop | ( | const tools::Rectangle & | rRectPixel | ) |
Crop the bitmap.
rRectPixel | A rectangle specifying the crop amounts on all four sides of the bitmap. If the upper left corner of the bitmap is assigned (0,0), then this method cuts out the given rectangle from the bitmap. Note that the rectangle is clipped to the bitmap's dimension, i.e. negative left,top rectangle coordinates or exceeding width or height is ignored. |
Definition at line 404 of file bitmap/bitmap.cxx.
References tools::Rectangle::GetHeight(), BitmapInfoAccess::GetPalette(), getPixelFormat(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), tools::Rectangle::GetSize(), GetSizePixel(), tools::Rectangle::GetWidth(), tools::Rectangle::Intersection(), tools::Rectangle::IsEmpty(), tools::Rectangle::Left(), ReassignWithSize(), vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and tools::Rectangle::Top().
Referenced by clipMetafileContentAgainstOwnRegions(), BitmapEx::Crop(), Printer::DrawDeviceMask(), BitmapScaleSuperFilter::execute(), vcl::bitmap::GetDownsampledBitmap(), Printer::ImplPrintTransparent(), EMFWriter::ImplWrite(), and WMFWriter::WriteRecords().
bool Bitmap::Dither | ( | ) |
Apply a Floyd dither algorithm to the bitmap.
This method dithers the bitmap inplace, i.e. a true color bitmap is converted to a paletted bitmap, reducing the color deviation by error diffusion.
Definition at line 1412 of file bitmap/bitmap.cxx.
References aMap, CALC_ERRORS, CALC_TABLES3, CALC_TABLES5, CALC_TABLES7, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::get(), getColor(), GetSizePixel(), Size::Height(), BitmapInfoAccess::Height(), maPrefMapMode, maPrefSize, vcl::N8_BPP, nVCLBLut, nVCLGLut, nVCLRLut, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), shiftColor(), Size::Width(), and BitmapInfoAccess::Width().
bool Bitmap::Erase | ( | const Color & | rFillColor | ) |
Fill the entire bitmap with the given color.
rFillColor | Color value to use for filling |
Definition at line 34 of file bitmappaint.cxx.
References ImplGetSVData(), ImplSetSalBitmap(), IsEmpty(), maPrefMapMode, maPrefSize, and mxSalBmp.
Referenced by AlphaMask::AlphaMask(), createBlendFrame(), OutputDevice::DrawTransformBitmapExDirect(), OutputDevice::DrawWaveLine(), BitmapEx::Erase(), AlphaMask::Erase(), vcl::drawmode::GetBitmapEx(), GDIMetaFile::ImplBmpMonoFnc(), and BitmapEx::ModifyBitmapEx().
bool Bitmap::Expand | ( | sal_Int32 | nDX, |
sal_Int32 | nDY, | ||
const Color * | pInitColor = nullptr |
||
) |
Expand the bitmap by pixel padding.
nDX | Number of pixel to pad at the right border of the bitmap |
nDY | Number of scanlines to pad at the bottom border of the bitmap |
pInitColor | Color to use for padded pixel |
Definition at line 777 of file bitmap/bitmap.cxx.
References BitmapInfoAccess::GetPalette(), getPixelFormat(), GetSizePixel(), Size::Height(), ReassignWithSize(), vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and Size::Width().
Referenced by BitmapEx::Expand().
BitmapChecksum Bitmap::GetChecksum | ( | ) | const |
Definition at line 301 of file bitmap/bitmap.cxx.
References getPixelFormat(), ImplGetSVData(), and mxSalBmp.
Referenced by vcl::PDFWriterImpl::createBitmapEmit(), vcl::PDFWriterImpl::drawJPGBitmap(), BitmapEx::GetChecksum(), and SvmWriter::GetChecksum().
|
static |
Definition at line 178 of file bitmap/bitmap.cxx.
References GetGreyPalette().
Referenced by vcl::unotools::bitmapExFromXBitmap(), CreateMask(), BitmapMonochromeFilter::execute(), BitmapDisabledImageFilter::execute(), BitmapMaskToAlphaFilter::execute(), vcl::drawmode::GetBitmapEx(), GetGreyPalette(), ImplMakeGreyscales(), BitmapPalette::IsGreyPaletteAny(), and BitmapEx::Rotate().
vcl::PixelFormat Bitmap::getPixelFormat | ( | ) | const |
Definition at line 258 of file bitmap/bitmap.cxx.
References vcl::INVALID, mxSalBmp, vcl::N24_BPP, vcl::N32_BPP, vcl::N8_BPP, and nBitCount.
Referenced by AdaptBitCount(), AlphaMask::AlphaMask(), BitmapEx::BitmapEx(), BitmapInfoAccess::BitmapInfoAccess(), Blend(), AlphaMask::BlendWith(), vcl::bitmap::CanvasTransformBitmap(), Convert(), vcl::bitmap::convertBitmap32To24Plus8(), CopyPixel(), vcl::PDFWriterImpl::createBitmapEmit(), Crop(), Printer::DrawDeviceMask(), OutputDevice::EmulateDrawTransparent(), BitmapScaleSuperFilter::execute(), BitmapColorQuantizationFilter::execute(), BitmapMosaicFilter::execute(), BitmapPopArtFilter::execute(), BitmapSimpleColorQuantizationFilter::execute(), BitmapFastScaleFilter::execute(), Expand(), BitmapEx::GetAlpha(), OutputDevice::GetBitmapEx(), GetChecksum(), BitmapEx::GetPixelColor(), GetSizeBytes(), ImplConvertDown8BPP(), ImplConvertUp(), BitmapEx::ModifyBitmapEx(), AlphaMask::operator=(), vcl::pngWrite(), AlphaMask::ReleaseAccess(), Rotate(), Scale(), vcl::PDFWriterImpl::writeBitmapObject(), and MetafileXmlDump::writeXml().
|
inline |
Definition at line 600 of file include/vcl/bitmap.hxx.
References maPrefMapMode.
Referenced by clipMetafileContentAgainstOwnRegions(), DetectEdges(), BitmapColorQuantizationFilter::execute(), BitmapConvolutionMatrixFilter::execute(), BitmapEmbossGreyFilter::execute(), BitmapMedianFilter::execute(), BitmapMonochromeFilter::execute(), BitmapMosaicFilter::execute(), BitmapSepiaFilter::execute(), BitmapSimpleColorQuantizationFilter::execute(), and BitmapSobelGreyFilter::execute().
|
inline |
Definition at line 610 of file include/vcl/bitmap.hxx.
References maPrefSize.
Referenced by clipMetafileContentAgainstOwnRegions(), DetectEdges(), BitmapColorQuantizationFilter::execute(), BitmapConvolutionMatrixFilter::execute(), BitmapEmbossGreyFilter::execute(), BitmapMedianFilter::execute(), BitmapMonochromeFilter::execute(), BitmapMosaicFilter::execute(), BitmapSepiaFilter::execute(), BitmapSimpleColorQuantizationFilter::execute(), BitmapSobelGreyFilter::execute(), and BitmapEx::GetContour().
|
inline |
Definition at line 620 of file include/vcl/bitmap.hxx.
References getPixelFormat(), GetSizePixel(), and vcl::pixelFormatBitCount().
Referenced by BitmapEx::GetSizeBytes().
Size Bitmap::GetSizePixel | ( | ) | const |
Definition at line 253 of file bitmap/bitmap.cxx.
References mxSalBmp.
Referenced by BitmapEx::BitmapEx(), OutputDevice::BlendBitmap(), OutputDevice::BlendBitmapWithAlpha(), vcl::bitmap::CanvasExtractBitmapData(), vcl::bitmap::convertBitmap32To24Plus8(), BitmapGaussianSeparableBlurFilter::convolutionPass(), CopyPixel(), CopyPixel_AlphaOptimized(), CreateAlphaMask(), CreateMask(), CreateRegion(), Crop(), BitmapEx::Crop(), DetectEdges(), Dither(), OutputDevice::DrawBitmap(), OutputDevice::DrawDeviceAlphaBitmap(), OutputDevice::DrawDeviceAlphaBitmapSlowPath(), Printer::DrawDeviceMask(), vcl::PDFWriterImpl::drawJPGBitmap(), OutputDevice::DrawMask(), OutputDevice::DrawTransformedBitmapEx(), BitmapWriteAccess::Erase(), BitmapScaleSuperFilter::execute(), BitmapColorQuantizationFilter::execute(), BitmapConvolutionMatrixFilter::execute(), BitmapDuoToneFilter::execute(), BitmapEmbossGreyFilter::execute(), BitmapGaussianSeparableBlurFilter::execute(), BitmapMedianFilter::execute(), BitmapMonochromeFilter::execute(), BitmapMosaicFilter::execute(), BitmapSeparableUnsharpenFilter::execute(), BitmapSepiaFilter::execute(), BitmapSimpleColorQuantizationFilter::execute(), BitmapSobelGreyFilter::execute(), BitmapFastScaleFilter::execute(), BitmapInterpolateScaleFilter::execute(), MetaBmpScaleAction::Execute(), BitmapEx::Expand(), Expand(), BitmapWriteAccess::FillRect(), GDIMetaFile::GetBoundRect(), BitmapEx::GetContour(), vcl::bitmap::GetDownsampledBitmap(), vcl::unotools::VclCanvasBitmap::getSize(), GetSizeBytes(), ImplConvertDown8BPP(), ImplConvertUp(), ImplMakeGreyscales(), Printer::ImplPrintTransparent(), ImplWheelWindow::ImplSetRegion(), EMFWriter::ImplWrite(), EMFWriter::ImplWriteBmpRecord(), vcl::bitmap::isHistorical8x8(), BitmapEx::ModifyBitmapEx(), ReassignWithSize(), OutputDevice::RemoveTransparenciesFromMetaFile(), Replace(), BitmapEx::ReplaceTransparency(), Rotate(), BitmapEx::Rotate(), Scale(), BitmapEx::Scale(), vcl::unotools::VclCanvasBitmap::VclCanvasBitmap(), WMFWriter::WMFRecord_StretchDIB(), vcl::PDFWriterImpl::writeBitmapObject(), vcl::PDFWriterImpl::writeGradientFunction(), and WMFWriter::WriteRecords().
bool Bitmap::GetSystemData | ( | BitmapSystemData & | rData | ) | const |
get system dependent bitmap data
rData | The system dependent BitmapSystemData structure to be filled |
Definition at line 851 of file bitmap/bitmap.cxx.
References mxSalBmp.
|
static |
Returns true if bitmap scaling is considered to be fast.
Currently this returns true if OpenGL is used for scaling, otherwise false (CPU scaling is slower).
Definition at line 1349 of file bitmap/bitmap.cxx.
References SkiaHelper::isVCLSkiaEnabled().
bool Bitmap::HasGreyPalette8Bit | ( | ) | const |
Definition at line 288 of file bitmap/bitmap.cxx.
References BitmapInfoAccess::GetPalette(), BitmapInfoAccess::HasPalette(), and BitmapPalette::IsGreyPalette8Bit().
Referenced by AlphaMask::AlphaMask(), BitmapEx::BitmapEx(), AlphaMask::BlendWith(), Convert(), AlphaMask::operator=(), vcl::pngWrite(), AlphaMask::ReleaseAccess(), and JPEGWriter::Write().
bool Bitmap::HasGreyPaletteAny | ( | ) | const |
Definition at line 274 of file bitmap/bitmap.cxx.
References BitmapInfoAccess::GetPalette(), BitmapInfoAccess::HasPalette(), and BitmapPalette::IsGreyPaletteAny().
Referenced by AdaptBitCount(), and vcl::PDFWriterImpl::writeBitmapObject().
|
private |
Definition at line 1139 of file bitmap/bitmap.cxx.
References aMap, COL_BLACK(), COL_WHITE(), InverseColorMap::GetBestPaletteIndex(), BitmapPalette::GetEntryCount(), BitmapReadAccess::GetIndexFromData(), Octree::GetPalette(), BitmapInfoAccess::GetPaletteColor(), getPixelFormat(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), GetSizePixel(), BitmapInfoAccess::HasPalette(), ImpErrorQuad::ImplAddColorError1(), ImpErrorQuad::ImplAddColorError3(), ImpErrorQuad::ImplAddColorError5(), ImpErrorQuad::ImplAddColorError7(), ImpErrorQuad::ImplGetColor(), maPrefMapMode, maPrefSize, vcl::N8_BPP, nCount, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), SAL_WARN_IF, and BitmapPalette::SetEntryCount().
Referenced by Convert().
|
private |
Definition at line 1057 of file bitmap/bitmap.cxx.
References aMap, BitmapPalette::GetEntryCount(), BitmapReadAccess::GetIndexFromData(), BitmapInfoAccess::GetPalette(), BitmapInfoAccess::GetPaletteColor(), getPixelFormat(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), GetSizePixel(), BitmapInfoAccess::HasPalette(), i, maPrefMapMode, maPrefSize, vcl::pixelFormatBitCount(), SAL_WARN_IF, and BitmapPalette::SetEntryCount().
Referenced by Convert().
|
inline |
Definition at line 570 of file include/vcl/bitmap.hxx.
Referenced by BitmapInfoAccess::BitmapInfoAccess(), BitmapReadAccess::BitmapReadAccess(), OutputDevice::BlendBitmap(), AlphaMask::BlendWith(), OutputDevice::DrawBitmap(), OutputDevice::DrawDeviceAlphaBitmap(), OutputDevice::DrawDeviceAlphaBitmapSlowPath(), OutputDevice::DrawDeviceBitmapEx(), OutputDevice::DrawDeviceMask(), OutputDevice::DrawTransformBitmapExDirect(), BitmapScaleSuperFilter::execute(), and BitmapInfoAccess::~BitmapInfoAccess().
bool Bitmap::ImplMakeGreyscales | ( | ) |
Definition at line 954 of file bitmap/bitmap.cxx.
References aMap, BitmapPalette::GetEntryCount(), GetGreyPalette(), BitmapReadAccess::GetIndexFromData(), Color::GetLuminance(), BitmapInfoAccess::GetPalette(), BitmapInfoAccess::GetPaletteColor(), BitmapInfoAccess::GetPaletteEntryCount(), BitmapReadAccess::GetPixelFromData(), BitmapReadAccess::GetScanline(), BitmapInfoAccess::GetScanlineFormat(), GetSizePixel(), BitmapInfoAccess::HasPalette(), maPrefMapMode, maPrefSize, N24BitTcBgr, N24BitTcRgb, vcl::N8_BPP, N8BitPal, and vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset().
Referenced by Convert(), BitmapEmbossGreyFilter::execute(), and BitmapSobelGreyFilter::execute().
void Bitmap::ImplMakeUnique | ( | ) |
Definition at line 325 of file bitmap/bitmap.cxx.
References SalInstance::CreateSalBitmap(), ImplGetSVData(), ImplSVData::mpDefInst, and mxSalBmp.
Referenced by BitmapInfoAccess::BitmapInfoAccess().
void Bitmap::ImplSetSalBitmap | ( | const std::shared_ptr< SalBitmap > & | xImpBmp | ) |
Definition at line 358 of file bitmap/bitmap.cxx.
References mxSalBmp.
Referenced by BitmapInfoAccess::BitmapInfoAccess(), AlphaMask::BlendWith(), Convert(), CreateDisplayBitmap(), Erase(), OutputDevice::GetBitmap(), Replace(), and Scale().
bool Bitmap::Invert | ( | ) |
Perform the Invert operation on every pixel.
Definition at line 61 of file bitmappaint.cxx.
References BitmapPalette::GetEntryCount(), BitmapInfoAccess::HasPalette(), i, Color::Invert(), mxSalBmp, and nCount.
Referenced by BitmapEx::BitmapEx(), OutputDevice::DrawTransparent(), BitmapEx::Invert(), vcl::PDFWriterImpl::playMetafile(), and ReadDIBV5().
|
inline |
Definition at line 595 of file include/vcl/bitmap.hxx.
References mxSalBmp.
Referenced by BitmapEx::Adjust(), AlphaMask::AlphaMask(), BitmapEx::BitmapEx(), SvmWriter::BmpExHandler(), SvmWriter::BmpExScaleHandler(), SvmWriter::BmpExScalePartHandler(), SvmWriter::BmpHandler(), SvmWriter::BmpScaleHandler(), SvmWriter::BmpScalePartHandler(), vcl::bitmap::CanvasExtractBitmapData(), clipMetafileContentAgainstOwnRegions(), BitmapEx::Convert(), BitmapEx::CopyPixel(), BitmapEx::Crop(), DetectEdges(), OutputDevice::DrawBitmap(), Printer::DrawDeviceMask(), OutputDevice::EmulateDrawTransparent(), Erase(), BitmapEx::Erase(), BitmapEx::Expand(), BitmapEx::GetAlpha(), ImpGraphic::getBitmap(), vcl::bitmap::GetDownsampledBitmap(), OutputDevice::ImplDrawRotateText(), Printer::ImplPrintTransparent(), EMFWriter::ImplWriteBmpRecord(), BitmapEx::Invert(), BitmapEx::IsEmpty(), SvmWriter::MaskHandler(), SvmWriter::MaskScaleHandler(), SvmWriter::MaskScalePartHandler(), BitmapEx::Mirror(), BitmapEx::ModifyBitmapEx(), AlphaMask::operator=(), RemoveBlendedStartColor(), BitmapEx::Replace(), Rotate(), BitmapEx::Rotate(), and BitmapEx::Scale().
bool Bitmap::Mirror | ( | BmpMirrorFlags | nMirrorFlags | ) |
Mirror the bitmap.
nMirrorFlags | About which axis (horizontal, vertical, or both) to mirror |
Definition at line 141 of file bitmappaint.cxx.
References vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::get(), Horizontal, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and Vertical.
Referenced by OutputDevice::DrawBitmap(), OutputDevice::DrawDeviceAlphaBitmap(), OutputDevice::DrawDeviceMask(), Printer::DrawDeviceMask(), Printer::ImplPrintTransparent(), BitmapEx::Mirror(), and Rotate().
|
inline |
Definition at line 118 of file include/vcl/bitmap.hxx.
References operator==().
Referenced by AlphaMask::operator!=().
Definition at line 220 of file bitmap/bitmap.cxx.
Definition at line 208 of file bitmap/bitmap.cxx.
References maPrefMapMode, maPrefSize, and mxSalBmp.
Referenced by AlphaMask::operator=().
bool Bitmap::operator== | ( | const Bitmap & | rBitmap | ) | const |
Definition at line 229 of file bitmap/bitmap.cxx.
References mxSalBmp.
Referenced by AlphaMask::operator==().
void Bitmap::ReassignWithSize | ( | const Bitmap & | rBitmap | ) |
ReassignWithSize and recalculate bitmap.
ReassignWithSizes the bitmap, and recalculates the bitmap size based on the new bitmap.
rBitmap | Bitmap to reassign and use for size calculation |
Definition at line 335 of file bitmap/bitmap.cxx.
References FRound(), GetSizePixel(), Size::Height(), maPrefMapMode, maPrefSize, Size::setHeight(), Size::setWidth(), and Size::Width().
Referenced by Crop(), BitmapDuoToneFilter::execute(), BitmapGaussianSeparableBlurFilter::execute(), BitmapSeparableUnsharpenFilter::execute(), BitmapFastScaleFilter::execute(), Expand(), and Rotate().
|
static |
Definition at line 399 of file bitmap/bitmap.cxx.
Referenced by vcl::bitmap::CanvasCairoExtractBitmapData(), BitmapMosaicFilter::execute(), BitmapEx::GetContour(), AlphaMask::ReleaseAccess(), vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::~ScopedBitmapAccess().
Remove existing blending against COL_WHITE based on given AlphaMask.
Inside convertToBitmapEx the content gets rendered to RGB target (no 'A'), so it gets blended against the start condition of the target device which is blank (usually white background, but others may be used). Usually rendering to RGB is sufficient (e.g. EditViews), but for conversion to BitmapEx the alpha channel is needed to e.g. allow export/conversion to pixel target formats which support Alpha, e.g. PNG. It is possible though to create the fully valid and correct AlphaChannel. If the content, the start condition and the alpha values are known it is possible to calculate back ("remove") the white blending from the result, and this is what this method does.
rColor | The Color we know this Bitmap is blended against (usually COL_WHITE) |
rAlphaMask | The AlphaMask which was used to blend white against this |
Definition at line 1651 of file bitmap/bitmap.cxx.
References Color::GetBlue(), Color::GetGreen(), Color::GetRed(), IsEmpty(), Color::SetBlue(), Color::SetGreen(), Color::SetRed(), x, and y.
Merge bitmap with given background color according to specified alpha mask.
rAlpha | Alpha mask specifying the amount of background color to merge in |
rMergeColor | Background color to be used for merging |
Definition at line 887 of file bitmappaint.cxx.
References aMap, BitmapReadAccess::GetColor(), GetSizePixel(), BitmapInfoAccess::Height(), maPrefMapMode, maPrefSize, Color::Merge(), vcl::N24_BPP, vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), and BitmapInfoAccess::Width().
Referenced by unographic::Graphic::colorChange(), BitmapEx::GetBitmap(), EMFWriter::ImplWrite(), BitmapEx::Replace(), BitmapEx::ReplaceTransparency(), and WMFWriter::WriteRecords().
bool Bitmap::Replace | ( | const Color & | rSearchColor, |
const Color & | rReplaceColor, | ||
sal_uInt8 | nTol = 0 |
||
) |
Replace all pixel having the search color with the specified color.
rSearchColor | Color specifying which pixel should be replaced |
rReplaceColor | Color to be placed in all changed pixel |
nTol | Tolerance value. Specifies the maximal difference between rSearchColor and the individual pixel values, such that the corresponding pixel is still regarded a match. |
Definition at line 928 of file bitmappaint.cxx.
References Color::GetBlue(), Color::GetGreen(), Color::GetRed(), i, ImplGetSVData(), ImplSetSalBitmap(), maPrefMapMode, maPrefSize, mxSalBmp, and vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset().
bool Bitmap::Replace | ( | const Color * | pSearchColors, |
const Color * | rReplaceColors, | ||
size_t | nColorCount, | ||
sal_uInt8 const * | pTols | ||
) |
Replace all pixel having one the search colors with the corresponding replace color.
pSearchColors | Array of colors specifying which pixel should be replaced |
rReplaceColors | Array of colors to be placed in all changed pixel |
nColorCount | Size of the aforementioned color arrays |
pTols | Tolerance value. Specifies the maximal difference between pSearchColor colors and the individual pixel values, such that the corresponding pixel is still regarded a match. |
Definition at line 994 of file bitmappaint.cxx.
References Color::GetBlue(), Color::GetGreen(), Color::GetRed(), i, and vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset().
Rotate bitmap by the specified angle.
nAngle10 | The rotation angle in tenth of a degree. The bitmap is always rotated around its center. |
rFillColor | The color to use for filling blank areas. During rotation, the bitmap is enlarged such that the whole rotation result fits in. The empty spaces around that rotated original bitmap are then filled with this color. |
Definition at line 299 of file bitmappaint.cxx.
References tools::Polygon::GetBoundRect(), BitmapInfoAccess::GetPalette(), BitmapReadAccess::GetPixel(), getPixelFormat(), tools::Rectangle::GetSize(), GetSizePixel(), Size::Height(), Horizontal, IsEmpty(), tools::Rectangle::Left(), Mirror(), ReassignWithSize(), vcl::ScopedBitmapAccess< Access, Bitmap, Acquire >::reset(), tools::Polygon::Rotate(), tools::Rectangle::Top(), toRadians(), Vertical, and Size::Width().
Referenced by OutputDevice::ImplDrawRotateText(), and BitmapEx::Rotate().
bool Bitmap::Scale | ( | const double & | rScaleX, |
const double & | rScaleY, | ||
BmpScaleFlag | nScaleFlag = BmpScaleFlag::Default |
||
) |
Scale the bitmap.
rScaleX | The scale factor in x direction. |
rScaleY | The scale factor in y direction. |
nScaleFlag | Method of scaling - it is recommended that either BmpScaleFlag::Default or BmpScaleFlag::BestQuality be used. |
Definition at line 1260 of file bitmap/bitmap.cxx.
References BestQuality, BiCubic, BiLinear, Default, basegfx::fTools::equal(), basegfx::fTools::equalZero(), Fast, BitmapFilter::Filter(), BitmapEx::GetBitmap(), getPixelFormat(), GetSizePixel(), Height, ImplGetSVData(), ImplSetSalBitmap(), Interpolate, Lanczos, maPrefMapMode, maPrefSize, mxSalBmp, NearestNeighbor, SAL_INFO, and Width.
bool Bitmap::Scale | ( | const Size & | rNewSize, |
BmpScaleFlag | nScaleFlag = BmpScaleFlag::Default |
||
) |
Scale the bitmap.
rNewSize | The resulting size of the scaled bitmap |
nScaleFlag | The algorithm to be used for scaling |
Definition at line 1332 of file bitmap/bitmap.cxx.
References GetSizePixel(), Size::Height(), Scale(), and Size::Width().
Referenced by BitmapEx::BitmapEx(), OutputDevice::DrawBitmap(), BitmapFastScaleFilter::execute(), ImpGraphic::getBitmap(), vcl::bitmap::GetDownsampledBitmap(), BitmapEx::Scale(), and Scale().
void Bitmap::SetEmpty | ( | ) |
Definition at line 246 of file bitmap/bitmap.cxx.
References maPrefMapMode, maPrefSize, and mxSalBmp.
Referenced by BitmapEx::ClearAlpha(), vcl::bitmap::GetDownsampledBitmap(), BitmapEx::ModifyBitmapEx(), and BitmapEx::SetEmpty().
|
inline |
Definition at line 605 of file include/vcl/bitmap.hxx.
References maPrefMapMode.
Referenced by DetectEdges(), BitmapColorQuantizationFilter::execute(), BitmapConvolutionMatrixFilter::execute(), BitmapEmbossGreyFilter::execute(), BitmapMedianFilter::execute(), BitmapMonochromeFilter::execute(), BitmapMosaicFilter::execute(), BitmapSepiaFilter::execute(), BitmapSimpleColorQuantizationFilter::execute(), BitmapSobelGreyFilter::execute(), and ImpGraphic::getBitmap().
|
inline |
Definition at line 615 of file include/vcl/bitmap.hxx.
References maPrefSize.
Referenced by DetectEdges(), BitmapColorQuantizationFilter::execute(), BitmapConvolutionMatrixFilter::execute(), BitmapEmbossGreyFilter::execute(), BitmapMedianFilter::execute(), BitmapMonochromeFilter::execute(), BitmapMosaicFilter::execute(), BitmapSepiaFilter::execute(), BitmapSimpleColorQuantizationFilter::execute(), BitmapSobelGreyFilter::execute(), and ImpGraphic::getBitmap().
void Bitmap::Vectorize | ( | GDIMetaFile & | rMtf, |
sal_uInt8 | cReduce, | ||
const Link< tools::Long, void > * | pProgress | ||
) |
Convert the bitmap to a meta file.
This works by putting continuous areas of the same color into polygons painted in this color, by tracing the area's bounding line.
rMtf | The resulting meta file |
cReduce | If non-null, minimal size of bound rects for individual polygons. Smaller ones are ignored. |
pProgress | A callback for showing the progress of the vectorization |
Definition at line 1491 of file bitmap/bitmap.cxx.
References ImplVectorizer::ImplVectorize().
|
private |
Definition at line 591 of file include/vcl/bitmap.hxx.
Referenced by CreateAlphaMask(), CreateMask(), Dither(), Erase(), GetPrefMapMode(), ImplConvertDown8BPP(), ImplConvertUp(), ImplMakeGreyscales(), operator=(), ReassignWithSize(), Replace(), Scale(), SetEmpty(), and SetPrefMapMode().
|
private |
Definition at line 592 of file include/vcl/bitmap.hxx.
Referenced by CreateAlphaMask(), CreateMask(), Dither(), Erase(), GetPrefSize(), ImplConvertDown8BPP(), ImplConvertUp(), ImplMakeGreyscales(), operator=(), ReassignWithSize(), Replace(), Scale(), SetEmpty(), and SetPrefSize().
|
private |
Definition at line 590 of file include/vcl/bitmap.hxx.
Referenced by accessSystemDependentDataHolder(), Bitmap(), Convert(), CopyPixel(), CopyPixel_AlphaOptimized(), CreateDisplayBitmap(), Erase(), GetChecksum(), getPixelFormat(), GetSizePixel(), GetSystemData(), ImplMakeUnique(), ImplSetSalBitmap(), Invert(), IsEmpty(), operator=(), operator==(), Replace(), Scale(), and SetEmpty().