Index: core/fpdfapi/fpdf_render/fpdf_render_image.cpp |
diff --git a/core/fpdfapi/fpdf_render/fpdf_render_image.cpp b/core/fpdfapi/fpdf_render/fpdf_render_image.cpp |
index 528ad78d2ba3b0a410d422b93f4ae96352c5b65e..17851b8b4b53e99f8831263ce6e28ac879485735 100644 |
--- a/core/fpdfapi/fpdf_render/fpdf_render_image.cpp |
+++ b/core/fpdfapi/fpdf_render/fpdf_render_image.cpp |
@@ -45,8 +45,6 @@ void CPDF_RenderStatus::CompositeDIBitmap(CFX_DIBitmap* pDIBitmap, |
if (!pDIBitmap) { |
return; |
} |
- FX_BOOL bIsolated = Transparency & PDFTRANS_ISOLATED; |
- FX_BOOL bGroup = Transparency & PDFTRANS_GROUP; |
if (blend_mode == FXDIB_BLEND_NORMAL) { |
if (!pDIBitmap->IsAlphaMask()) { |
if (bitmap_alpha < 255) { |
@@ -66,8 +64,10 @@ void CPDF_RenderStatus::CompositeDIBitmap(CFX_DIBitmap* pDIBitmap, |
} |
} |
} |
- FX_BOOL bBackAlphaRequired = blend_mode && bIsolated && !m_bDropObjects; |
- FX_BOOL bGetBackGround = |
+ bool bIsolated = !!(Transparency & PDFTRANS_ISOLATED); |
+ bool bGroup = !!(Transparency & PDFTRANS_GROUP); |
+ bool bBackAlphaRequired = blend_mode && bIsolated && !m_bDropObjects; |
+ bool bGetBackGround = |
((m_pDevice->GetRenderCaps() & FXRC_ALPHA_OUTPUT)) || |
(!(m_pDevice->GetRenderCaps() & FXRC_ALPHA_OUTPUT) && |
(m_pDevice->GetRenderCaps() & FXRC_GET_BITS) && !bBackAlphaRequired); |