From 9f3926df5c2828ad3e8cfce2b4444b1c84352cf4 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Wed, 6 Feb 2019 13:46:24 +0000 Subject: tdf#123165 cache recently scaled bitmaps for reuse MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit dropping the cached scaled bitmap when the bitmap is accesed via BitmapAccessMode::Write for writing Change-Id: Ib6539522944838238bd699ec3531039d21dc0f8b Reviewed-on: https://gerrit.libreoffice.org/67459 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- vcl/inc/svdata.hxx | 2 ++ 1 file changed, 2 insertions(+) (limited to 'vcl/inc/svdata.hxx') diff --git a/vcl/inc/svdata.hxx b/vcl/inc/svdata.hxx index ea48d774ccca..08c1e5a66d77 100644 --- a/vcl/inc/svdata.hxx +++ b/vcl/inc/svdata.hxx @@ -22,6 +22,7 @@ #include +#include #include #include #include @@ -194,6 +195,7 @@ struct ImplSVGDIData std::unique_ptr mpPrinterQueueList; // List of all printer queue std::shared_ptr mxScreenFontList; // Screen-Font-List std::shared_ptr mxScreenFontCache; // Screen-Font-Cache + o3tl::lru_map maScaleCache = o3tl::lru_map(10); // Cache for scaled images ImplDirectFontSubstitution* mpDirectFontSubst = nullptr; // Font-Substitutions defined in Tools->Options->Fonts GraphicConverter* mpGrfConverter = nullptr; // Converter for graphics long mnAppFontX = 0; // AppFont X-Numenator for 40/tel Width -- cgit