Kaydet (Commit) 290a954a authored tarafından Noel Grandin's avatar Noel Grandin

tdf#116646 Slideshows with transitions page swap rendering issues

regression from
    commit 5b75a169
    move cairo extract bitmap code from canvas to vcl

Change-Id: Ic8d7cd9d54010ae272073877da18a985e931e22a
Reviewed-on: https://gerrit.libreoffice.org/52005Tested-by: 's avatarJenkins <ci@libreoffice.org>
Tested-by: 's avatarXisco Faulí <xiscofauli@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 0cb17267
......@@ -363,10 +363,10 @@ namespace cairocanvas
if( !pSurface )
{
vcl::bitmap::CanvasCairoExtractBitmapData(aBmpEx, aBitmap, data, bHasAlpha);
long nWidth;
long nHeight;
vcl::bitmap::CanvasCairoExtractBitmapData(aBmpEx, aBitmap, data, bHasAlpha, nWidth, nHeight);
const long nWidth = aBmpEx.GetPrefSize().Width();
const long nHeight = aBmpEx.GetPrefSize().Height();
SurfaceSharedPtr pImageSurface = rSurfaceProvider->getOutputDevice()->CreateSurface(
CairoSurfaceSharedPtr(
cairo_image_surface_create_for_data(
......
......@@ -102,7 +102,7 @@ VCL_DLLPUBLIC css::uno::Sequence< sal_Int8 > GetMaskDIB(BitmapEx const & aBmpEx)
* @param data will be filled with alpha data, if xBitmap is alpha/transparent image
* @param bHasAlpha will be set to true if resulting surface has alpha
**/
VCL_DLLPUBLIC void CanvasCairoExtractBitmapData( BitmapEx & rBmpEx, Bitmap & rBitmap, unsigned char*& data, bool& bHasAlpha );
VCL_DLLPUBLIC void CanvasCairoExtractBitmapData( BitmapEx & rBmpEx, Bitmap & rBitmap, unsigned char*& data, bool& bHasAlpha, long& rnWidth, long& rnHeight );
VCL_DLLPUBLIC css::uno::Sequence< sal_Int8 > CanvasExtractBitmapData(BitmapEx & rBitmapEx, const css::geometry::IntegerRectangle2D& rect);
......
......@@ -719,14 +719,14 @@ static bool readAlpha( BitmapReadAccess const * pAlphaReadAcc, long nY, const lo
* @param data will be filled with alpha data, if xBitmap is alpha/transparent image
* @param bHasAlpha will be set to true if resulting surface has alpha
**/
void CanvasCairoExtractBitmapData( BitmapEx & aBmpEx, Bitmap & aBitmap, unsigned char*& data, bool& bHasAlpha )
void CanvasCairoExtractBitmapData( BitmapEx & aBmpEx, Bitmap & aBitmap, unsigned char*& data, bool& bHasAlpha, long& rnWidth, long& rnHeight )
{
AlphaMask aAlpha = aBmpEx.GetAlpha();
::BitmapReadAccess* pBitmapReadAcc = aBitmap.AcquireReadAccess();
::BitmapReadAccess* pAlphaReadAcc = nullptr;
const long nWidth = pBitmapReadAcc->Width();
const long nHeight = pBitmapReadAcc->Height();
const long nWidth = rnWidth = pBitmapReadAcc->Width();
const long nHeight = rnHeight = pBitmapReadAcc->Height();
long nX, nY;
bool bIsAlpha = false;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment