From 548c2735c09570726f08d5ae9fee8efefb54d529 Mon Sep 17 00:00:00 2001 From: osnola Date: Sun, 31 Mar 2019 09:34:11 +0200 Subject: [PATCH] glm: force dmat3 initialization (needed from v0.9.9.0) Change-Id: I2cb285f2d9bc1e9818ed946b38caaf8a5de9e61a Reviewed-on: https://gerrit.libreoffice.org/69993 Reviewed-by: Laurent Alonso(fr) Tested-by: Laurent Alonso(fr) --- src/lib/IWORKCollector.cpp | 6 +++--- src/lib/KEYCollector.cpp | 3 +-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/lib/IWORKCollector.cpp b/src/lib/IWORKCollector.cpp index 41a9c79..794b462 100644 --- a/src/lib/IWORKCollector.cpp +++ b/src/lib/IWORKCollector.cpp @@ -183,8 +183,8 @@ private: IWORKCollector::Level::Level() : m_geometry() , m_graphicStyle() - , m_trafo() - , m_previousTrafo() + , m_trafo(1) + , m_previousTrafo(1) { } @@ -601,7 +601,7 @@ void IWORKCollector::startLevel() return; } - glm::dmat3 currentTrafo, prevTrafo; + glm::dmat3 currentTrafo(1), prevTrafo(1); if (!m_levelStack.empty()) { currentTrafo = m_levelStack.top().m_trafo; diff --git a/src/lib/KEYCollector.cpp b/src/lib/KEYCollector.cpp index a9d8cc3..08e7e69 100644 --- a/src/lib/KEYCollector.cpp +++ b/src/lib/KEYCollector.cpp @@ -167,7 +167,7 @@ void KEYCollector::insertTextPlaceholder(const KEYPlaceholderPtr_t &placeholder) { if (bool(placeholder)) { - glm::dmat3 trafo; + glm::dmat3 trafo(1); if (bool(placeholder->m_geometry)) trafo = makeTransformation(*placeholder->m_geometry); trafo *= m_levelStack.top().m_trafo; @@ -417,7 +417,6 @@ void KEYCollector::drawTextBox(const IWORKTextPtr_t &text, const glm::dmat3 &tra double w = boundingBox->m_naturalSize.m_width; double h = boundingBox->m_naturalSize.m_height; vec = trafo * glm::dvec3(w, h, 0); - if (vec[0]>0) props.insert("svg:width", pt2in(vec[0])); if (vec[1]>0) -- 2.24.1