7#ifndef CORE_FXGE_AGG_FX_AGG_DRIVER_H_
8#define CORE_FXGE_AGG_FX_AGG_DRIVER_H_
13#include "build/build_config.h"
14#include "core/fxcrt/retain_ptr.h"
15#include "core/fxge/cfx_fillrenderoptions.h"
16#include "core/fxge/renderdevicedriver_iface.h"
18#if BUILDFLAG(IS_APPLE)
19#include "core/fxcrt/unowned_ptr_exclusion.h"
30class rasterizer_scanline_aa;
59 uint32_t stroke_color,
90 std::unique_ptr<CFX_ImageRenderer>* handle,
104 void Clear(uint32_t color);
107 void RenderRasterizer(pdfium::
agg::rasterizer_scanline_aa& rasterizer,
110 bool bGroupKnockout);
112 void SetClipMask(pdfium::
agg::rasterizer_scanline_aa& rasterizer);
115 std::unique_ptr<CFX_ClipRgn> m_pClipRgn;
116 std::vector<std::unique_ptr<CFX_ClipRgn>> m_StateStack;
117#if BUILDFLAG(IS_APPLE)
118 UNOWNED_PTR_EXCLUSION
void* m_pPlatformGraphics =
nullptr;
121 const bool m_bRgbByteOrder;
122 const bool m_bGroupKnockout;
123 RetainPtr<CFX_DIBitmap> m_pBackdropBitmap;
const FX_RECT & GetBox() const
constexpr CFX_FloatRect(float l, float b, float r, float t)
void Intersect(const CFX_FloatRect &other_rect)
FX_RECT GetOuterRect() const
bool Continue(PauseIndicatorIface *pPause)
CFX_Matrix & operator=(const CFX_Matrix &other)=default
CFX_Matrix(float a1, float b1, float c1, float d1, float e1, float f1)
CFX_Matrix operator*(const CFX_Matrix &right) const
CFX_PointF Transform(const CFX_PointF &point) const
CFX_Matrix GetInverse() const
void SetBitmap(RetainPtr< CFX_DIBitmap > bitmap)
bool FillRectWithBlend(const FX_RECT &rect, uint32_t fill_color, BlendMode blend_type) override
~CFX_AggDeviceDriver() override
CFX_AggDeviceDriver(RetainPtr< CFX_DIBitmap > pBitmap, bool bRgbByteOrder, RetainPtr< CFX_DIBitmap > pBackdropBitmap, bool bGroupKnockout)
bool ContinueDIBits(CFX_ImageRenderer *handle, PauseIndicatorIface *pPause) override
bool DrawDeviceText(pdfium::span< const TextCharPos > pCharPos, CFX_Font *pFont, const CFX_Matrix &mtObject2Device, float font_size, uint32_t color, const CFX_TextRenderOptions &options) override
void RestoreState(bool bKeepSaved) override
bool StartDIBits(RetainPtr< const CFX_DIBBase > bitmap, float alpha, uint32_t argb, const CFX_Matrix &matrix, const FXDIB_ResampleOptions &options, std::unique_ptr< CFX_ImageRenderer > *handle, BlendMode blend_type) override
bool GetClipBox(FX_RECT *pRect) override
int GetDeviceCaps(int caps_id) const override
bool GetDIBits(const RetainPtr< CFX_DIBitmap > &pBitmap, int left, int top) override
void SaveState() override
RetainPtr< CFX_DIBitmap > GetBackDrop() override
bool SetClip_PathStroke(const CFX_Path &path, const CFX_Matrix *pObject2Device, const CFX_GraphStateData *pGraphState) override
int GetDriverType() const override
bool MultiplyAlpha(float alpha) override
DeviceType GetDeviceType() const override
bool DrawPath(const CFX_Path &path, const CFX_Matrix *pObject2Device, const CFX_GraphStateData *pGraphState, uint32_t fill_color, uint32_t stroke_color, const CFX_FillRenderOptions &fill_options, BlendMode blend_type) override
bool MultiplyAlphaMask(const RetainPtr< const CFX_DIBBase > &mask) override
bool SetDIBits(const RetainPtr< const CFX_DIBBase > &pBitmap, uint32_t argb, const FX_RECT &src_rect, int left, int top, BlendMode blend_type) override
bool StretchDIBits(RetainPtr< const CFX_DIBBase > bitmap, uint32_t argb, int dest_left, int dest_top, int dest_width, int dest_height, const FX_RECT *pClipRect, const FXDIB_ResampleOptions &options, BlendMode blend_type) override
void Clear(uint32_t color)
bool SetClip_PathFill(const CFX_Path &path, const CFX_Matrix *pObject2Device, const CFX_FillRenderOptions &fill_options) override
#define FXRGB2GRAY(r, g, b)
#define FXARGB_SETRGBORDERDIB(p, argb)
constexpr FX_ARGB ArgbEncode(uint32_t a, uint32_t r, uint32_t g, uint32_t b)
#define FXARGB_TOBGRORDERDIB(argb)
#define FXARGB_SETDIB(p, argb)
#define FXDIB_ALPHA_MERGE(backdrop, source, source_alpha)
#define FXRC_ALPHA_OUTPUT
#define FXDC_PIXEL_HEIGHT
#define FXRC_BYTEMASK_OUTPUT
void Offset(int dx, int dy)
void Intersect(const FX_RECT &src)
constexpr FX_RECT(int l, int t, int r, int b)
#define UNOWNED_PTR_EXCLUSION