summaryrefslogtreecommitdiff
path: root/core/fpdfapi/render/cpdf_scaledrenderbuffer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/fpdfapi/render/cpdf_scaledrenderbuffer.cpp')
-rw-r--r--core/fpdfapi/render/cpdf_scaledrenderbuffer.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/core/fpdfapi/render/cpdf_scaledrenderbuffer.cpp b/core/fpdfapi/render/cpdf_scaledrenderbuffer.cpp
index 17e33af3b1..82970e5e60 100644
--- a/core/fpdfapi/render/cpdf_scaledrenderbuffer.cpp
+++ b/core/fpdfapi/render/cpdf_scaledrenderbuffer.cpp
@@ -52,9 +52,8 @@ bool CPDF_ScaledRenderBuffer::Initialize(CPDF_RenderContext* pContext,
bpp = 32;
}
while (1) {
- CFX_FloatRect rect(pRect);
- m_Matrix.TransformRect(rect);
- FX_RECT bitmap_rect = rect.GetOuterRect();
+ FX_RECT bitmap_rect =
+ m_Matrix.TransformRect(CFX_FloatRect(pRect)).GetOuterRect();
int32_t iWidth = bitmap_rect.Width();
int32_t iHeight = bitmap_rect.Height();
int32_t iPitch = (iWidth * bpp + 31) / 32 * 4;